From: Alexandre Oliva Date: Sat, 2 Sep 2000 23:56:42 +0000 (+0000) Subject: * demo/Makefile.am: Don't extract configuration variables directly X-Git-Tag: multi-language-merge-point~161 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a2a961f72a06b13a1043ac84a4257de37ed3f056;p=thirdparty%2Flibtool.git * demo/Makefile.am: Don't extract configuration variables directly from the libtool script, since it breaks with multiple configurations. Use $(LIBTOOL) --config instead. --- diff --git a/ChangeLog b/ChangeLog index 9809ceea5..fefb10e55 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2000-09-02 Alexandre Oliva + * demo/Makefile.am: Don't extract configuration variables directly + from the libtool script, since it breaks with multiple + configurations. Use $(LIBTOOL) --config instead. + * tests/link-2.test: Create hell.lo in the format expected by libtool. diff --git a/demo/Makefile.am b/demo/Makefile.am index bbf435dc3..afc7e8f3a 100644 --- a/demo/Makefile.am +++ b/demo/Makefile.am @@ -60,7 +60,7 @@ CLEANFILES = $(hardcode_tests) # Unfortunately, in order to test libtool thoroughly, we need access # to its private directory. -objdir = `sed -n -e 's/^objdir=\(.*\)$$/\1/p' ../libtool` +objdir = `$(LIBTOOL) --config | sed -n -e 's/^objdir=\(.*\)$$/\1/p'` # The following rules are only for the libtool demo and tests. # Regenerate our acinclude.m4 only if it doesn't exist. @@ -72,6 +72,7 @@ $(srcdir)/acinclude.m4: # Test programs to see what gets hardcoded. .PHONY: hardcode hardcode: $(hardcode_tests) +SET_HARDCODE_FLAGS = eval `$(LIBTOOL) --config | egrep -e '^(hardcode_.*|wl)='` hc-direct: $(hell_OBJECTS) $(hell_DEPENDENCIES) $(libdir)/libhello.la @rm -f hc-direct @echo "You may ignore any linking errors from the following command:" @@ -80,14 +81,14 @@ hc-direct: $(hell_OBJECTS) $(hell_DEPENDENCIES) $(libdir)/libhello.la for lib in $$library_names; do \ shlib="./$(objdir)/$$lib"; \ done; \ - eval `egrep -e '^(hardcode_.*|wl)=' libtool`; \ + $(SET_HARDCODE_FLAGS); \ libdir=$(libdir); \ flag=`eval echo \"$$hardcode_libdir_flag_spec\"`; \ echo "$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(hell_OBJECTS) $$shlib $(LIBS) $(LIBM) $$flag || echo unsupported > $@"; \ eval "$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(hell_OBJECTS) $$shlib $(LIBS) $(LIBM) $$flag || echo unsupported > $@" hc-libflag: $(hell_OBJECTS) $(hell_DEPENDENCIES) $(libdir)/libhello.la - @eval `egrep -e '^(hardcode_.*|wl)=' libtool`; \ + @$(SET_HARDCODE_FLAGS); \ libdir=`pwd`/$(objdir); \ flag=`eval echo \"$$hardcode_libdir_flag_spec\"`; \ if test -z "$$flag"; then \ @@ -102,7 +103,8 @@ hc-libflag: $(hell_OBJECTS) $(hell_DEPENDENCIES) $(libdir)/libhello.la hc-libpath: $(hell_OBJECTS) $(hell_DEPENDENCIES) $(libdir)/libhello.la @rm -f hc-libpath @echo "You may ignore any linking errors from the following command:" - @eval `egrep -e '^(shlibpath_var|hardcode_.*|wl)=' libtool`; \ + @$(SET_HARDCODE_FLAGS); \ + eval `$(LIBTOOL) --config | grep '^shlibpath_var='`; \ libdir=$(libdir); \ flag=`eval echo \"$$hardcode_libdir_flag_spec\"`; \ echo "$$shlibpath_var=./$(objdir) $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(hell_OBJECTS) -lhello $(LIBS) $(LIBM) $$flag || echo unsupported > $@"; \ @@ -110,7 +112,7 @@ hc-libpath: $(hell_OBJECTS) $(hell_DEPENDENCIES) $(libdir)/libhello.la hc-minusL: $(hell_OBJECTS) $(hell_DEPENDENCIES) @rm -f hc-minusL - @eval `egrep -e '^(hardcode_.*|wl)=' libtool`; \ + @$(SET_HARDCODE_FLAGS); \ libdir=$(libdir); \ flag=`eval echo \"$$hardcode_libdir_flag_spec\"`; \ echo "$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(hell_OBJECTS) -L./$(objdir) -lhello $(LIBS) $(LIBM) $$flag || echo unsupported > $@"; \