From 1015a097bffef8b2d56050210d47a31ad32f5858 Mon Sep 17 00:00:00 2001 From: Simon Wilkinson Date: Thu, 23 Aug 2012 20:48:21 +0100 Subject: [PATCH] auth: Use libtool Use libtool to build a pthreaded version of the auth library Change-Id: I452773e7fa159c278f5a7a7d21e77b6dd44c14bd Reviewed-on: http://gerrit.openafs.org/8089 Tested-by: BuildBot Reviewed-by: Derrick Brashear --- src/auth/Makefile.in | 73 +++++++++++++++++++++++++------------------- src/auth/liboafs_auth.la.sym | 46 ++++++++++++++++++++++++++++ 2 files changed, 88 insertions(+), 31 deletions(-) create mode 100644 src/auth/liboafs_auth.la.sym diff --git a/src/auth/Makefile.in b/src/auth/Makefile.in index 7a6668d..80a472f 100644 --- a/src/auth/Makefile.in +++ b/src/auth/Makefile.in @@ -7,14 +7,26 @@ srcdir=@srcdir@ include @TOP_OBJDIR@/src/config/Makefile.config +include @TOP_OBJDIR@/src/config/Makefile.libtool include @TOP_OBJDIR@/src/config/Makefile.lwp +BASE_objs= cellconfig.lo keys.lo userok.lo writeconfig.lo authcon.lo \ + acfg_errors.lo ktc_errors.lo netrestrict.lo token.xdr.lo token.lo \ + realms.lo \ + AFS_component_version_number.lo -OBJS= cellconfig.o keys.o ktc.o userok.o writeconfig.o authcon.o \ - acfg_errors.o ktc_errors.o token.xdr.o token.o realms.o netrestrict.o +LT_objs= ktc.lo $(BASE_objs) +KRB_objs = ktc.krb.lo $(BASE_objs) -KOBJS= cellconfig.o keys.o ktc.krb.o userok.o writeconfig.o authcon.o \ - acfg_errors.o ktc_errors.o token.xdr.o token.o realms.o netrestrict.o +LT_deps= $(top_builddir)/src/opr/liboafs_opr.la \ + $(top_builddir)/src/comerr/liboafs_comerr.la \ + $(top_builddir)/src/rx/liboafs_rx.la \ + $(top_builddir)/src/rxkad/liboafs_rxkad.la \ + $(top_builddir)/src/audit/liboafs_audit.la \ + $(top_builddir)/src/util/liboafs_util.la \ + $(top_builddir)/src/sys/liboafs_sys.la + +LT_libs= $(LDFLAGS_roken) $(LIB_roken) LIBS=libauth.a \ ${TOP_LIBDIR}/librxkad.a \ @@ -23,12 +35,10 @@ LIBS=libauth.a \ ${TOP_LIBDIR}/liblwp.a \ ${TOP_LIBDIR}/util.a -INCLS=cellconfig.h auth.h keys.h internal.h -KSRCS=auth.h -UKSRCS=${KSRCS} cellconfig.h acfg_errors.c keys.h cellconfig.c \ - ktc.c authcon.c ktc_errors.c +INCLS=cellconfig.h auth.h keys.h internal.h token.h -all: ${TOP_LIBDIR}/libauth.a ${TOP_LIBDIR}/libauth.krb.a depinstall +all: liboafs_auth.la ${TOP_LIBDIR}/libauth.a ${TOP_LIBDIR}/libauth.krb.a \ + depinstall depinstall: ${TOP_INCDIR}/afs/keys.h \ ${TOP_INCDIR}/afs/cellconfig.h \ @@ -62,31 +72,33 @@ ${TOP_LIBDIR}/libauth.a: libauth.a ${TOP_LIBDIR}/libauth.krb.a: libauth.krb.a ${INSTALL_DATA} libauth.krb.a $@ -cellconfig.o: cellconfig.c ${INCLS} -keys.o: keys.c ${INCLS} -ktc.o: ktc.c ${INCLS} ${TOP_INCDIR}/afs/vice.h -writeconfig.o: writeconfig.c ${INCLS} -authcon.o: authcon.c ${INCLS} -userok.o: userok.c ${INCLS} -cellconfig.o: cellconfig.c ${INCLS} +cellconfig.lo: cellconfig.c ${INCLS} +keys.lo: keys.c ${INCLS} +ktc.lo: ktc.c ${INCLS} ${TOP_INCDIR}/afs/vice.h +writeconfig.lo: writeconfig.c ${INCLS} +authcon.lo: authcon.c ${INCLS} +userok.lo: userok.c ${INCLS} +cellconfig.lo: cellconfig.c ${INCLS} +realms.lo: realms.c ${INCLS} +netrestrict.lo: ${INCLS} + copyauth.o: copyauth.c ${INCLS} AFS_component_version_number.o setkey.o: setkey.c ${INCLS} AFS_component_version_number.o -realms.o: realms.c ${INCLS} -netrestrict.o: ${INCLS} -CFLAGS_ktc.krb.o = -DAFS_KERBEROS_ENV -ktc.krb.o: ktc.c ${INCLS} ${TOP_INCDIR}/afs/vice.h - $(AFS_CCRULE) $(srcdir)/ktc.c +$(LT_objs): $(INCLS) + +CFLAGS_ktc.krb.lo = -DAFS_KERBEROS_ENV +ktc.krb.lo: ktc.c ${INCLS} ${TOP_INCDIR}/afs/vice.h + $(LTLWP_CCRULE) $(srcdir)/ktc.c -libauth.a: $(OBJS) AFS_component_version_number.o - -$(RM) -f libauth.a - $(AR) crv $@ $(OBJS) AFS_component_version_number.o - $(RANLIB) libauth.a +libauth.a: $(LT_objs) + $(LT_LDLIB_lwp) $(LT_objs) -libauth.krb.a: $(KOBJS) AFS_component_version_number.o - -$(RM) -f $@ - $(AR) crv $@ $(KOBJS) AFS_component_version_number.o - $(RANLIB) $@ +libauth.krb.a: $(KRB_objs) + $(LT_LDLIB_lwp) $(KRB_objs) + +liboafs_auth.la: liboafs_auth.la.sym $(LT_objs) $(LT_deps) + $(LT_LDLIB_shlib) $(LT_objs) $(LT_deps) $(LT_libs) copyauth: copyauth.o ${LIBS} $(AFS_LDRULE) copyauth.o ${LIBS} ${XLIBS} @@ -98,8 +110,6 @@ acfg_errors.c cellconfig.h: acfg_errors.et cellconfig.p.h $(RM) -f cellconfig.h acfg_errors.c ${COMPILE_ET} -p ${srcdir} acfg_errors -h cellconfig -ktc.o: token.h - ktc_errors.c auth.h: ktc_errors.et auth.p.h $(RM) -f auth.h ktc_errors.c ${COMPILE_ET} -p ${srcdir} ktc_errors -h auth @@ -143,6 +153,7 @@ test: cd test; $(MAKE) clean: + $(LT_CLEAN) $(RM) -f *.o *.a copyauth setkey auth.h cellconfig.h acfg_errors.c \ ktc_errors.c token.h token.xdr.c core Ktoken.xdr.c \ AFS_component_version_number.c diff --git a/src/auth/liboafs_auth.la.sym b/src/auth/liboafs_auth.la.sym new file mode 100644 index 0000000..7d1c53a --- /dev/null +++ b/src/auth/liboafs_auth.la.sym @@ -0,0 +1,46 @@ +afsconf_AddTypedKey +afsconf_BuildServerSecurityObjects +afsconf_CellAliasApply +afsconf_CellApply +afsconf_CheckAuth +afsconf_ClientAuth +afsconf_ClientAuthSecure +afsconf_ClientAuthToken +afsconf_Close +afsconf_DeleteKey +afsconf_GetAfsdbInfo +afsconf_GetAllKeys +afsconf_GetCellInfo +afsconf_GetExtendedCellInfo +afsconf_GetKey +afsconf_GetLatestKey +afsconf_GetLocalCell +afsconf_GetNoAuthFlag +afsconf_IsLocalRealmMatch +afsconf_Open +afsconf_ParseNetFiles +afsconf_PickClientSecObj +afsconf_SetLocalRealm +afsconf_SetNoAuthFlag +afsconf_SetSecurityFlags +afsconf_SuperUser +afsconf_UpToDate +afsconf_typedKey_new +afsconf_typedKey_put +afsconf_typedKey_values +initialize_ACFG_error_table +initialize_KTC_error_table +ktc_GetToken +ktc_GetTokenEx +ktc_OldPioctl +ktc_SetToken +ktc_SetTokenEx +token_FreeSet +token_SetsEquivalent +token_addToken +token_buildTokenJar +token_freeToken +token_importRxkadViceId +token_replaceToken +token_setPag +token_setRxkadViceId -- 1.9.4