Commit Graph

271 Commits

Author SHA1 Message Date
Ralf Wildenhues
34700eacf5 * libltdl/m4/libtool.m4 (_LT_COMPILER_PIC)
<lt_cv_prog_compiler_pic_works>: Renamed from
lt_prog_compiler_pic_works.
<lt_cv_prog_compiler_static_works>: Renamed from
lt_prog_compiler_static_works.
* NEWS: Update.
2007-10-11 17:23:33 +00:00
Ralf Wildenhues
e14f5d12ae * NEWS: Update. 2007-09-01 10:55:42 +00:00
Ralf Wildenhues
1e63751c04 * libltdl/m4/libtool.m4 (_LT_COMPILER_PIC, _LT_LINKER_SHLIBS)
(_LT_LANG_CXX_CONFIG) [ linux ]: Add support for IBM XL 8.0
C/C++ (xlc*, xlC*) and IBM XL Fortran 10.1 (xlf*) on GNU/Linux,
tested on ppc, pending a $shlibpath_var related fix.
(_LT_SYS_HIDDEN_LIBDEPS): Double-quote $output_verbose_link_cmd
properly during evaluation, obsoleting $no_glob_subst mangling.
* NEWS: Update.
2007-08-29 20:54:53 +00:00
Gary V. Vaughan
a894e3baee Add a test to simulate a failure visible on systems which
need a library prefix like 'lib', such as BeOS.  Fix a number
of bugs exposed by this test in order for it to pass.
Currently the prefix is hardcoded as 'lib', as I am not aware
of systems that require a different prefix:

* libltdl/loaders/preopen.c (lt_dlpreload_open):  Move error
condition out of test loop to be sure that each originator is
tried, instead of erroring out if the first doesn't match.
Support passing NULL as the originator to load all preloaded
modules originating in the program itself.
* libltdl/lt_dlloader.c (lt_dlloader_dump): New debug function.
* libltdl/libltdl/lt_dlloader.h (lt_dlloader_dump): Declare it
when LT_DEBUG_LOADERS is defined at compile time.
* libltdl/ltdl.c (lt_dlinit): Dump loader list after successful
initialisation.
(tryall_dlopen): Add a new VTABLE parameter to force use of a
specific loader in preference to trying every loader in turn.
Adjust all callers.
(try_dlopen): Always see whether a module was preloaded for
module names with no directory component before searching the
filesystem for a match.
* libltdl/m4/libtool.m4 (_LT_CMD_GLOBAL_SYMBOLS): Declare
a new global_symbol_to_c_name_address_lib_prefix variable.
(global_symbol_to_c_name_address_lib_prefix): The sed
expressions to use when a lib prefix is enforced need to be
slightly different to work with preloaded modules.
* libltdl/config/ltmain.m4sh (func_generate_dlsyms): In order
to name preloaded symbols correctly for the lookup algorithm
to work when the loaded module file must be prefixed with lib.
Use global_symbol_to_c_name_address_lib_prefix when
need_lib_prefix is other than no.
* tests/need_lib_prefix.at: New test to check for breakage on
hosts where need_lib_prefix is unknown.
* Makefile.am (TESTSUITE_AT): Add new test.
* tests/TODO: Note missing tests that would have caught some
of the latent bugs fixed by this patch.
* HACKING: Document libltdl keyword.
* NEWS: Updated.
2007-06-24 20:46:47 +00:00
Gary V. Vaughan
c823c708c8 Without this patch, lt_dlopen always opens modules with symbol
visibility set according to the underlying implementation.
Here, we add lt_dlopenadvise() to allow callers to request,
among other things, local or global symbol visibility from the
underlying dlloader:

