Bug 124206

Summary: pam 0.77-40 does not build package
Product: [Fedora] Fedora Reporter: Steve Grubb <linux_4ever>
Component: pamAssignee: Nalin Dahyabhai <nalin>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: rawhide   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-07-27 16:22:23 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Steve Grubb 2004-05-24 18:01:16 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.4.2)
Gecko/20040308

Description of problem:
Pam does not finish compiling from the src rpm for several reasons.

1) The dependancies are bad
2) The dlopen script is fatally flawed.


Solutions:

1) Pam 0.77-40 needs glib2-devel rather than glib-devel. Actually, the
correct dependencies are this:

Requires: cracklib, cracklib-dicts, glib, initscripts >= 3.94
Obsoletes: pamconfig
Prereq: grep, mktemp, sed, coreutils, /sbin/ldconfig
Requires: glib2, cracklib, cracklib-dicts
BuildPrereq: autoconf, bison, flex, glib2-devel, sed, cracklib,
cracklib-dicts
BuildPrereq: perl, pkgconfig
%if %{WITH_SELINUX}
Requires: libselinux
BuildPrereq: libselinux-devel
%endif


2) The dlopen script does not allow for the Library path of the new
shared object files to be passed in. It uses the normal system path
which definitely does not have the newly built libraries in it. The
pam spec file should be updated to pass their location like this:

# Check for module problems.  Specifically, check that every module we
just
# installed can actually be loaded by a minimal PAM-aware application.
for module in $RPM_BUILD_ROOT/%{_lib}/security/pam*.so ; do
        if ! $RPM_SOURCE_DIR/dlopen.sh -L$RPM_BUILD_ROOT/%{_lib} -lpam
-ldl ${module} ; then
                exit 1
        fi

Then dlopen needs to accept the -L argument like this @ line 43:

        -l*|-L*)
                ldflags="$ldflags $arg"
                ;;


I honestly have no idea how you guys get this package compiled without
the above changes. It simply doesn't work as is.

Version-Release number of selected component (if applicable):
pam-0.77-40

How reproducible:
Always

Steps to Reproduce:
1. rpmbuild -bb /usr/src/redhat/SPEC/pam.spec
    

Actual Results:  You get a message saying the build failed.

Expected Results:  A message saying where the newly built rpm is located.

Additional info:

Comment 1 Alan Cox 2004-07-27 16:22:23 UTC
Done