]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Hack: define top_build_prefix for old autotools
authorAmos Jeffries <amosjeffries@squid-cache.org>
Sun, 1 Aug 2010 13:34:08 +0000 (07:34 -0600)
committerAmos Jeffries <amosjeffries@squid-cache.org>
Sun, 1 Aug 2010 13:34:08 +0000 (07:34 -0600)
This hack was removed during the libtool 2.2 upgrade.

The issue shows up as bundle builds failing to link libltdl/libltdlc.la
when they should in fact be linking ../libltdl/libltdlc.la in src/Makefile

It is caused by the macros of libtool 2.2 assuming the presence of
top_build_prefix but since autoconf 2.62 that was replaced with
ac_top_build_prefix and is no longer automatically defined in Makefile's.

Some distros also seem to have back-ported the removal of top_build_prefix
into their old autoconf causing macro version tests to fail.

configure.in

index 2bf7ab3398df0e8cdce2259303e713afb698e5e9..cdc4bcbe37014c701db006e20c7f309ced705936 100644 (file)
@@ -72,6 +72,14 @@ else
 fi
 
 LT_INIT([dlopen])
+if ! test "${ac_top_build_prefix}" = "";
+then
+       # LTDL v3-v7 macros assume the autoconf 2.62 variable top_build_prefix is defined
+       # But from autoconf 2.64 its called ac_top_build_prefix and not automatically added to the Makefile
+       # This fixes Linux LTDLv3-v7, and BSD LTDL v2.2
+       top_build_prefix=${ac_top_build_prefix}
+       AC_SUBST(top_build_prefix)
+fi
 LTDL_INIT
 LT_LIB_DLLOAD