]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
* Redo how library object files are found for the PAM module build to
authorRuss Allbery <rra@debian.org>
Thu, 18 Aug 2005 19:38:52 +0000 (19:38 +0000)
committerRuss Allbery <rra@debian.org>
Thu, 18 Aug 2005 19:38:52 +0000 (19:38 +0000)
    avoid assuming C locale character set behavior.  (Closes: #323582)

debian/changelog
debian/patches/pam
src/pam/Makefile.in

index 392b0e4160540fb3c5e536a93faaaa8871a08864..a6eae6e4d4ae5aa0aa53c6370a770c3b9ab9b9bb 100644 (file)
@@ -5,6 +5,8 @@ openafs (1.3.87-2) unstable; urgency=low
     dynroot.  afs-newcell generates the server CellServDB directly to work
     around oddities with bos addhost.  Thanks to Fahemm Mitha and Sergio
     Gelato for analysis and patches.  (Closes: #322638)
+  * Redo how library object files are found for the PAM module build to
+    avoid assuming C locale character set behavior.  (Closes: #323582)
 
  --
 
index 50425c35d1e0f8a1f7971c4175a72000383171ac..9598ce296133f30fea63aea982bfae6a5582694a 100644 (file)
@@ -19,16 +19,26 @@ handled more consistently.
 
 --- openafs-1.3.87.orig/src/pam/Makefile.in
 +++ openafs-1.3.87/src/pam/Makefile.in
-@@ -25,7 +25,7 @@
+@@ -25,7 +25,17 @@
          afs_pam_msg.o afs_message.o AFS_component_version_number.o
     OBJS = $(SHOBJS) test_pam.o
  INCLUDES=-I${TOP_OBJDIR}/src/config -I${TOP_INCDIR} 
 -CFLAGS =  ${DEBUG} ${INCLUDES} ${PAM_CFLAGS}
 +CFLAGS =  ${DEBUG} ${INCLUDES} ${PAM_CFLAGS} ${MT_CFLAGS}
++
++# For Debian, we link directly with the object files that would have gone
++# into the libafsrpc and libafsauthent shared libraries.  The shared libraries
++# themselves cannot be used because the interface isn't stable and they have
++# no SONAME, but this is the easiest way of getting PIC objects built with the
++# pthread API.
++SHLIB_OBJS    := `ls ../shlibafsauthent/*.o | grep -v version_num` \
++                 `ls ../shlibafsrpc/*.o | grep -v version_num`
++KRB_SHLIB_OBJS        := `ls ../shlibafsauthent/*.o | egrep -v 'version_num|ktc.o'` \
++                 `ls ../shlibafsrpc/*.o | grep -v version_num`
  
  all: test_pam ${TOP_LIBDIR}/pam_afs.so.1 ${TOP_LIBDIR}/pam_afs.krb.so.1
  
-@@ -39,14 +39,18 @@
+@@ -39,14 +49,18 @@
        ${CC} ${CFLAGS} -c ${srcdir}/afs_auth.c -o afs_auth.o
  
  afs_auth_krb.o: afs_auth.c afs_pam_msg.h afs_message.h afs_util.h
@@ -48,20 +58,19 @@ handled more consistently.
  pam_afs.so.1: $(SHOBJS) afs_setcred.o afs_auth.o afs_util.o
        set -x; \
        case "$(SYS_NAME)" in \
-@@ -59,8 +63,10 @@
+@@ -59,8 +73,9 @@
                        afs_setcred.o afs_auth.o afs_util.o \
                        $(SHOBJS) $(LIBS) ;; \
        *linux*) \
 -              $(CC) $(LDFLAGS) -o $@ afs_setcred.o \
 -                      afs_auth.o afs_util.o $(SHOBJS) $(LIBS) ;;\
 +              $(CC) $(LDFLAGS) $(PAM_CFLAGS) -o $@ afs_setcred.o \
-+                      afs_auth.o afs_util.o $(SHOBJS) \
-+                      ../shlibafsauthent/[a-z]*.o ../shlibafsrpc/[a-z]*.o \
++                      afs_auth.o afs_util.o $(SHOBJS) $(SHLIB_OBJS) \
 +                      $(MT_LIBS) -lpam -lresolv;;\
        *fbsd*| *nbsd*) \
                $(CC) $(LDFLAGS) -o $@ afs_setcred.o \
                        afs_auth.o afs_util.o $(SHOBJS) $(LIBS) ;;\
-@@ -68,7 +74,7 @@
+@@ -68,7 +83,7 @@
                echo No link line for system $(SYS_NAME). ;; \
        esac
  
@@ -70,25 +79,17 @@ handled more consistently.
        set -x; \
        case "$(SYS_NAME)" in \
        hp_ux* | ia64_hpux*) \