* libltdl/ltdl.c (LT_DLRESIDENT_FLAG): Removed.
(LT_DLIS_RESIDENT): Use public is_resident info field.
(LT_DLIS_SYMLOCAL, LT_DLIS_SYMGLOBAL): New macros to test for
module symbol visibility status.
(tryall_dlopen): If vtable->module_open() was able to act on
either is_symlocal or is_symglobal hints, store that in
the handle flags.
(lt_dlopenadvise): New function that works like lt_dlopen(),
but accepts an advise type to determine whether to ask
dlloaders to change default symbol visibility.
(lt_dlopen, lt_dlopenext): Just call lt_dlopenadvise() with
the correct parameters.
(lt_dladvise_init, lt_dladvise_destroy): New functions to
initialize and destroy an advise type hint.
(lt_dladvise_ext, lt_dladvise_resident, lt_dladvise_local)
(lt_dladvise_global): Set hints on an advise type.
(openadvise): Factored out of lt_dlopenadvise.
(has_library_ext): Factored out of lt_dlopenadvise.
* libltdl/ltdl.h: Declare all of the above.
(lt_dlinfo): New fields for advise hints.
* libltdl/libltdl/lt_dlloader.h (lt_module_open): Add a new
advise parameter.  Adjust all callers.
(lt_dladvise): New opaque type for advise hints.
* libltdl/libltdl/lt__private.h (lt__advise): Declare
contents of opaque lt_dladvise type.
* libltdl/libltdl/lt_error.h (CONFLICTING_FLAGS): New error
for attempts to have local and global symbol visibility at the
same time.
* libltdl/loaders/dld_link.c, libltdl/loaders/dyld.c,
libltdl/loaders/load_add_on.c, libltdl/loaders/loadlibrary.c,
libltdl/loaders/preopen.c, libltdl/loaders/shl_load.c: Adjust.
* libltdl/loaders/dlopen.c (RTLD_LOCAL, RTLD_GLOBAL): Try to
define these symbols if the system has equivalents.
(vmopen): If unable to act on a caller request to set symbol
visibility, then unset the relevant hints in the advise type.
* tests/lt_dladvise.at: New tests for the above.
* doc/libtool.texi (Libltdl Interface): Updated.
* NEWS: Updated.
2007-05-08 14:38:50 +00:00
Ralf Wildenhues
06470c3a43 * libltdl/config/ltmain.m4sh (func_mode_link): Fix accumulation
of `inherited_linker_flags' entries from multiple deplibs, by
adding $new_inherited_linker_flags only once, only in link pass.
* tests/inherited_flags: Amend test to expose this.
* NEWS: Adjust: kill one regression, but add note about the
feature new in 1.9b.
Report by Jeff Squyres and others.
2007-04-23 17:10:17 +00:00
Gary V. Vaughan
c193153265 The stamp-vcl file rules caused non-gnu make programs to rerun
parts of the configuration process on each invocation.  Instead
of relying on a stamp file, we now compare version numbers of
generated files with the ChangeLog timestamp manually in the
affected make rules to decide whether regenerating is necessary:

* Makefile.am (EXTRA_DIST): Remove stamp-vcl.
(clean-ltmain-sh): Also remove users' obsolescent stamp-vcl.
(rebuild): Keep some common code here for...
(libtool, libltdl/m4/ltversion.m4, libltdl/config/ltmain.sh):
Rewritten to work without reference to intermediate stamp-vcl
file.
* configure.ac (CONFIG_STATUS_DEPENDENCIES): Change from
stamp-vcl to ChangeLog.
* NEWS: Removed entry saying this fix is needed.
2007-03-26 20:18:43 +00:00
Ralf Wildenhues
c003219f02 * libltdl/m4/libtool.m4 (_LT_SYS_DYNAMIC_LINKER)
(_LT_CHECK_MAGIC_METHOD, _LT_COMPILER_PIC, _LT_LINKER_SHLIBS)
(_LT_LANG_CXX_CONFIG, _LT_SYS_HIDDEN_LIBDEPS) [ interix ]: When
matching for interix, accept version range [3-9] instead of 3.
* NEWS: Update.
Report by Martin Koeppe <mkoeppe@gmx.de>.
2007-03-18 18:08:50 +00:00
Ralf Wildenhues
d2f789e3c7 * NEWS: Rewrite all news since 1.9f and put in categories,
update.
2007-02-27 22:15:45 +00:00
Charles Wilson
51e40f80fd * NEWS: Update for Cygwin changes. 2007-01-28 20:23:57 +00:00
Ralf Wildenhues
baf8599e6f Assume C89 for included headers, and throughout the testsuite.
* NEWS: Update.
* libltdl/argz.c: Do not include strings.h nor memory.h, include
string.h unconditionally.
Patch by Simon Josefsson <jas@extundo.com>.
* libltdl/libltdl/lt__private.h: Likewise.
* libltdl/m4/ltdl.m4 (LTDL_INIT): Do not check for string.h,
strings.h, memory.h.
* tests/cdemo/configure.ac: Assume presence of math.h.
* tests/cdemo/foo.c: Likewise.
* tests/demo/configure.ac: Likewise for math.h, string.h.
Assume 'const'.  Drop obsolete AC_EXEEXT.
* tests/demo/dlmain.c: Likewise.
* tests/demo/foo.c: Likewise.
* tests/depdemo/configure.ac: Likewise.
* tests/depdemo/l4/l4.c: Likewise.
* tests/f77demo/configure.ac: Likewise.  Also drop obsolete
AC_OBJEXT.
* tests/fcdemo/configure.ac: Likewise.
* tests/mdemo/configure.ac: Likewise.
* tests/mdemo/foo1.c: Likewise.
* tests/mdemo/foo2.c: Likewise.
* tests/mdemo2/configure.ac: Likewise.
* tests/pdemo/configure.ac: Likewise.
* tests/pdemo/longer_file_name_dlmain.c:
* tests/pdemo/longer_file_name_foo.c: Likewise.
* tests/pdemo/longer_file_name_foo2.c: Likewise.
* tests/tagdemo/configure.ac: Likewise.
* tests/tagdemo/foo.cpp: Likewise.
2007-01-27 16:45:40 +00:00
Ralf Wildenhues
148027b94c * NEWS: Account for recent multilib fix.
* tests/search-path.at: New test, to provide at least a weak
test.
* Makefile.am: Update.
2006-10-24 20:17:38 +00:00
Ralf Wildenhues
8f951c011f * libltdl/m4/libtool.m4 (_LT_LINKER_SHLIBS, _LT_LANG_CXX_CONFIG)
[ openbsd ]: Set `hardcode_direct_absolute', to prefer rpath
over putting absolute file names in NEEDED entries.
* NEWS: Update.
Reported by Jake Meuser and others.
2006-09-17 19:30:15 +00:00
Kurt Roeckx
956f27f44c * libltdl/m4/libtool.m4 (_LT_SYS_DYNAMIC_LINKER)
(_LT_CHECK_MAGIC_METHOD, _LT_COMPILER_PIC, _LT_LINKER_SHLIBS)
(_LT_LANG_CXX_CONFIG) [k*bsd*-gnu]: kfreebsd*-gnu and
knetbsd*-gnu behave like linux-gnu.
* libltdl/m4/ltdl.m4 (LT_SYS_DLOPEN_DEPLIBS): Likewise.
* libltdl/m4/libtool.m4 (_LT_ENABLE_LOCK)
[x86_64-*kfreebsd*-gnu]: Add 32/64 bit bi-arch support.
* NEWS: Update.
2006-08-25 15:04:30 +00:00
Bruno Haible
a84c618b61 * libltdl/m4/libtool.m4 (_LT_COMPILER_PIC, _LT_LINKER_SHLIBS)
(_LT_LANG_CXX_CONFIG, _LT_SYS_HIDDEN_LIBDEPS) [ linux ]:
Add support for Sun C 5.9, Sun C++ 5.9, and Sun Fortran 8.3 on
GNU/Linux.
* NEWS: Update.
2006-05-15 16:40:43 +00:00
John Bowler
ebfa770bf4 * libltdl/config/ltmain.m4sh (func_mode_link): For version_type
`none', we still need to set `current', `age', and `revision',
so that our checks don't barf.  The values won't be used later.
Apparently reported by several people, several times, for BeOS.
* NEWS, THANKS: Update.
2006-05-14 08:20:11 +00:00
Ralf Wildenhues
9e38ec274b * libltdl/m4/ltdl.m4 (LT_SYS_DLOPEN_DEPLIBS) [ freebsd ]
[ dragonfly ]: Set libltdl_cv_sys_dlopen_deplibs to yes.
Fixes excessive lt_dlopen times on these systems.
* NEWS, THANKS: Update.
Bug reported by Peter Jeremy <peterjeremy@optushome.com.au>,
patch by Joerg Sonnenberger <joerg@netbsd.org>.
2006-03-23 22:39:41 +00:00
Leif Ekblad
e425114109 * libltdl/m4/libtool.m4 (_LT_SYS_DYNAMIC_LINKER)
(_LT_CHECK_MAGIC_METHOD, _LT_COMPILER_PIC): Added support for
RDOS.
* NEWS: Updated.
2006-01-12 22:02:56 +00:00
Ralf Wildenhues
33c0290e19 Basic support for PIE (position-independent executables).
* libltdl/config/ltmain.m4sh (func_generate_dlsyms):
Don't pass PIE flag for compilation of the symbol file object.
* NEWS: Updated.
2005-12-03 08:48:15 +00:00
Todd Vierling
7389434efe * libltdl/m4/libtool.m4 (LT_CMD_MAX_LEN, _LT_SYS_DYNAMIC_LINKER)
(_LT_CHECK_MAGIC_METHOD, _LT_COMPILER_PIC, _LT_LINKER_SHLIBS)
(_LT_LANG_CXX_CONFIG) [ interix3 ]: Support for Interix/Microsoft
Services for Unix.
* libltdl/m4/ltdl.m4 (LT_SYS_DLOPEN_DEPLIBS): Likewise.
* NEWS: Updated.
2005-11-20 08:45:54 +00:00
Howard Chu
01f0aa7662 * libltdl/config/ltmain.m4sh (func_mode_link):
With `-static', only link statically against uninstalled
libtool libraries.  Fixes 1.5.x regression to match documented
behavior.
* NEWS: Updated.
2005-10-29 14:21:02 +00:00
Gary V. Vaughan
e1454ec7b4 * libltdl/Makefile.inc: New file, factored out of Makefile.am for
use in non-recursive libltdl installations.
* bootstrap: Adjust.
* Makefile.am: include it.
(libltdl/Makefile.am): Adjust to build from the new
libltdl/Makefile.inc.
(SUBDIR_LIBOBJS): Renamed from this...
(LTDL_SUBDIR_LIBOBJS): ...to this.
* configure.ac: Adjust.
* doc/libtool.texi (Invoking libtoolize): Document the new modes
and libtoolize option to select them.
* libtoolize.m4sh: Parse new options, --nonrecursive, --recursive
and --subproject.  Install the appropriate files with --ltdl
according to the selected mode.
(func_scan_files): If --subproject, --recursive or --nonrecursive
options were not given, use the value from LT_CONFIG_LTDL_DIR; if
a mode was given, and there is also an argument to
LT_CONFIG_LTDL_DIR, ensure they are the same.
* NEWS: Updated.
2005-10-26 10:42:05 +00:00
Gary V. Vaughan
04edc7871c * libltdl/ltdl.h, libltdl/ltdl.c (lt_dlhandle_first): Removed.
* libltdl/ltdl.h, libltdl/ltdl.c (lt_dlhandle_next)
(lt_dlhandle_find, lt_dlforeach): Removed...
(lt_dlhandle_iterate, lt_dlhandle_fetch, lt_dlhandle_map): Similar
functions that are multi-loader safe, and require a registered
interface validator argument.
* doc/libtool.texi: Updated.
* NEWS: Updated.
2005-10-26 10:26:48 +00:00
Gary V. Vaughan
9f6099490a * libltdl/m4/ltdl.m4: Bump serial as we are changing the
interface.
(LT_CONFIG_LTDL_DIR): New macro to centralise setting the
subdirectory used for libltdl.
(LTDL_CONVENIENCE): Continue backwards compatibility support for
declaring the libltdl source subdirectory with an argument, but
defer to LT_CONFIG_LTDL_DIR.
(AC_LIBLTDL_CONVENIENCE): Adjust to upgrade to the new style.
(LTDL_INSTALLABLE, AC_LIBLTDL_INSTALLABLE): Ditto.
(LTDL_INIT): lt_ltdl_dir is set by LT_CONFIG_LTDL_DIR now, and
even `./' needs trailing slashes trimming!  If the user didn't
upgrade their configure.ac yet, call LT_CONFIG_LTDL_DIR for them.
* libtoolize.m4sh (func_scan_files): If --ltdl option is given
without a directory argument, use the value from
LT_CONFIG_LTDL_DIR; if the argument is given, and there is also a
value in LT_CONFIG_LTDL_DIR, ensure they are the same.
* libltdl/configure.ac: Use it.
* NEWS: Updated.
2005-10-03 15:45:47 +00:00
Gary V. Vaughan
6db2a8ba58 * libltdl/ltdl.h (lt_dlmutex_register, lt_dlmutex_lock)
(lt_dlmutex_unlock, lt_dlmutex_seterror, lt_dlmutex_geterror)
(lt_dlmalloc, lt_dlrealloc, lt_dlfree): Remove deprecated APIs.
* doc/libtool.tex: Updated.
* NEWS: Updated.
2005-09-27 10:41:07 +00:00
Gary V. Vaughan
757d7dc478 Reorganise the libtool tree to create a bootstrapped libltdl for
installation to the libtoolize master tree, so that libltdl is
useable even in the extreme case of when automake and autoconf are
not installed on the developers machine.  Part of this change
requires some duplication of rules between Makefile.am (which
builds libltdl for this distribution) and libltdl/Makefile.am
(which is used by projects that libltoolize --ltdl --copy), so
libtool now really does use a single toplevel Makefile.am, and we
generate libltdl/Makefile.am from that:

* m4, config: Moved from here...
* libltdl/m4, libltdl/config: ...to here, to reduce the amount of
kludging needed in bootstrap for autoreconf to run.
* tests/cdemo/Makefile.am, tests/demo/Makefile.am,
tests/depdemo/Makefile.am, tests/f77demo/Makefile.am,
tests/fcdemo/Makefile.am, tests/mdemo/Makefile.am,
tests/mdemo2/Makefile.am, tests/pdemo/Makefile.am,
tests/tagdemo/Makefile.am (ACLOCAL_AMFLAGS): Adjust to
compensate.
* tests/cdemo/configure.ac, tests/demo/configure.ac,
tests/depdemo/configure.ac, tests/f77demo/configure.ac,
tests/fcdemo/configure.ac, tests/mdemo/configure.ac,
tests/mdemo2/configure.ac, tests/pdemo/configure.ac,
tests/tagdemo/configure.ac (AC_CONFIG_AUX_DIR): Ditto.
* libltdl/m4/ltdl.m4: Increment serial number.
(LTDL_INIT): Accept an optional directory argument to prefix each
of the LD_DLLOADERS locations.  Default to empty for backwards
compatibility.
* Makefile.maint: Adjust to compensate.
* configure.ac (AC_CONFIG_AUX_DIR, AC_CONFIG_MACRO_DIR): Adjust.
(AC_CONFIG_LIBOBJ_DIR): Set here so that we can build LTLIBOBJS
from in a subdirectory from the amalgamated Makefile.am.
(AM_PROG_CC_C_O, AM_INIT_AUTOMAKE): Use subdir-objects.
(AC_CONFIG_FILES): Remove libltdl/Makefile.am.
* libltdl/Makefile.am: Removed from repository, and merged into
Makefile.am as we now generate it...
* Makefile.am (libltdl/Makefile.am): ...from here, by extracting
the merged rules, and tweaking paths to accomodate the difference
in directory from Makefile.am to libltdl/Makefile.am.
(nobase_dist_pkgdata_DATA): Automake generated installation rules
change timestamps of installed files, so renamed this...
(configauxfiles): ...to this...
(libtoolize): ...substitute it...
(install-data-local): ...install manually, preserving
timestamps...
(install-data-hook): ...and set execute bit as appropriate.
(uninstall-hook): Not forgetting to remove them at uninstall.
(libltdl/Makefile.in): New rule.  Called from...
* bootstrap: ...here to avoid relying on config.status at
bootstrap time.
(auxdir, m4dir): Extract from configure.ac for ease of future
maintenance.  Adjust all references.
(reconfdirs): Call autoreconf for libltdl too -- even
though we don't use it for the build, libltdl/configure and
friends are installed with `libtoolize --ltdl --copy'.
* libtoolize.m4sh: Add files from the installed config master tree
to libtoolize --ltdl project subdirectory.
Diagnose duplicated files when --ltdl is used in an autotooled
project.
It's perfectly fine to run `libtoolize --ltdl --copy' in a tree
that has no configure.ac or configure.in; we want libltdl to be
useful even to projects that don't use autotools themselves.
(libtoolize_flags): Removed.  Changed all callers.
(func_massage_pkgconfig_files): New function.
* tests/standalone.at: New tests for using libltdl without
supporting configury in the parent project.
* tests/testsuite.at: Run them!
* NEWS: Updated.
2005-08-23 01:49:37 +00:00
Ralf Wildenhues
a1b595f6ab * m4/libtool.m4 (_LT_PROG_FC, _LT_LANG_FC_CONFIG): New macros
for modern Fortran.
(LT_LANG, _LT_LANG_DEFAULT_CONFIG, _LT_SYS_DYNAMIC_LINKER,
_LT_SYS_HIDDEN_LIBDEPS): Adjusted.
* tests/fcdemo-conf.test, tests/fcdemo-exec.test,
tests/fcdemo-make.test, tests/fcdemo-shared.test,
tests/fcdemo-static.test, tests/fcdemo/Makefile.am, tests/fcdemo/README,
tests/fcdemo/configure.ac, tests/fcdemo/cprogram.c, tests/fcdemo/foo.h,
tests/fcdemo/fooc.c, tests/fcdemo/foof.f90, tests/fcdemo/foof2.f90,
tests/fcdemo/foof3.f90, tests/fcdemo/fprogram.f90: New tests for Fortran.
* tests/convenience.at: Extended.
* Makefile.am, configure.ac: Adjusted.
* NEWS: Updated.
2005-08-08 09:23:57 +00:00
Gary V. Vaughan
ef4442da9b Revert the parallel installation changes from November last year:
* libtoolize.m4sh (pkgdatadir, aclocaldir): Substituted from
configure.
(func_copy_all_from_path): Removed.  No longer used.
(func_copy_some_files): Simplify now that nothing is copied from a
list of possible directories now.
(func_scan_files): Remove directory readability check...
(func_nonemptydir_p): ...in favour of a dedicated sanity check
function called from the main body.
(_lt_pkgvdatadir): Set pkgdatadir and aclocaldir appropriately if
this is in the environment.
* configure.ac: Tests for `ln' removed.
(APIVERSION): Removed.
* Makefile.am (pkgvdatadir, nobase_dist_pkgvdata_DATA)
(nobase_pkgvdata_DATA): Renamed to...
(pkgdatadir, nobase_dist_pkgdata_DATA, aclocalfiles): ...these
respectively.
(edit): Adjust for new variable names.
(install-data-local): Don't bother to remove old macro files that
will be overwritten by the installation, and perform a manual
installation of $(aclocalfiles) to preserve timestamps.
(install-exec-hook): Removed.  No need to make versioned links.
(uninstall-hook): No need to remove versioned links, but now we
need to manually remove the manually installed $(aclocalfiles).
* doc/libtool.texi: Remove bogus notes about setting
ACLOCAL_AMFLAGS for versioned libtool installations.
* NEWS: Remove parallel installation item.
2005-04-30 09:30:14 +00:00
Ralf Wildenhues
5b9fd5f43a * m4/libtool.m4 (_LT_CC_BASENAME): New macro to figure out $cc_basename.
Skip ccache, distcc, purify, cmdline options, `$host_alias-' prefix.
(_LT_SETUP, _LT_LANG_CXX_CONFIG, _LT_LANG_F77_CONFIG,
_LT_LANG_GCJ_CONFIG, _LT_LANG_RC_CONFIG): Use.
* NEWS, TODO: Update.
2005-04-15 13:36:56 +00:00
Per Bothner
85ad7692fb Allow special characters in source file names. Will break unless
`-o target' is also given, which must not contain special characters.
En passant, fix source file quoting broken for cygwin/MSVC.
2005-03-12 08:49:04 +00:00
Ralf Wildenhues
c2930cb393 * NEWS: s/Linux/GNU &/. 2005-02-04 15:47:40 +00:00
Craig Dooley
94a93ca621 * NEWS, m4/libtool.m4, config/ltmain.m4sh [dragonfly]:
Add support for DragonFly.
2005-01-26 17:38:51 +00:00
Ralf Wildenhues
d471094f21 * libtoolize.m4sh: Install `install-sh' as well, needed for configure ..
* Makefile.am, Makefile.maint: .. install, update it.
* NEWS, doc/libtool.texi (Distributing): .. document it.
Reported by Ross Boylan <ross@biostat.ucsf.edu>.
2004-12-20 13:08:35 +00:00
Ralf Wildenhues
81b4ad79e3 * config/ltmain.m4sh (func_lalib_p): Update function
description. (func_lalib_unsafe_p): New function with same
functionality but written without forks; this function is safe
to use for cases where the argument either does not exist or
is required to be a lalib for correct operation.
* NEWS: Mention the fact that stdin is not to be used.
* (func_mode_execute, func_mode_install, func_mode_link):
Use func_lalib_unsafe_p where appropriate.
* (func_mode_execute): For the program wrapper, use
func_ltwrapper_p instead of func_lalib_p.
2004-11-29 21:18:26 +00:00
Ralf Wildenhues
e5874b17a0 * m4/libtool.m4 (_LT_LINKER_SHLIBS): Treat linux-dietlibc with
the `diet' compiler wrapper (as opposed to the `diet-dyn'
wrapper) as a static-only platform.
* NEWS: Updated.
2004-11-29 21:12:41 +00:00
Ralf Wildenhues
60fbf440cb * m4/ltdl.m4 (LT_LIB_DLLOAD): Define HAVE_LIBDLLOADER if we
have a dlloader to preload.
* libltdl/ltdl.c (lt_dlinit): Only preload if HAVE_LIBDLLOADER, only
declare preloaded_symbols then.  Fixes libltdl on static platforms.
* NEWS: Updated.
2004-11-29 21:00:20 +00:00
Jeff Squyres
c541367158 * m4/libtool.m4 [linux] (_LT_COMPILER_PIC, _LT_LINKER_SHLIBS,
_LT_LANG_CXX_CONFIG), NEWS, THANKS: Support for Portland Group
(aka "pgi") compilers.
2004-11-24 17:25:38 +00:00
Gary V. Vaughan
ef758b513c * configure.ac (APIVERSION): New substituted variable.
(pkgvdatadir): Ditto.  Versioned data directory.
(pkgvmacrodir): Ditto.  Versioned aclocal directory.
(LN): New check for LN command.
* Makefile.am (aclocal_DATA): Replaced with...
(pkgvmacro_DATA): ...this.
(install-data-local): Remove old shared resources.
(install-exec-hook): Make versioned links to executables.
(uninstall-hook): Remove versioned files.
* libltdl/Makefile.am (ltdldatadir): Redefine in terms of
pkgvdatadir.
* libltdl/loaders/Makefile.am (ltdldatadir): Ditto.
* libtoolize.m4sh: Copy macro files from versioned macro directory
instead of shared aclocal directory.
* doc/libtool.texi: Document it.
* NEWS: Updated.
2004-11-15 01:03:14 +00:00
Gary V. Vaughan
fd13e4f5ca Add some new tests for Libtool's support of Automake
subdir-objects builds.  This marks the beginning of a move to an
Autotest driven test framework, which will eventually allow us to
trim away many of the generated files in the current test demo
subdirectories:

