* m4/libtool.m4, m4/ltdl.m4, m4/ltoptions.m4: Added commented out
empty macro definitions to match each AU_DEFUN to help aclocal
from automake-1.4 regexps find the right libtool macro files.
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,_LT_COMPILER_NO_RTTI,g
s,AC_LIBTOOL_PROG_COMPILER_PIC,_LT_COMPILER_PIC,g
s,AC_L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EN_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>
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.
Either set variables to allow a client to link with the installed
libltdl, or else compile a local libltdl as a convenience library.
* libtoolize.in (opt_ltdl): Removed in favour of...
(ltdldir): ...this, which is defaulted to "libltdl" or can be set
by the user with an argument to --ltdl.
(Main): Use it!
* doc/libtool.texi (Distributing libltdl): Improved documentation
on libltdl.
(Invoking libtoolize): Document new optional --ltdl target
directory argument.
* m4/libtool.m4 (AC_LIBTOOL_SYS_DYNAMIC_LINKER): Use it. Set
ldqnx.so linker type.
(AC_DEPLIBS_CHECK_METHOD): QNX6 uses GNU C++, with deplib
checking, so use pass_all.
(AC_LIBTOOL_PROG_COMPILER_PIC): Use -shared for QNX.
(_LT_LANG_CXX_CONFIG): QNX can make shared libraries.
* m4/ltdl.m4 (AC_LTDL_SYS_DLOPEN_DEPLIBS): QNX opens deplibs on
dlopen.
* NEWS: Updated.
* libltdl/argz_.h: ...to here, so as not to shadow system
argz.h when we `#include <argz.h>' for example.
#include stdlib.h and sys/types.h to ensure we get a size_t
definition.
* libltdl/argz.c (HAVE_CONFIG_H): Set it up how ltdl likes it when
used by another client.
* m4/argz.m4: New file.
(gl_FUNC_ARGZ): Try to find an error_t definition, and a system
argz.h.
* m4/ltdl.m4: Use it.
(AC_LTDL_FUNC_ARGZ): Removed.
* libltdl/lt__glibc.h: #include <argz.h> to pick up either the
system argz.h or our libltdl/argz.h if necessary.
* libltdl/Makefile.am (libltdl_la_SOURCES): Move argz.h from
here...
(ltdldata_DATA): ...here. Along with argz.c.
(argz.h): Generate from argz_.h if the system file is missing.
Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
them as libtool modules. Currently loader-preopen.c is linked
unconditionally and other appropriate loaders discovered by
AC_LTDL_DLLIB are built and linked in:
* libltdl/Makefile.am (libltdl_la_SOURCES): Add loader-preopen
module.
* m4/ltdl.m4 (AC_LTDL_DLLIB): Use AC_LIBOBJ to add appropriate
loaders to libltdl.
* libltdl/lt_system.h (LT_SCOPE): Moved to here.
* libltdl/ltdl.h (lt_dlloader, lt_user_data, lt_module)
(lt_module_open, lt_module_close, lt_find_sym, lt_dlloader_exit)
(struct lt_user_dlloader, lt_dlloader_next, lt_dlloader_find)
(lt_dlloader_name, lt_dlloader_data, lt_dlloader_add)
(lt_dlloader_remove): Moved declarations...
* libltdl/lt_loader.h: ...to here.
* libltdl/ltdl.c: Include lt_loader.h. Move loader implementation
code from here...
* 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: ...to here.
* tests/cdemo/Makefile.am, tests/demo/Makefile.am,
tests/depdemo/Makefile.am, tests/f77demo/Makefile.am,
tests/mdemo/Makefile.am, tests/mdemo2/Makefile.am,
tests/pdemo/Makefile.am, tests/tagdemo/Makefile.am (AM_CPPFLAGS):
Add -I$(top_srcdir)/../.. so that libltdl include files can be
written as #include <libltdl/lt_dlloader.h> and found correctly.
(argz_next, argz_stringify): Move from here...
* libltdl/argz.c: New file. ...to here.
* libltdl/lt__glibc.h: New file. Rename global symbols into the
lt__ namespace.
* libltdl/lt__private.h: Include lt__glibc.h.
* libltdl/Makefile.am (libltdl_la_SOURCES): Add new files.
(AM_CPPFLAGS): Add -DLTDL.
* libltdl/argz.h (argz_append, argz_create_sep, argz_insert)
(argz_next, argz_stringify): New file. Declare argz functions
here, including lt__glibc.h when LTDL is defined to rename global
symbols for libltdl.
* m4/ltdl.m4 (AC_LTDL_FUNC_ARGZ): Add argz to AC_LIBOBJ if any of
our argz_* functions are missing from the system libraries.
from here...
* libltdl/lt__private.h: ...to here. New file to declare ltdl's
internal interfaces.
* libltdl/ltdl.c: Include lt__private.h.
* m4/ltdl.m4 (AC_LIB_LTDL): Add lt_dirent to AC_LIBOBJ if all of
opendir, readdir and closedir are missing.
(AC_CHECK_HEADERS): Remove assert.h, ctype.h, errno.h, malloc.h,
stdio.h and stdlib.h; these headers are all available in standard
c89 environments and newer.
* libltdl/lt__private.h: Include them here unconditionally.
* libltdl/lt__dirent.c (opendir, readdir, closedir): New file.
Windows dirent emulation functions moved to here...
* libltdl/ltdl.c (opendir, readdir, closedir): ...from here.
* libltdl/lt__dirent.h: New file. Rename the global symbols from
lt__dirent.c into the lt__ namespace so they don't clash with
other libraries.
Factor out the bottom portability layer from ltdl. Code in this
layer has global symbols renamed by lt__pre89.h, and may not
refer to any symbols except those provided by the system libraries
or other code in the portability layer:
* libltdl/lt__pre89.h: New file. Rename all the symbols from
LTLIBOBJS into the lt__ namespace so that they don't clash with
other libraries.
* libltdl/ltdl.c (rpl_memcpy, rpl_memmove, rpl_strchr, rpl_strcmp)
(rpl_strrchr): Moved from here...
* libltdl/memcpy.c (memcpy): ...to here, and fixed void *
dereference bug...
* libltdl/memmove.c (memmove): ...to here, and fixed void *
dereference bug...
* libltdl/strchr.c (strchr): ...to here...
* libltdl/strcmp.c (strcmp): ...here...
* libltdl/strrchr.c (strrchr): ...and here.
* libltdl/Makefile.am (libltdl_la_SOURCES): Add lt__pre89.h.
(libltdl_la_LIBADD, libltdlc_la_LIBADD): Add $(LTLIBOBJS).
(ltdldata_DATA): Add replacement sources files.
* m4/ltdl.m4 (AC_LIB_LTDL): Do careful config.h and LTLIBOBJ
setting for missing pre89 functions.
$Revision: 1.1470 $ $Date: 2004/04/08 12:01:57 $
$top_srcdir.
* m4/ltdl.m4 (AC_LIB_LTDL): Run AC_CONFIG_HEADERS for the user if
necessary. Calculate filename from first argument to
AC_CONFIG_HEADERS, and substitute as CONFIG_H.
* libltdl/Makefile.am (AM_CPPFLAGS): Make sure we are searching in
$top_srcdir for headers.
(DEFS): Override the default HAVE_CONFIG_H with the config.h
filename.
(ltdl.lo): Reference config.h via $(CONFIG_H).
* libltdl/ltdl.c (HAVE_CONFIG_H): Ditto.
* 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.