-@@ -81,7 +87,10 @@
+@@ -81,7 +96,8 @@
                        $(SHOBJS) $(LDFLAGS) $(KLIBS) ;; \
        *linux*) \
                $(CC) $(LDFLAGS) -o $@ afs_setcred_krb.o \
 -                      afs_auth_krb.o afs_util_krb.o $(SHOBJS) $(KLIBS) ;;\
 +                      afs_auth_krb.o afs_util_krb.o ktc.o $(SHOBJS) \
-+                      `ls ../shlibafsauthent/[a-z]*.o | grep -v ktc.o` \
-+                      ../shlibafsrpc/[a-z]*.o \
-+                      $(MT_LIBS) -lpam -lresolv;;\
++                      $(KRB_SHLIB_OBJS) $(MT_LIBS) -lpam -lresolv;;\
        *fbsd*| *nbsd*) \
                $(CC) $(LDFLAGS) -o $@ afs_setcred_krb.o \
                        afs_auth_krb.o afs_util_krb.o $(SHOBJS) $(KLIBS) ;;\
-@@ -104,13 +113,19 @@
-               echo No link line for system $(SYS_NAME). ;; \
-       esac
- install:  ${DESTDIR}${libdir}/pam_afs.so.1 ${DESTDIR}${libdir}/pam_afs.krb.so.1
- ${DEST}/lib/pam_afs.so.1: pam_afs.so.1
+@@ -110,7 +126,13 @@
        ${INSTALL} $? $@
  
  ${DEST}/lib/pam_afs.krb.so.1: pam_afs.krb.so.1
@@ -103,7 +104,7 @@ handled more consistently.
  
  afs_pam_msg.o: afs_pam_msg.c afs_pam_msg.h afs_message.h
  afs_message.o: afs_message.c afs_message.h
-@@ -130,10 +145,22 @@
+@@ -130,10 +152,22 @@
        ${INSTALL} $? $@
  
  ${DESTDIR}${libdir}/pam_afs.krb.so.1: pam_afs.krb.so.1
index e1dabebfc6e22ba6eca7ed80b5bcda6f8e504d71..ba777e921102cf354d08ccfd48bb1c4a077bbbf6 100644 (file)
@@ -27,6 +27,16 @@ LDFLAGS = ${SHLIB_LDFLAGS}
 INCLUDES=-I${TOP_OBJDIR}/src/config -I${TOP_INCDIR} 
 CFLAGS =  ${DEBUG} ${INCLUDES} ${PAM_CFLAGS} ${MT_CFLAGS}
 
+# For Debian, we link directly with the object files that would have gone
+# into the libafsrpc and libafsauthent shared libraries.  The shared libraries
+# themselves cannot be used because the interface isn't stable and they have
+# no SONAME, but this is the easiest way of getting PIC objects built with the
+# pthread API.
+SHLIB_OBJS     := `ls ../shlibafsauthent/*.o | grep -v version_num` \
+                  `ls ../shlibafsrpc/*.o | grep -v version_num`
+KRB_SHLIB_OBJS := `ls ../shlibafsauthent/*.o | egrep -v 'version_num|ktc.o'` \
+                  `ls ../shlibafsrpc/*.o | grep -v version_num`
+
 all: test_pam ${TOP_LIBDIR}/pam_afs.so.1 ${TOP_LIBDIR}/pam_afs.krb.so.1
 
 afs_setcred.o: afs_setcred.c afs_pam_msg.h afs_message.h afs_util.h
@@ -64,8 +74,7 @@ pam_afs.so.1: $(SHOBJS) afs_setcred.o afs_auth.o afs_util.o
                        $(SHOBJS) $(LIBS) ;; \
        *linux*) \
                $(CC) $(LDFLAGS) $(PAM_CFLAGS) -o $@ afs_setcred.o \
-                       afs_auth.o afs_util.o $(SHOBJS) \
-                       ../shlibafsauthent/[a-z]*.o ../shlibafsrpc/[a-z]*.o \
+                       afs_auth.o afs_util.o $(SHOBJS) $(SHLIB_OBJS) \
                        $(MT_LIBS) -lpam -lresolv;;\
        *fbsd*| *nbsd*) \
                $(CC) $(LDFLAGS) -o $@ afs_setcred.o \
@@ -88,9 +97,7 @@ pam_afs.krb.so.1: $(SHOBJS) afs_setcred_krb.o afs_auth_krb.o afs_util_krb.o ktc.
        *linux*) \
                $(CC) $(LDFLAGS) -o $@ afs_setcred_krb.o \
                        afs_auth_krb.o afs_util_krb.o ktc.o $(SHOBJS) \
-                       `ls ../shlibafsauthent/[a-z]*.o | grep -v ktc.o` \
-                       ../shlibafsrpc/[a-z]*.o \
-                       $(MT_LIBS) -lpam -lresolv;;\
+                       $(KRB_SHLIB_OBJS) $(MT_LIBS) -lpam -lresolv;;\
        *fbsd*| *nbsd*) \
                $(CC) $(LDFLAGS) -o $@ afs_setcred_krb.o \
                        afs_auth_krb.o afs_util_krb.o $(SHOBJS) $(KLIBS) ;;\