* configure.ac (AC_CONFIG_TESTDIR): Re-enable commented out
Autotest macros.
(AUTOTEST, M4SH): Use --language long hand.
* bootstrap: Generate tests/testsuite, and by implication
tests/package.m4.
* Makefile.am (edit): Add substitutions needed to generate
tests/package.m4 from bootstrap.
(check-recursive): Add tests/testsuite.
(TESTSUITE): The new Autotest testsuite target.
(TESTSUITE_AT): The Autotest sources.
(EXTRA_DIST): Distribute the generated testsuite and sources.
(tests/package.m4): Use $(edit) to propagate package metadata to
the new tests.
(tests/testsuite): Build the testsuite.
(tests/atconfig): How to regenerate the file.
(check-local): Hook Autotest into `make check'.
(installcheck-local): Run the testsuite on the installed tree.
(clean-local): Tidy our file droppings.
* tests/Makefile.am: Remove bitrotted code from Autotest
experiments in Autoconf 2.52 era.  Updated the rest and moved into
Makefile.am.
* tests/testsuite.at: New container for Autotest test groups.
* tests/am-subdir.at: New test group for compatibility with
Automake's subdir-objects builds.  Currently holds two tests, one
for a C project and another similar project in C++.
* TODO: Add an entry to remind us that these new tests expose a
bug in libtool.
* NEWS: Updated.
2004-10-16 14:43:48 +00:00
Gary V. Vaughan
e5d70992b8 * m4/libtool.m4 (_LT_PROG_ECHO_BACKSLASH): Don't confuse $ECHO
with $lt_ECHO, or we always get a libtool with ECHO=echo, rather
than testing for a mechanism that quotes  properly.
* NEWS: Updated.

* config/ltmain.m4sh: Need to include getopt.m4sh earlier so that
progpath is set before it is called to --no-reexec.
* NEWS: Updated.

Without this change, the distributed libtool tarball has a
dependency on autom4te.  There was some inconsistency in the
filenames: now we have foo.m4sh -> m4sh -> foo.in -> configure
-> foo[.sh].  Bootstrap runs the m4sh steps and the resulting .in
files are distributed:

* tests/Makefile.am (EXTRA_DIST): Distribute defs.m4sh.
* Makefile.am (EXTRA_DIST): Distribute libtoolize.m4sh.
(libtoolize.in, libtoolize): Split into bootstrap and runtime
stages.
($(top_srcdir)/tests/defs.in, $(top_srcdir)/tests/defs): Ditto.
($(top_srcdir)/config/ltmain.sh): Swap ltmain.m4sh and ltmain.in
names.
* bootstrap: Make libtoolize.in and tests/defs.in.
* NEWS: Updated.
2004-10-04 18:32:45 +00:00
Jim Tison
23031a61ab Initial support for s390x-ibm-tpf:
* m4/libtool.m4: Correct obvious spelling errors in remarks.
(_LT_ENABLE_LOCK): Make s390x-ibm-tpf hosts adopt elf64_s390
conventions.
(_LT_SYS_DYNAMIC_LINKER): Set defaults for s390x-ibm-tpf host.
(_LT_CHECK_MAGIC_METHOD): Skip all dependency checks for
s390x-ibm-tpf hosts.
(_LT_LINKER_SHLIBS): Make s390x-ibm-tpf hosts adopt GNU/Linux OS
attributes.
* NEWS: Updated.
2004-10-02 12:57:45 +00:00
Charles Wilson
8c7eb9e5c9 * ltmain.in (func_generate_dlsyms) [cygwin, mingw]: when creating
a .exp file for an executable, also create a .def file, and add
that file to the link command via SYMFILES.  This causes binutils
to generate an .edata section, and allows self dlopening to work.
* NEWS: Updated.
2004-09-22 08:50:34 +00:00
Gary V. Vaughan
0e0104aa45 My most recent `2004-09-02 Gary V. Vaughan' patch for mkdir_p
below is horrendously broken since it makes the installed libtool
try to run the mkinstalldirs or install-sh helper scripts.  This
patch fixes the `make -j' mkdir race condition internally:

* libtoolize.in (func_mkdir_p): New slice and dice algorithm
to build the directory tree one dir at a time, ignoring errors
until the end incase they are transient due to a concurrent
identical mkdir.
* tests/defs (func_mkdir_p): Ditto.
* config/ltmain.in (func_mkdir_p): Ditto, except that ltmain.in
uses $echo rather than $ECHO, and uses $show and $run to interact
correctly with the command line.
* configure.ac (AM_INIT_AUTOMAKE): 1.8 is sufficient again.
* Makefile.am (edit): Don't substitute automake's $(mkdir_p).
* NEWS: Updated.
2004-09-16 14:57:02 +00:00
Ralf Wildenhues
8240b4ebba * m4/libtool.m4 (_LT_CMD_GLOBAL_SYMBOLS): The linker distinguishes
data and code symbols on linux-gnu/ia64.  Fixes multiple testsuite
failures.
* NEWS: Updated.
2004-09-11 00:50:27 +00:00
Albert Chin-A-Young
0aef25d740 * m4/libtool.m4, config/ltmain.in: When calling $LTCC,
pass default $CFLAGS through with $LTCFLAGS.
2004-09-05 17:35:16 +00:00
David Edelsohn
875f854504 * config/ltmain.in (func_mode_link): Use $pic_object as
$non_pic_object if $non_pic_object=none.
* NEWS: Updated.
2004-09-03 13:02:33 +00:00
Gary V. Vaughan
ba6daa7408 Builds of packages that use libtool and make -j produce "directory
already exists warnings" for .lib directory.  Build on automake
wisdom to support make -j builds where a suitable mkdir is
available:

* configure.ac (AM_INIT_AUTOMAKE): Require 1.9, which goes to some
trouble to find a $(mkdir_p) that doesn't interfere with make -j.
* Makefile.am (edit): Substitute for @mkdir_p@.
* config/ltmain.in (MKDIR_P): Take @mkdir_p@ value.
(mkdir): Removed.
(func_mkdir_p): New function to use $MKDIR_P.  Factor out all
previous mkdir calls to use this function.
(RM, MV): Declared as in libtoolize.in.  Changed all callers.
* libtoolize.in (MKDIR_P): Take @mkdir_p@ value from automake.
(func_mkdir_p): Use it, similarly to new config/ltmain.in.
* tests/defs: Synchronize boiler plate code with ltmain.in.
Adjust all callers.
Add missing copyright preamble.
* tests/demo-static.test: Add missing copyright preamble.
Reported by Daniel Reed <n@ml.org>
2004-09-03 00:26:37 +00:00
Ralf Wildenhues
c45d3a0d18 * libltdl/ltdl.c (try_dlopen): Fix memory leak.
* NEWS: Updated.
2004-09-02 13:27:24 +00:00
Gary V. Vaughan
cae83b341b * libltdl/slist.c, libltdl/slist.h: Merge in changes from latest
upstream.  Mostly comments, formal item boxing, a sort function,
and const madness reduction.
(slist_new): Removed.
(slist_box, slist_unbox, slist_sort): New.
(SListCompare, SListCallback): Swapped!
(slist_remove, slist_find): Change order of parameters for
orthogonality with slist_foreach.  Changed all callers.
* libltdl/lt_dlloader.c (loader_cmp): Renamed to...
(loader_callback): ...this.  Return boxed item.
(lt_dlloader_remove): Adjust to new loader_callback semantics;
unbox each removed item before returning.
Remove unused variable.
Remove const from name parameter, since the slist API cannot
guarantee userdata const-ancy for its callback functions.
(lt_dlloader_find): Adjust to new loader_callback semantics; need
to return the contents of the boxed item.
Remove const from name parameter, since the slist API cannot
guarantee userdata const-ancy for its callback functions.
* libltdl/lt_dlloader.h (lt_dlloader_find, lt_dlloader_remove):
Adjust to new constless footprint.
* libltdl/ltdl.c (ltdl_exit): The global `loaders' list is changed
variable `loader' is invalidated.  Since some loaders may be
resident modules that cannot be unloaded (though we have none
yet), we must save each `next' address before calling
`lt_dlloader_remove'.
* NEWS: Updated.
* THANKS: Added Ralf.
2004-09-02 12:55:32 +00:00
Gary V. Vaughan
53f09b2d98 Don't use C99 flexible array types as we want to be C89
compatible.  Instead, revert to the old way of doing things with
an array of symbol name vs. address, and adding the originator as
the first symbol but with a NULL address:

* config/ltmain.in (func_extract_dlsyms): Store originator as a
NULL address symbol.
* libltdl/ltdl.h (lt_dlsymbol): Removed.
(lt_dlsymlist): Remove originator field.
(LTDL_SET_PRELOADED_SYMBOLS): Adjust.
* libltdl/loaders/preopen.c (vm_open, lt_dlpreload_open): Adjust
for new types.
(vm_sym): Skip the new originator symbol when scanning symbol
names.
* m4/libtool.m4 (_LT_CMD_GLOBAL_SYMBOLS): Adjust preloaded symbols
test file to match.
* NEWS: Updated.
2004-09-01 01:22:26 +00:00