From 3a22ab67f6d57e1ca30361570c09f1047ad38152 Mon Sep 17 00:00:00 2001 From: Pekka Riikonen Date: Fri, 6 Dec 2002 17:25:31 +0000 Subject: [PATCH] Added --wihtout-libtoolfix. --- CHANGES | 3 +++ configure.in.pre | 22 +++++++++++++++++++++- lib/silccrypt/Makefile.am | 8 +++++++- lib/silcsim/Makefile.am | 10 ++++++++-- 4 files changed, 39 insertions(+), 4 deletions(-) diff --git a/CHANGES b/CHANGES index 30980576..4698a724 100644 --- a/CHANGES +++ b/CHANGES @@ -12,6 +12,9 @@ Fri Dec 6 17:40:24 EET 2002 Pekka Riikonen * GETKEY to update the client entrys fingerprint too. Affected file lib/silcclient/command_reply.c. + * Added --without-libtoolfix for package builders using weird + wrappers around libtool (BSD at least). + Thu Dec 5 22:29:46 EET 2002 Pekka Riikonen * Fixed backup router bugs: When backup resumes router and diff --git a/configure.in.pre b/configure.in.pre index c8161875..9c9aa969 100644 --- a/configure.in.pre +++ b/configure.in.pre @@ -997,6 +997,22 @@ AC_ARG_WITH(silcd, AC_MSG_RESULT(yes) ]) +libtoolfix=true +AC_MSG_CHECKING(whether to do libtoolfix) +AC_ARG_WITH(libtoolfix, + [ --without-libtoolfix Do not fix libtool, for package builders], + [ + AC_MSG_RESULT(no) + libtoolfix=false + ], + [ + AC_MSG_RESULT(yes) + ]) + +AC_SUBST(ETCDIR) +AC_DEFINE_UNQUOTED(SILC_ETCDIR, "$ETCDIR") + + ## ## Misc @@ -1031,7 +1047,11 @@ AC_SUBST(SILC_DIST_SUBDIRS) # to in run-time specify when to compile shared/static libraries without # need to reconfigure the entire libtool. # -./libtoolfix $SILC_TOP_SRCDIR/ltmain.sh +if test x$libtoolfix = xtrue; then + ./libtoolfix $SILC_TOP_SRCDIR/ltmain.sh +fi +AM_CONDITIONAL(SILC_LIBTOOLFIX, test x$libtoolfix = xtrue) + # # Makefile outputs diff --git a/lib/silccrypt/Makefile.am b/lib/silccrypt/Makefile.am index d158c3ae..47f72044 100644 --- a/lib/silccrypt/Makefile.am +++ b/lib/silccrypt/Makefile.am @@ -38,8 +38,14 @@ libsilccrypt_la_SOURCES = \ silcpkcs.c \ pkcs1.c +if SILC_LIBTOOLFIX # Tell libtool to compile silccrypt as shared since silcsim will need it. -CFLAGS = --libtool-enable-shared +LTFLAGS = --libtool-enable-shared +else +LTFLAGS = +endif + +CFLAGS = $(LTFLAGS) if SILC_DIST_TOOLKIT include_HEADERS = \ diff --git a/lib/silcsim/Makefile.am b/lib/silcsim/Makefile.am index 6fed6774..3e45d3d7 100644 --- a/lib/silcsim/Makefile.am +++ b/lib/silcsim/Makefile.am @@ -52,10 +52,16 @@ if SILC_SIM all: $(SIM_CIPHER_OBJS) $(SIM_HASH_OBJS) endif +if SILC_LIBTOOLFIX +LTFLAGS = --libtool-enable-shared +else +LTFLAGS = +endif + $(SIM_CIPHER_OBJS): @if test '!' -f lib$*.la ; then \ $(LIBTOOL) --mode=link $(CCLD) -rpath $(silc_modulesdir) \ - ../silccrypt/$*.lo -o lib$*.la --libtool-enable-shared; \ + ../silccrypt/$*.lo -o lib$*.la $(LTFLAGS); \ cd $(srcdir) && $(LN_S) -f $(srcdir)/.libs/lib$*.so \ $(srcdir)/$*.sim.so; \ fi @@ -63,7 +69,7 @@ $(SIM_CIPHER_OBJS): $(SIM_HASH_OBJS): @if test '!' -f lib$*.la ; then \ $(LIBTOOL) --mode=link $(CCLD) -rpath $(silc_modulesdir) \ - ../silccrypt/$*.lo -o lib$*.la --libtool-enable-shared; \ + ../silccrypt/$*.lo -o lib$*.la $(LTFLAGS); \ cd $(srcdir) && $(LN_S) -f $(srcdir)/.libs/lib$*.so \ $(srcdir)/$*.sim.so; \ fi -- 2.43.0