2001-06-30 06:56:50 +08:00
|
|
|
## Process this file with autoconf to create configure. -*- autoconf -*-
|
2004-01-17 06:42:26 +08:00
|
|
|
# Copyright (C) 2001, 2004 Free Software Foundation, Inc.
|
2001-10-06 23:35:17 +08:00
|
|
|
#
|
|
|
|
# This program is free software; you can redistribute it and/or modify
|
|
|
|
# it under the terms of the GNU General Public License as published by
|
|
|
|
# the Free Software Foundation; either version 2 of the License, or
|
|
|
|
# (at your option) any later version.
|
|
|
|
#
|
|
|
|
# This program is distributed in the hope that it will be useful,
|
|
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
# GNU General Public License for more details.
|
|
|
|
#
|
|
|
|
# You should have received a copy of the GNU General Public License
|
|
|
|
# along with this program; if not, write to the Free Software
|
|
|
|
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
|
|
|
# 02111-1307 USA
|
|
|
|
|
|
|
|
|
2003-11-19 20:55:47 +08:00
|
|
|
AC_PREREQ(2.58) ## We use AS_HELP_STRING
|
2003-11-25 23:48:23 +08:00
|
|
|
## Oldest automake required for bootstrap is below in AM_INIT_AUTOMAKE.
|
2001-10-06 23:35:17 +08:00
|
|
|
|
|
|
|
|
|
|
|
## ------------------------ ##
|
|
|
|
## Autoconf initialisation. ##
|
|
|
|
## ------------------------ ##
|
2004-10-05 09:00:39 +08:00
|
|
|
AC_INIT([libtool], [2.1a], [bug-libtool@gnu.org])
|
2004-01-17 06:03:19 +08:00
|
|
|
AC_CONFIG_HEADERS([config.h:config-h.in])
|
My thanks to Alexandre Duret-Lutz <adl@gnu.org> for the insight
required to write this changeset -- especially that ltmain.sh is
the same on any machine for a given release, which I hadn't
noticed for some bizarre reason: It turns out that generating
distributed files from configure causes no end of hassle, as
evidenced by the many patches I've generated over the last few
days to try and get the dist and distcheck make rules to work.
Instead of all that hair, we now simply generate our distributed
files (now including ltmain.sh) with make rules -- and since
automake creates make variables for all AC_SUBSTs, that is really
easy. The code looks a lot more like automake and autoconf
Makefile.ams now, and doesn't have all the rough edges the earlier
hacky solution suffered from. We still generate libtool from
config.status, but that is not a distributed file, and doesn't
break the golden rule. Besides, there is way more going on there
than a bunch of substitutions:
* Makefile.am (edit): New common sed substitutions for files now
generated by make instead of config.status.
(CLEANFILES): Clean new tmp files.
(EXTRA_DIST): Add ltmain.sh.
(vcl-tmp): Reinstated.
(m4/ltversion.m4, config/ltmain.sh): New rules. Generate from
here instead of config.status.
(libtoolize): Ditto.
(libtool): Call config.status to regenerate if necessary.
(dist-hook): Removed.
* config/ltmain.in: Moved here from top_srcdir.
* README-alpha: Update instructions to check AS_SHELL_SANITIZE is
up to date.
* bootstrap: Rewritten. Generate m4/ltversion.m4 and
config/ltmain.sh because configure depends on them.
* configure.ac (AC_CONFIG_SRCDIR): Use libtoolize.in now that
ltmain.in has moved.
(AC_CONFIG_FILES): Don't generate distributed files,
config/ltmain.sh and libtoolize from config.status. We have make
rules to do that now.
2004-07-31 07:02:39 +08:00
|
|
|
AC_CONFIG_SRCDIR([libtoolize.in])
|
* bootstrap: Rewritten to use autoreconf.
* config.guess, config.sub, mkstamp: Moved from here...
* config/config.guess, config/config.sub, config/mkstamp: ...to
here, respectively.
* libtool.m4, ltdl.m4: Moved from here...
* m4/libtool.m4, m4/ltdl.m4: ...to here, respectively.
* configure.ac: Removed various acinclude.m4 hackery, as these
files are no longer needed with automake 1.8.
* Makefile.am: Removed various acinclude.m4 hackery, as these
files are no longer needed with automake 1.8.
(AUTOMAKE_OPTIONS): Require CVS automake.
(CONF_SUBDIRS, CFLAGS, CPPFLAGS, LDFLAGS, LIBS, FFLAGS, FLIBS):
Automake now makes a Make variable from every AC_SUBST, so these
are NOP.
(aclocal_macros): These files are now in their own m4 subdir.
Changed all clients.
(EXTRA_DIST): mkstamp has moved to the new config subdir. Changed
all clients.
(pkgdata_SCRIPTS): Ditto wrt config.guess and config.sub.
(pkgdata_DATA): Ditto wrt ltmain.sh.
* f77demo/configure.ac, libltdl/configure.ac (AM_CONFIG_HEADER):
Is deprecated in favour of AC_CONFIG_HEADERS. Updated to the
latter.
* Makefile.am, cdemo/Makefile.am, demo/Makefile.am,
depdemo/Makefile.am, f77demo/Makefile.am, mdemo/Makefile.am,
mdemo2/Makefile.am, pdemo/Makefile.am, tagdemo/Makefile.am
(EXTRA_DIST): Remove acinclude.m4.
(ACLOCAL_AMFLAGS): Search new `m4' macro directory.
* configure.ac, cdemo/configure.ac, demo/configure.ac,
depdemo/configure.ac, f77demo/configure.ac, mdemo/configure.ac,
mdemo2/configure.ac, pdemo/configure.ac, tagdemo/configure.ac
(AC_CONFIG_AUX_DIR): Declare that config helper scripts are now
kept in the new config subdir.
* libltdl/configure.ac (AC_CONFIG_AUX_DIR): Removed. Defaults to
`.' anyway.
2003-09-25 19:22:29 +08:00
|
|
|
AC_CONFIG_AUX_DIR([config])
|
2001-10-06 23:35:17 +08:00
|
|
|
|
2003-10-15 16:44:52 +08:00
|
|
|
|
|
|
|
## ------------------------ ##
|
|
|
|
## Autotest initialisation. ##
|
|
|
|
## ------------------------ ##
|
|
|
|
|
2004-10-16 22:43:48 +08:00
|
|
|
AC_CONFIG_TESTDIR([tests])
|
|
|
|
AC_SUBST([AUTOM4TE], [autom4te])
|
|
|
|
AC_SUBST([AUTOTEST], ['$(AUTOM4TE) --language=autotest'])
|
Refactor all the test case common code into shell functions in
tests/defs, and move the various demo directories out of
$top_srcdir, and into tests too. The refactoring showed up a
number of inconsistencies and latent bugs, as well as fixing (I
think!!) the long-standing annoyance with some of the tests giving
spurious failures intermittently. While I was here, emacs kindly
removed a lot of bogus whitespace and added copyright notices for
us:
* cdemo, demo, depdemo, f77demo, mdemo, mdemo2, pdemo, tagdemo:
Moved from here...
* tests/cdemo, tests/demo, tests/depdemo, tests/f77demo,
tests/mdemo, tests/mdemo2, tests/pdemo, tests/tagdemo: ...to
here.
* tests/defs: Factor much common functionality from the test
scripts into shell functions. Added a copyright notice.
* tests/assign.test, tests/cdemo-conf.test, tests/cdemo-exec.test,
tests/cdemo-make.test, tests/cdemo-shared.test,
tests/cdemo-static.test, tests/demo-conf.test,
tests/demo-deplibs.test, tests/demo-exec.test,
tests/demo-inst.test, tests/demo-make.test,
tests/demo-nofast.test, tests/demo-nopic.test,
tests/demo-pic.test, tests/demo-shared.test,
tests/demo-static.test, tests/demo-unst.test,
tests/depdemo-conf.test, tests/depdemo-exec.test,
tests/depdemo-inst.test, tests/depdemo-make.test,
tests/depdemo-nofast.test, tests/depdemo-shared.test,
tests/depdemo-static.test, tests/depdemo-unst.test,
tests/f77demo-conf.test, tests/f77demo-exec.test,
tests/f77demo-make.test, tests/f77demo-shared.test,
tests/f77demo-static.test, tests/link-2.test, tests/link.test,
tests/mdemo-conf.test, tests/mdemo-exec.test,
tests/mdemo-inst.test, tests/mdemo-make.test,
tests/mdemo-shared.test, tests/mdemo-static.test,
tests/mdemo-unst.test, tests/mdemo2-conf.test,
tests/mdemo2-exec.test, tests/mdemo2-make.test, tests/nomode.test,
tests/pdemo-conf.test, tests/pdemo-exec.test,
tests/pdemo-inst.test, tests/pdemo-make.test,
tests/pdemo-unst.test, tests/quote.test, tests/sh.test,
tests/suffix.test, tests/tagdemo-conf.test,
tests/tagdemo-exec.test, tests/tagdemo-make.test,
tests/tagdemo-shared.test, tests/tagdemo-static.test: Refactored
to use new functions in tests/defs. Added a copyright notice.
* tests/hardcode.test, noinst-link.test,
tests/relink.test, tests/relink.test,
tests/mdryrun.test: Ditto. Moved from here...
* tests/demo-hardcode.test, demo-noinst-link.test,
tests/demo-relink.test, tests/depdemo-relink.test,
tests/mdemo-dryrun.test: ...to here respectively.
* Makefile.am: Added a copyright notice.
* tests/sh.test: Check libtoolize.in for non-portabilities too.
* libtoolize.in: Fix non-portabilities found by tests/sh.test.
2003-10-15 05:45:03 +08:00
|
|
|
|
2001-10-06 23:35:17 +08:00
|
|
|
|
|
|
|
## ---------------------------------------- ##
|
|
|
|
## Display a configure time version banner. ##
|
|
|
|
## ---------------------------------------- ##
|
1999-01-23 02:04:51 +08:00
|
|
|
|
2003-11-22 18:03:13 +08:00
|
|
|
# Calculating the previous version is somewhat involved, so do it once
|
|
|
|
# here, and SUBST the result for the maintainer release rules. The
|
|
|
|
# versioning scheme we use is described here:
|
|
|
|
# http://www.gnu.org/software/libtool/contribute.html
|
|
|
|
|
|
|
|
# First we break the version number up into its constituent parts.
|
2004-02-06 22:38:56 +08:00
|
|
|
lt_major=`echo "AC_PACKAGE_VERSION" | sed ['s,\..*$,,g']`
|
|
|
|
lt_minor=`echo "AC_PACKAGE_VERSION" | sed ['s,^[0-9]*\.\([0-9]*\).*$,\1,']`
|
|
|
|
lt_micro=`echo "AC_PACKAGE_VERSION" | sed ['s,^[0-9]*\.[0-9]*\(\.[0-9]*\).*$,\1,']`
|
|
|
|
lt_alpha=`echo "AC_PACKAGE_VERSION" | sed ['s,^[0-9.]*,,']`
|
2003-11-22 18:03:13 +08:00
|
|
|
|
2004-02-06 22:38:56 +08:00
|
|
|
test "$lt_minor" = "AC_PACKAGE_VERSION" && lt_minor=0
|
|
|
|
test "$lt_micro" = "AC_PACKAGE_VERSION" && lt_micro=""
|
2003-11-22 18:03:13 +08:00
|
|
|
|
|
|
|
# Then we try to work out what the release before this one would have been
|
|
|
|
# numbered. The only time we come unstuck is when this is the first release
|
2004-02-06 22:38:56 +08:00
|
|
|
# from a stable branch (lt_micro=lt_alpha=""), so LASTRELEASE is the last
|
2003-11-22 18:03:13 +08:00
|
|
|
# release from the old stable branch, and we don't know what version that
|
|
|
|
# was, so leave it unset so that the Makefile can complain.
|
2004-02-06 22:38:56 +08:00
|
|
|
case $lt_alpha in
|
2003-11-22 18:03:13 +08:00
|
|
|
[[ab]])
|
2004-02-06 22:38:56 +08:00
|
|
|
case $lt_micro in
|
2003-11-22 18:03:13 +08:00
|
|
|
[.[01]])
|
2004-02-06 22:38:56 +08:00
|
|
|
LASTRELEASE="$lt_major.$lt_minor" ;;
|
2003-11-22 18:03:13 +08:00
|
|
|
*)
|
2004-02-06 22:38:56 +08:00
|
|
|
LASTRELEASE="$lt_major.$lt_minor$lt_micro" ;;
|
2003-11-22 18:03:13 +08:00
|
|
|
esac
|
|
|
|
;;
|
|
|
|
[[cegikmoqsuwy]])
|
|
|
|
LASTRELEASE=`echo "AC_PACKAGE_VERSION" | tr 'c-y' 'b-w'` ;;
|
|
|
|
[[dfhjlnprtvxz]])
|
|
|
|
LASTRELEASE=`echo "AC_PACKAGE_VERSION" | tr 'd-z' 'b-x'` ;;
|
2004-02-06 22:38:56 +08:00
|
|
|
*) # No lt_alpha component
|
|
|
|
case $lt_micro in
|
2003-11-22 18:03:13 +08:00
|
|
|
.0)
|
|
|
|
LASTRELEASE="" ;;
|
|
|
|
.1)
|
2004-02-06 22:38:56 +08:00
|
|
|
LASTRELEASE="$lt_major.$lt_minor" ;;
|
2003-11-22 18:03:13 +08:00
|
|
|
.*)
|
2004-02-06 22:38:56 +08:00
|
|
|
lt_micro_value=`echo $lt_micro | sed 's,^\.,,'`
|
|
|
|
LASTRELEASE="$lt_major.$lt_minor.`expr $lt_micro_value - 1`" ;;
|
2003-11-22 18:03:13 +08:00
|
|
|
*)
|
|
|
|
LASTRELEASE="" ;;
|
|
|
|
esac
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
AC_SUBST([LASTRELEASE])
|
|
|
|
|
1999-01-22 22:09:12 +08:00
|
|
|
# This is a sanity check so we can see which version is used in bug reports.
|
|
|
|
# It is assumed that we only want to see the date extension for cvs libtool
|
|
|
|
# versions (i.e. "odd" letters) and not actual alpha releases.
|
2004-07-29 00:14:01 +08:00
|
|
|
TIMESTAMP=`${CONFIG_SHELL} ${ac_aux_dir}/mkstamp < ${srcdir}/ChangeLog`
|
|
|
|
package_revision=`( set $TIMESTAMP; echo $1; )`
|
2004-02-06 22:38:56 +08:00
|
|
|
case $lt_alpha in
|
2004-07-29 00:14:01 +08:00
|
|
|
[[bdfhjlnprtvxz]])
|
|
|
|
TIMESTAMP=
|
1999-01-22 22:09:12 +08:00
|
|
|
;;
|
2001-09-22 22:20:17 +08:00
|
|
|
esac
|
2004-07-29 00:14:01 +08:00
|
|
|
AS_BOX([Configuring AC_PACKAGE_TARNAME${TIMESTAMP:+" (Build:$TIMESTAMP)"} AC_PACKAGE_VERSION])
|
|
|
|
echo
|
2001-10-06 23:35:17 +08:00
|
|
|
AC_SUBST([TIMESTAMP])
|
2004-07-29 00:14:01 +08:00
|
|
|
AC_SUBST([package_revision])
|
2001-10-06 23:35:17 +08:00
|
|
|
|
|
|
|
|
2001-10-31 07:35:59 +08:00
|
|
|
## ------------------------ ##
|
|
|
|
## Automake Initialisation. ##
|
|
|
|
## ------------------------ ##
|
2003-11-25 23:48:23 +08:00
|
|
|
|
|
|
|
dnl These are bootstrap requirements, once built, libtool may work with
|
|
|
|
dnl much older releases of autoconf and automake. See release notes.
|
2004-09-16 22:57:02 +08:00
|
|
|
AM_INIT_AUTOMAKE([1.8 gnits dist-bzip2]) ## We use auto-m4_including
|
2001-10-31 07:35:59 +08:00
|
|
|
|
2004-09-23 09:16:41 +08:00
|
|
|
dnl We use m4sh to generate libtool's portable shell scripts
|
2004-10-16 22:43:48 +08:00
|
|
|
AC_SUBST([M4SH], ['$(AUTOM4TE) --language=m4sh'])
|
2004-09-23 09:16:41 +08:00
|
|
|
|
2004-02-07 00:11:26 +08:00
|
|
|
dnl Make sure config.status is regenerated when the version timestamp changes
|
|
|
|
AC_SUBST([CONFIG_STATUS_DEPENDENCIES], ['$(top_builddir)/stamp-vcl'])
|
2001-10-31 07:35:59 +08:00
|
|
|
|
2001-10-06 23:35:17 +08:00
|
|
|
## ------------------------------- ##
|
|
|
|
## Libtool specific configuration. ##
|
|
|
|
## ------------------------------- ##
|
|
|
|
|
2004-11-15 09:03:14 +08:00
|
|
|
# The API version is the base version. We must guarantee
|
|
|
|
# compatibility for all releases with the same API version.
|
|
|
|
# Our current rule is that:
|
|
|
|
# * All releases, including the prereleases, in an X.Y series
|
|
|
|
# are compatible. So 2.0.1c is compatible with 2.0.
|
|
|
|
# * Prereleases on the trunk are all incompatible -- 2.1b and 2.1c
|
|
|
|
# aren't the same.
|
|
|
|
APIVERSION=`echo "$VERSION" | sed -e 's/^\([[0-9]]*\.[[0-9]]*[[a-z]]*\).*$/\1/'`
|
|
|
|
AC_SUBST([APIVERSION])
|
2004-12-13 00:24:28 +08:00
|
|
|
AC_SUBST([aclocaldir], ["\${datadir}/aclocal"])
|
2004-11-15 09:03:14 +08:00
|
|
|
AC_SUBST([pkgvdatadir], ["\${datadir}/$PACKAGE-$APIVERSION"])
|
|
|
|
AC_SUBST([pkgvmacrodir], ["\${datadir}/$PACKAGE-$APIVERSION/m4"])
|
2001-10-06 23:35:17 +08:00
|
|
|
|
|
|
|
AC_ARG_ENABLE(ltdl-install,
|
Run our configure.ac files through Autoconf 2.59's autoupdate, and
then tweak the results by hand:
* m4/libtool.m4 (AC_PROG_LD): In common with all the other
AC_PROG_ macros, AC_SUBST the discovered LD.
(AC_PROG_NM): Similarly for NM.
(LT_AC_PROG_SED): Similarly for SED.
* configure.ac: No need to SUBST NM and LD manually any more.
(AC_PREREQ): Conservatively downgrade from 2.59 to 2.54.
* tests/cdemo/configure.ac, tests/demo/configure.ac,
tests/depdemo/configure.ac, tests/f77demo/configure.ac,
tests/mdemo/configure.ac, tests/mdemo2/configure.ac,
tests/pdemo/configure.ac, tests/tagdemo/configure.ac: Ditto.
* m4/libtool.m4 (AM_PROG_LIBTOOL, AM_ENABLE_SHARED,
AM_ENABLE_STATIC, AM_DISABLE_SHARED, AM_DISABLE_STATIC,
AM_PROG_LD, AM_PROG_NM): AU_DEFUN these macros so autoupdate can
use the newer definitions.
2003-11-14 19:12:22 +08:00
|
|
|
[AS_HELP_STRING([--disable-ltdl-install], [do not install libltdl])])
|
2001-10-06 23:35:17 +08:00
|
|
|
if test x"${enable_ltdl_install+set}" != xset; then
|
|
|
|
enable_ltdl_install=yes
|
|
|
|
fi
|
|
|
|
|
2003-11-17 23:49:06 +08:00
|
|
|
# All subdirectories that are configured on demand, but that must be
|
|
|
|
# included in the distribution. This substitution is for tests/Makefile.am,
|
|
|
|
# so the directory names are relative to that directory.
|
|
|
|
CONF_SUBDIRS="cdemo demo depdemo f77demo mdemo mdemo2 pdemo tagdemo"
|
2001-10-06 23:35:17 +08:00
|
|
|
AC_SUBST([CONF_SUBDIRS])
|
|
|
|
|
|
|
|
DIST_MAKEFILE_LIST=
|
|
|
|
for dir in $CONF_SUBDIRS; do
|
2003-11-17 23:49:06 +08:00
|
|
|
DIST_MAKEFILE_LIST="${DIST_MAKEFILE_LIST}tests/$dir/Makefile "
|
2001-10-06 23:35:17 +08:00
|
|
|
done
|
|
|
|
AC_SUBST([DIST_MAKEFILE_LIST])
|
|
|
|
|
|
|
|
|
2004-11-15 09:03:14 +08:00
|
|
|
# Test for ln. We need use it to install the versioned binaries.
|
|
|
|
AC_MSG_CHECKING([whether ln works])
|
|
|
|
AC_CACHE_VAL([am_cv_prog_ln], [
|
|
|
|
rm -f conftest conftest.file
|
|
|
|
: >conftest.file
|
|
|
|
if ln conftest.file conftest 2>/dev/null; then
|
|
|
|
am_cv_prog_ln=ln
|
|
|
|
else
|
|
|
|
am_cv_prog_ln='cp -p'
|
|
|
|
fi
|
|
|
|
rm -f conftest conftest.file])
|
|
|
|
AC_SUBST([LN], [$am_cv_prog_ln])
|
|
|
|
result=no
|
|
|
|
test "x$am_cv_prog_ln" = xln && result=yes
|
|
|
|
AC_MSG_RESULT([$result])
|
|
|
|
|
2001-10-06 23:35:17 +08:00
|
|
|
|
|
|
|
## ---------------- ##
|
|
|
|
## compiler checks. ##
|
|
|
|
## ---------------- ##
|
1997-04-02 02:29:23 +08:00
|
|
|
|
2004-08-31 04:27:17 +08:00
|
|
|
# Need to be sure that we have a working C compiler, otherwise even with
|
|
|
|
# a good C compiler: if the following C++ tests fail, the whole libtool
|
|
|
|
# build fails!
|
|
|
|
AC_PROG_CC
|
|
|
|
AC_PROG_CPP
|
|
|
|
|
2001-10-06 23:35:17 +08:00
|
|
|
## ----------------------- ##
|
|
|
|
## Libtool initialisation. ##
|
|
|
|
## ----------------------- ##
|
2004-04-16 01:05:26 +08:00
|
|
|
LT_INIT([dlopen win32-dll])
|
The Grand Renaming. In preparation for libtool-2.0, move all of
the many and varied m4 symbols accumulated by libtool over the
years, considering also that modern autoconf can detect unexpanded
macros even without AC in the macro name:
* bootstrap: Remove libltdl/config.h from previous releases.
* m4/libtool.m4, m4/ltdl.m4, doc/libtool.texi: Basically, run a
giant sed transformation like this:
s,AC_LIB_LTDL,LTDL_INIT,g
s,AC_LIBLTDL_CONVENIENCE,LTDL_CONVENIENCE,g
s,AC_LIBLTDL_INSTALLABLE,LTDL_INSTALLABLE,g
s,AC_WITH_LTDL,LT_WITH_LTDL,g
s,AC_LTDL_ENABLE_INSTALL,_LT_ENABLE_INSTALL,g
s,AC_DEPLIBS_CHECK_METHOD,_LT_CHECK_MAGIC_METHOD,g
s,AC_LIBTOOL_OBJDIR,_LT_CHECK_OBJDIR,g
s,AC_LTDL_OBJDIR,_LT_CHECK_OBJDIR,g
s,AC_LTDL_DLPREOPEN,_LT_CHECK_DLPREOPEN,g
s,AC_LIBTOOL_SYS_MAX_CMD_LEN,LT_CMD_MAX_LEN,g
s,AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE,_LT_CMD_GLOBAL_SYMBOLS,g
s,AC_LIBTOOL_SYS_OLD_ARCHIVE,_LT_CMD_OLD_ARCHIVE,g
s,AC_PROG_LD_RELOAD_FLAG,_LT_CMD_RELOAD,g
s,AC_LIBTOOL_SYS_LIB_STRIP,_LT_CMD_STRIPLIB,g
s,AC_CHECK_LIBM,LT_LIB_M,g
s,AC_LTDL_DLLIB,LT_LIB_DLLOAD,g
s,AC_LIBTOOL_COMPILER_OPTION,_LT_COMPILER_OPTION,g
s,AC_LIBTOOL_PROG_CC_C_O,_LT_COMPILER_C_O,g
s,AC_LIBTOOL_PROG_COMPILER_NO_RTTI,_L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ENABLE_LOCK,g
s,_LT_AC_CHECK_DLFCN,_LT_HEADER_DLFCN,g
s,_LT_AC_TRY_DLOPEN_SELF,_LT_TRY_DLOPEN_SELF,g
s,LT_AC_PROG_EGREP,_LT_DECL_EGREP,g
s,LT_AC_PROG_SED,_LT_DECL_SED,g
* doc/libtool.texi (Autoconf macros): Document exported macros.
* libtoolize.in: Compare ltdl.m4 serial numbers for LTDL_INIT
instead of newly obsoleted AC_LIB_LTDL.
(func_scan_files): Also set seen_ltdl for LTDL_INIT and
LT_WITH_LTDL.
* libltdl/ltdl.c (lt_dlforeachfile): LT_SYS_LIBSEARCH_PATH is not
an environment variable, it is an actual path.
Reported by Noah Mish <noah@cs.caltech.edu>
2004-08-23 06:02:07 +08:00
|
|
|
LTDL_INIT
|
2001-06-25 01:55:52 +08:00
|
|
|
|
2004-04-16 01:05:26 +08:00
|
|
|
# Enable all the language support we can
|
|
|
|
LT_LANG(C++)
|
|
|
|
LT_LANG(Fortran 77)
|
|
|
|
LT_LANG(Java)
|
|
|
|
LT_LANG(Windows Resource)
|
|
|
|
|
* configure.in (AC_CONFIG_DIRS): configure only libltdl, and then,
only if --enable-ltdl-install
(CONF_SUBDIRS): list directories that are configured on demand,
but that must be included in the distribution
(ACINCLUDE_M4_LIST, DIST_MAKEFILE_LIST): generated from CONF_SUBDIRS
* Makefile.am (AUTOMAKE_OPTIONS): added version 1.3e and
readme-alpha, to handle README-alpha automatically
(EXTRA_DIST): removed README-alpha
(BUILD_SUBDIRS): subdirectories that are always built
(SUBDIRS): BUILD_SUBDIRS plus BUILD_LTDL
(DIST_SUBDIRS): BUILD_SUBDIRS plus CONF_SUBDIRS, from configure
(all-local, check-local): depend on $(ACINCLUDE_M4_LIST), from
configure, and libtool, so that it is built before subdirs
(configure-subdirs): new target
(configure-subdirs, distdir): depend on $(DIST_MAKEFILE_LIST),
from configure
(@DIST_MAKEFILE_LIST@): create subdir if needed, then run
configure.
On-demand configuration of subdirs at distribution time was
suggested by Gary V. Vaughan <gvaughan@oranda.demon.co.uk>
1999-01-13 18:41:07 +08:00
|
|
|
|
2004-03-24 22:10:25 +08:00
|
|
|
## --------------------------- ##
|
|
|
|
## Work out which tests to run ##
|
|
|
|
## --------------------------- ##
|
2004-10-06 21:49:22 +08:00
|
|
|
AM_CONDITIONAL(HAVE_CXX,[test -n "[$]_LT_TAGVAR(compiler, CXX)"])
|
|
|
|
AM_CONDITIONAL(HAVE_F77,[test -n "[$]_LT_TAGVAR(compiler, F77)"])
|
The Grand Renaming. In preparation for libtool-2.0, move all of
the many and varied m4 symbols accumulated by libtool over the
years, considering also that modern autoconf can detect unexpanded
macros even without AC in the macro name:
* bootstrap: Remove libltdl/config.h from previous releases.
* m4/libtool.m4, m4/ltdl.m4, doc/libtool.texi: Basically, run a
giant sed transformation like this:
s,AC_LIB_LTDL,LTDL_INIT,g
s,AC_LIBLTDL_CONVENIENCE,LTDL_CONVENIENCE,g
s,AC_LIBLTDL_INSTALLABLE,LTDL_INSTALLABLE,g
s,AC_WITH_LTDL,LT_WITH_LTDL,g
s,AC_LTDL_ENABLE_INSTALL,_LT_ENABLE_INSTALL,g
s,AC_DEPLIBS_CHECK_METHOD,_LT_CHECK_MAGIC_METHOD,g
s,AC_LIBTOOL_OBJDIR,_LT_CHECK_OBJDIR,g
s,AC_LTDL_OBJDIR,_LT_CHECK_OBJDIR,g
s,AC_LTDL_DLPREOPEN,_LT_CHECK_DLPREOPEN,g
s,AC_LIBTOOL_SYS_MAX_CMD_LEN,LT_CMD_MAX_LEN,g
s,AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE,_LT_CMD_GLOBAL_SYMBOLS,g
s,AC_LIBTOOL_SYS_OLD_ARCHIVE,_LT_CMD_OLD_ARCHIVE,g
s,AC_PROG_LD_RELOAD_FLAG,_LT_CMD_RELOAD,g
s,AC_LIBTOOL_SYS_LIB_STRIP,_LT_CMD_STRIPLIB,g
s,AC_CHECK_LIBM,LT_LIB_M,g
s,AC_LTDL_DLLIB,LT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ACKSLASH,_LT_PROG_ECHO_BACKSLASH,g
s,_LT_AC_SYS_LIBPATH_AIX,_LT_SYS_MODULE_PATH_AIX,g
s,_LT_AC_SHELL_INIT,_LT_SHELL_INIT,g
s,_LT_AC_LOCK,_LT_ENABLE_LOCK,g
s,_LT_AC_CHECK_DLFCN,_LT_HEADER_DLFCN,g
s,_LT_AC_TRY_DLOPEN_SELF,_LT_TRY_DLOPEN_SELF,g
s,LT_AC_PROG_EGREP,_LT_DECL_EGREP,g
s,LT_AC_PROG_SED,_LT_DECL_SED,g
* doc/libtool.texi (Autoconf macros): Document exported macros.
* libtoolize.in: Compare ltdl.m4 serial numbers for LTDL_INIT
instead of newly obsoleted AC_LIB_LTDL.
(func_scan_files): Also set seen_ltdl for LTDL_INIT and
LT_WITH_LTDL.
* libltdl/ltdl.c (lt_dlforeachfile): LT_SYS_LIBSEARCH_PATH is not
an environment variable, it is an actual path.
Reported by Noah Mish <noah@cs.caltech.edu>
2004-08-23 06:02:07 +08:00
|
|
|
AM_CONDITIONAL(HAVE_GCJ, [test -n "[$]_LT_TAGVAR(compiler, GCJ)"])
|
|
|
|
AM_CONDITIONAL(HAVE_RC, [test -n "[$]_LT_TAGVAR(compiler, RC)"])
|
2004-03-24 22:10:25 +08:00
|
|
|
|
* configure.in (AC_CONFIG_DIRS): configure only libltdl, and then,
only if --enable-ltdl-install
(CONF_SUBDIRS): list directories that are configured on demand,
but that must be included in the distribution
(ACINCLUDE_M4_LIST, DIST_MAKEFILE_LIST): generated from CONF_SUBDIRS
* Makefile.am (AUTOMAKE_OPTIONS): added version 1.3e and
readme-alpha, to handle README-alpha automatically
(EXTRA_DIST): removed README-alpha
(BUILD_SUBDIRS): subdirectories that are always built
(SUBDIRS): BUILD_SUBDIRS plus BUILD_LTDL
(DIST_SUBDIRS): BUILD_SUBDIRS plus CONF_SUBDIRS, from configure
(all-local, check-local): depend on $(ACINCLUDE_M4_LIST), from
configure, and libtool, so that it is built before subdirs
(configure-subdirs): new target
(configure-subdirs, distdir): depend on $(DIST_MAKEFILE_LIST),
from configure
(@DIST_MAKEFILE_LIST@): create subdir if needed, then run
configure.
On-demand configuration of subdirs at distribution time was
suggested by Gary V. Vaughan <gvaughan@oranda.demon.co.uk>
1999-01-13 18:41:07 +08:00
|
|
|
|
2001-10-06 23:35:17 +08:00
|
|
|
## -------- ##
|
|
|
|
## Outputs. ##
|
|
|
|
## -------- ##
|
2004-07-29 00:14:01 +08:00
|
|
|
AC_CONFIG_FILES([Makefile libltdl/Makefile libltdl/loaders/Makefile
|
This pervasive changeset makes two intertwined deep changes to the
operation of libtool (neither would work alone). First, there is
a new feature that allows libraries to preopen modules. This
entails a backwards incompatible change to the libltdl API for
separating out the preloaded symbol lists by owner. Second, in
the tradition of "eating our own dogfood", libltdl now preloads
its own dlloaders. The internal API for dlloaders has also had to
change in a backwards incompatible way in support of the new
library preloading feature. If you don't use preloaded libraries,
you needn't change your project sources, though you will need to
recompile against the new libltdl. The API changes are mostly
confined to dlloaders, so you probably needn't worry about those
(unless you have written a custom loader that you want libltdl to
use):
* configure.ac (AC_CONFIG_FILES): Add libltdl/loaders/Makefile.
* libltdl/configure.ac (AC_CONFIG_FILES): Add loaders/Makefile.
* libltdl/loaders: New directory for module loaders, to simplify
Makefile rules, and to give the loaders themselves names that are
unique in the first few characters.
* libtoolize.in (func_copy_all_files): Copy recursively to pick up
the loaders directory contents.
* libltdl/loaders/Makefile.am: New file. Move module building
rules to here...
* libltdl/Makefile.am: ...from here.
(VERSION_INFO): Bumped version info to signify interface changes.
(libltdl_la_CPPFLAGS, libltdlc_la_CPPFLAGS): Set LTDLOPEN
appropriately for each library.
* libltdl/loader-dld_link.c, libltdl/loader-dlopen.c,
libltdl/loader-dyld.c, libltdl/loader-load_add_on.c,
libltdl/loader-loadlibrary.c libltdl/loader-preopen.c,
libltdl/loader-shl_load.c: Moved from here...
* libltdl/loaders/dld_link.c, libltdl/loaders/dlopen.c,
libltdl/loaders/dyld.c, libltdl/loaders/load_add_on.c,
libltdl/loaders/loadlibrary.c libltdl/loaders/preopen.c,
libltdl/loaders/shl_load.c: ...to here.
(get_vtable): New entry function for each.
* libltdl/loaders/preopen.c (lt_dlsymlists_t): Replaced by...
(symlist_chain): ...a new structure which maps lists of preloaded
symbols from the object that loads them.
(lt_dlpreload_open): New function to automatically open all
preloaded modules belonging to a named object (ORIGINATOR).
* libltdl/lt__alloc.c (lt__zalloc): New function to return a block
of zeroed out new memory.
* libltdl/lt__alloc.h (lt__zalloc): Prototype it.
* libltdl/lt__private.h (lt__alloc_die_callback): Add missing
prototype.
(lt__error_strings): Make this opaque to callers.
* libltdl/lt_error.c (lt__error_strings): Move the implementation
to here.
* libltdl/lt_dlloader.h (lt_user_dlloader): Add extra fields to
make originator focused preloading possible. *BREAKS BACKWARDS
COMPATIBILITY*
(lt_dlloader_add): Take advantage of new fields to simplify
paramater list.
* libltdl/lt_system.h (LT_STR): New ANSI stringification macro.
(LT_CONC): Fix it to work from within macros.
* libltdl/ltdl.c (loader_init, loader_init_callback): Simplify
dlloader loading.
(get_vtable, preloaded_symbols): Point these at the preopen.c
symbols to bootstrap the loader chain.
(lt_dlinit): Load the preopen dlloader manually, and then use it
to load any other preloaded dlloaders.
(lt_dlloader_add): Simplify parameter list. Populate new
fields. Chain new loaders according to priority field.
* libltdl/ltdl.h (lt_dlsymlist): Add a new originator field.
(lt_dlpreload_callback_func): Type of a callback for automatic
lt_dlpreload_open loading.
(LTDL_SET_PRELOADED_SYMBOLS): Adjust to hook into preloaded
symbols from the "@PROGRAM@" originator.
* tests/demo/dlmain.c (main): Use mangled preloaded_symbols symbol.
* tests/pdemo/longer_file_name_dlmain.c (main): Ditto.
* ltmain.in: Don't spew spurious warnings when dlopening and
dlpreopening modules.
(func_generate_dlsyms): Factored out from multiple copies in the
rest of the code. Generate originator keyed symbol lists.
(func_extract_archives): Also factored. Extract the contents of
convenience archives for linking with dependent libraries when
--whole-archive is not available.
[darwin]: Don't try to link $old_library unless it exists, and
$lib is a bundle.
* m4/ltdl.m4 (AC_LTDL_DLLIB): Check for all possible dynamic
loading libraries/apis rather that stopping when an acceptable one
is discovered.
(LT_DLLOADERS): New variable for holding dlloaders that can be
preloaded.
* doc/libtool.texi: Document interface changes.
* NEWS: Updated.
2004-07-15 20:14:48 +08:00
|
|
|
doc/Makefile tests/Makefile])
|
Libtool now builds with the help of Autoconf-2.50!
* configure.ac (AC_PREREQ): Require Autoconf-2.50 or newer.
(AC_PROG_CPP, AC_EXEEXT, AC_OBJEXT): Removed. Autoconf-2.50
doesn't have the AC_REQUIRE bug that required these to be called
explicitly from here. Autoconf-2.50 uses this file instead of...
* configure.in: ...this, which is now deleted.
* cdemo/configure.ac, cdemo/configure.in: Ditto.
* demo/configure.ac, demo/configure.in: Ditto.
* depdemo/configure.ac, depdemo/configure.in: Ditto.
* libltdl/configure.ac, libltdl/configure.in: Ditto.
* mdemo/configure.ac, mdemo/configure.in: Ditto.
* pdemo/configure.ac, pdemo/configure.in: Ditto.
* libltdl/acconfig.h: Deleted.
* Makefile.am (libtool): libtool now depends on configure.ac.
* libtool.m4 (_LT_AC_LOCK): Use 2.50's AC_LANG_PUSH/AC_LANG_POP
instead of 2.13's AC_LANG_SAVE/AC_LANG_RESTORE.
(AC_LIBTOOL_LANG_C_CONFIG): Ditto.
(AC_LIBTOOL_LANG_CXX_CONFIG): Ditto.
* libtoolize.in: Use $configure_ac, instead of hardcoding
configure.in.
2001-06-29 06:02:06 +08:00
|
|
|
AC_OUTPUT
|