From: Simo Sorce Date: Thu, 11 Sep 2014 21:01:26 +0000 (-0400) Subject: Change the modules build process X-Git-Tag: v1.0.3~1 X-Git-Url: http://www.project-moonshot.org/gitweb/?p=mod_auth_gssapi.git;a=commitdiff_plain;h=e3d818c06bf103a6121e3f3198d70e60b60cd454 Change the modules build process USe automake directives to directly invoke the apxs favored libtool, and use APXS only to perform the final install. Fixes #4 --- diff --git a/configure.ac b/configure.ac index e20a83a..b709373 100644 --- a/configure.ac +++ b/configure.ac @@ -69,8 +69,15 @@ AC_CHECK_FUNCS(gss_store_cred_into) AC_SUBST([GSSAPI_CFLAGS]) AC_SUBST([GSSAPI_LIBS]) -CFLAGS="`${APXS} -q CFLAGS` `${APR} --cflags` ${GSSAPI_CFLAGS} ${OPENSSL_CFLAGS} -I`${APXS} -q INCLUDEDIR` -I`${APR} --includes`" -LIBS="`${APR} --libs` ${GSSAPI_LIBS} ${OPENSSL_LIBS}" +MAG_CFLAGS="`${APXS} -q CFLAGS` `${APR} --cflags` ${GSSAPI_CFLAGS} ${OPENSSL_CFLAGS} -I`${APXS} -q INCLUDEDIR` `${APR} --includes`" +MAG_LIBS="`${APR} --libs` ${GSSAPI_LIBS} ${OPENSSL_LIBS}" +LIBTOOL="`${APXS} -q LIBTOOL`" +MAG_LIBDIR="`${APXS} -q libexecdir`" + +AC_SUBST([MAG_CFLAGS]) +AC_SUBST([MAG_LIBS]) +AC_SUBST([LIBTOOL]) +AC_SUBST([MAG_LIBDIR]) AC_CONFIG_FILES([Makefile src/Makefile]) diff --git a/src/Makefile.am b/src/Makefile.am index 9fac277..01a1220 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,7 +1,18 @@ -EXTRA_DIST = mod_auth_gssapi.c sessions.c crypto.c mod_auth_gssapi.h sessions.h crypto.h +magdir = $(MAG_LIBDIR) +mag_LTLIBRARIES = \ + mod_auth_gssapi.la -all-local: - @APXS@ -c ${LIBS} mod_auth_gssapi.c sessions.c crypto.c +dist_noinst_HEADERS = \ + mod_auth_gssapi.h crypto.h sessions.h + +mod_auth_gssapi_la_SOURCES = \ + mod_auth_gssapi.c crypto.c sessions.c +mod_auth_gssapi_la_CFLAGS = \ + $(MAG_CFLAGS) +mod_auth_gssapi_la_LDFLAGS = \ + $(MAG_LIBS) \ + -avoid-version \ + -module install-exec-local: if test ! -d ${APXS_LIBEXECDIR}; then mkdir -p ${APXS_LIBEXECDIR}; fi