e4ab46
Ensure that $(LIBLTDL) is built first
e4ab46
e4ab46
After Automake upstream commit f4e91bfc490d, the list in 'all-am:' is
e4ab46
reordered for this test-case (*_LTLIBRARIES is before *_PROGRAMS), which
e4ab46
means that linker will fail to link 'old' binary.
e4ab46
e4ab46
Previously (with automake <= 1.16), it was matter of luck -- it worked if
e4ab46
(a) the build was serial (-j1), and/or (b) libtool-ltdl-devel package was
e4ab46
installed on the box so ./configure picked the system version of libltdl.
e4ab46
e4ab46
Users should anyways use system's ltdl, so this has low priority.
e4ab46
e4ab46
diff --git a/tests/old-ltdl-iface.at b/tests/old-ltdl-iface.at
e4ab46
index cee29089..6f9c8001 100644
e4ab46
--- a/tests/old-ltdl-iface.at
e4ab46
+++ b/tests/old-ltdl-iface.at
e4ab46
@@ -62,6 +62,9 @@ MOSTLYCLEANFILES =
e4ab46
 include ltdl/Makefile.inc
e4ab46
 bin_PROGRAMS = old
e4ab46
 old_LDADD = -Lltdl $(LIBLTDL)
e4ab46
+# TODO: if --with-included-ltdl was unused this would
e4ab46
+# generate useless dependency.
e4ab46
+old_DEPENDENCIES = $(LIBLTDL)
e4ab46
 ]])
e4ab46
 
e4ab46
 AT_DATA([old.c],
e4ab46
@@ -131,7 +134,7 @@ LT_AT_CHECK_LIBTOOLIZE([--ltdl=ltdl --nonrecursive --install], 0, [expout], [exp
e4ab46
 
e4ab46
 AT_CHECK([test -f ltdl/Makefile.inc])
e4ab46
 
e4ab46
-LT_AT_BOOTSTRAP([ignore], [-I m4], [], [--add-missing], [--force])
e4ab46
+LT_AT_BOOTSTRAP([ignore], [-I m4], [], [--add-missing], [--force], [--with-included-ltdl])
e4ab46
 
e4ab46
 LT_AT_EXEC_CHECK([./old], 0, [[...]])
e4ab46