From: Alan T. DeKok Date: Sat, 27 Oct 2012 07:08:18 +0000 (+0200) Subject: Fixes to work with system libtool X-Git-Tag: release_3_0_0_beta1~1646 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=15433acd6429d37f0bff736f93a32c0cdf031a2f;p=thirdparty%2Ffreeradius-server.git Fixes to work with system libtool --- diff --git a/Make.inc.in b/Make.inc.in index c42211ba91d..6bde399afae 100644 --- a/Make.inc.in +++ b/Make.inc.in @@ -152,3 +152,10 @@ all: $(top_srcdir)/scripts/jlibtool $(top_srcdir)/scripts/jlibtool: $(top_srcdir)/scripts/jlibtool.c $(CC) $^ -o $@ + +# Add -module for normal libtool. It doesn't like building "foo.la" +# as a library unless you tell it to shut up, yes, I KNOW this is a module +ifeq "$(findstring jlibtool,$(LIBTOOL))" "" + RLM_MOD = "-module" +endif + diff --git a/src/modules/rlm_sql/drivers/rules.mak b/src/modules/rlm_sql/drivers/rules.mak index 78a1f0f7141..c698bf3e578 100644 --- a/src/modules/rlm_sql/drivers/rules.mak +++ b/src/modules/rlm_sql/drivers/rules.mak @@ -104,7 +104,7 @@ build-module: $(TARGET).la $(TARGET).la: $(LT_OBJS) @echo LINK $@ $^ @$(LIBTOOL) --mode=link $(CC) -release $(RADIUSD_VERSION) \ - $(LINK_MODE) $(LDFLAGS) $(RLM_SQL_LDFLAGS) -o $@ \ + $(LINK_MODE) $(LDFLAGS) $(RLM_SQL_LDFLAGS) $(RLM_MOD) -o $@ \ -rpath $(libdir) $^ $(RLM_SQL_LIBS) ####################################################################### diff --git a/src/modules/rules.mak b/src/modules/rules.mak index ce1a538b164..71a4de77097 100644 --- a/src/modules/rules.mak +++ b/src/modules/rules.mak @@ -125,7 +125,7 @@ build-module: $(TARGET).la $(RLM_UTILS) $(TARGET).la: $(RLM_SUBDIRS) $(LT_OBJS) @echo LINK $@ $(filter %.lo,$^) @$(LIBTOOL) --quiet --mode=link $(CC) -release $(RADIUSD_VERSION) \ - $(LINK_MODE) $(LDFLAGS) $(RLM_LDFLAGS) -o $@ \ + $(LINK_MODE) $(LDFLAGS) $(RLM_LDFLAGS) $(RLM_MOD) -o $@ \ $(filter %.lo,$^) $(LIBRADIUS) $(RLM_LIBS) $(LIBS) #######################################################################