+2005-08-25 Peter Ekberg <peda@lysator.liu.se>
+ Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
+
+ * tests/standalone.at: (without autotools): Add
+ $(CFLAGS) to LTCOMPILE and LTLINK. Separate compiling
+ and linking. Remove compiling flags from link. Add
+ --tag. Add -no-undefined flag.
+
2005-08-24 Bruno Haible <bruno@clisp.org>
* libltdl/config/ltmain.sh (func_mode_install): Try "ln -s -f"
AT_DATA([Makefile],
[[LIBTOOL = ./libltdl/libtool
INCLUDES = -I./libltdl
-MODFLAGS = -module -avoid-version
+MODFLAGS = -module -avoid-version -no-undefined
-LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(CPPFLAGS) $(INCLUDES)
-LTLINK = $(LIBTOOL) --mode=link $(CC) $(CPPFLAGS) $(INCLUDES) $(LDFLAGS)
+LTCOMPILE = $(LIBTOOL) --tag=CC $(LIBTOOLFLAGS) --mode=compile \
+ $(CC) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)
+LTLINK = $(LIBTOOL) --tag=CC $(LIBTOOLFLAGS) --mode=link \
+ $(CC) $(CFLAGS) $(LDFLAGS)
-TARGETS = libltdl/libltdlc.la module.la ltdldemo
+TARGETS = libltdl/libltdlc.la module.la ltdldemo$(EXEEXT)
all: $(TARGETS)
$(LIBTOOL) libltdl/libltdlc.la:
cd libltdl && ./configure && $(MAKE)
-ltdldemo: $(LIBTOOL) module.la libltdl/libltdlc.la main.c
- $(LTLINK) -o ltdldemo main.c -dlopen module.la ./libltdl/libltdlc.la
+ltdldemo$(EXEEXT): $(LIBTOOL) module.la libltdl/libltdlc.la main.lo
+ $(LTLINK) -o ltdldemo main.lo -dlopen module.la ./libltdl/libltdlc.la
+
+main.lo: $(LIBTOOL) main.c
+ $(LTCOMPILE) -c main.c
module.la: $(LIBTOOL) module.lo
$(LTLINK) -o module.la module.lo $(MODFLAGS) -rpath /dev/null
]])
LT_AT_LIBTOOLIZE([--copy --ltdl])
-${MAKE-make} CC="$CC" CPPFLAGS="$CPPFLAGS" CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS"
+${MAKE-make} CC="$CC" LIBTOOLFLAGS="$LIBTOOLFLAGS" CPPFLAGS="$CPPFLAGS" \
+ CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS"
AT_DATA([expout],
[[Hello!