+2003-08-05 Jim Pick <jim@kaffe.org>,
+ Ito Kazumitsu <kaz@maczuka.gcd.org>,
+ Gary V. Vaughan <gary@gnu.org>
+
+ Much as we have tried not to make it the callers' responsibility
+ to maintain an lt_dlrealloc function pointer, it is too difficult
+ to implement realloc as malloc/memcpy/free without knowing the
+ size of the original block. rpl_realloc has been deprecated since
+ 2002-10-30, but kaffe has real failures with that so it's time to
+ bite the bullet. Caller gets to maintain lt_dlrealloc:
+
+ * NEWS (1.5.1): Updated.
+ * libltdl/ltdl.c (LT_DLREALLOC): Use lt_dlrealloc so the user can
+ update the function pointer to match lt_dlmalloc.
+ (lt_emalloc): Use lt_dlrealloc rather than hardcoding realloc.
+ * doc/libtool.texi (Libltdl interface): Describe lt_dlrealloc now
+ that it too has become part of the exported interface to libltdl.
+
2003-08-01 Peter O'Gorman <peter@pogma.com>
* libtool.m4 (darwin): Use "-undefined dynamic_lookup" if the
- user set MACOSX_DEPLOYMENT_TARGET to 10.3 or greater.
+ user set MACOSX_DEPLOYMENT_TARGET to 10.3 or greater.
* libltdl/ltdl.c (dyld): Save the error from the first lookup
to report in lt_dlerror(). Otherwise the error is always
"Symbol _foo not in /usr/lib/libSystem.dylib".
* ltmain.in: search libraries in the order of preference, rather
than picking .la's even if they're in a less preferred directory.
-
+
2003-06-03 Robert Millan <rmh@debian.org>
* ltdl.m4: Add support for GNU/FreeBSD.
2003-06-03 Peter O'Gorman <peter@pogma.com>
* libtool.m4 (darwin): Remove checks for Apple-specific gcc.
- * libltdl/ltdl.c (HAVE_MACH_O_DYLD_H): #define
+ * libltdl/ltdl.c (HAVE_MACH_O_DYLD_H): #define
__private_extern__ for fsf gcc.
* ltmain.in (darwin): Only add new paths to newlib_search_path.
* README: Changed typo in version description.
* config.guess, config.sub, texinfo.tex: Synchronized from
ftp.gnu.org.
-
+
2003-04-10 Alexandre Oliva <aoliva@redhat.com>
*destination* ptr to decide how much to copy. This
sometimes results in out-of-bound accesses which cause
segfaults. This is a quick hack for now; we may want
- something cleaner later. (tryall_dlopen_module): check to
- be sure (dirname_len > 0) before testing first character
- against '/'. (try_dlopen): check for feof(file) in read
- loop -- otherwise infloop?
+ something cleaner later.
+ (tryall_dlopen_module): check to be sure (dirname_len > 0) before
+ testing first character against '/'.
+ (try_dlopen): check for feof(file) in read loop -- otherwise
+ infinite loop?
2002-10-25 Robert Boehne <rboehne@gnu.org>
New in 1.5b: 2003-??-??; CVS version 1.5a, Libtool team:
* Bug fixes.
-
+\f
+New in 1.5.1: 2003-??-??; CVS version 1.5.0a, Libtool team:
+* lt_dlrealloc is an official part of the libltdl API.
+* Bug fixes.
+\f
New in 1.5: 2003-04-14; CVS version 1.4e, Libtool team:
* First stable release of multi-language architecture.
* libtool and libltdl support for Mac OS/X.
@cindex mode, install
In @dfn{install} mode, libtool interprets most of the elements of
-@var{mode-args} as an installation command beginning with
+@var{mode-args} as an installation command beginning with
@code{cp}, or a BSD-compatible @code{install} program.
The following components of @var{mode-args} are treated specially:
@table @samp
@item -inst-prefix @var{inst-prefix-dir}
When installing into a temporary staging area, rather than the
-final @var{prefix}, this argument is used to reflect the
+final @var{prefix}, this argument is used to reflect the
temporary path, in much the same way @code{automake} uses
@var{DESTDIR}. For instance, if @var{prefix} is @code{/usr/local},
but @var{inst-prefix-dir} is @code{/tmp}, then the object will be
-installed under @code{/tmp/usr/local/}. If the installed object
+installed under @code{/tmp/usr/local/}. If the installed object
is a libtool library, then the internal fields of that library
will reflect only @var{prefix}, not @var{inst-prefix-dir}:
libdir='/tmp/usr/local/lib'
@end example
-@code{inst-prefix} is also used to insure that if the installed
-object must be relinked upon installation, that it is relinked
-against the libraries in @var{inst-prefix-dir}/@var{prefix},
+@code{inst-prefix} is also used to insure that if the installed
+object must be relinked upon installation, that it is relinked
+against the libraries in @var{inst-prefix-dir}/@var{prefix},
not @var{prefix}.
In truth, this option is not really intended for use when calling
libtool directly; it is automatically used when @code{libtool --mode=install}
-calls @code{libtool --mode=relink}. Libtool does this by
-analyzing the destination path given in the original
-@code{libtool --mode=install} command and comparing it to the
+calls @code{libtool --mode=relink}. Libtool does this by
+analyzing the destination path given in the original
+@code{libtool --mode=install} command and comparing it to the
expected installation path established during @code{libtool --mode=link}.
Thus, end-users need change nothing, and @code{automake}-style
@end deftypefun
@deftypevar {lt_ptr (*) (size_t @var{size})} lt_dlmalloc
+@deftypevarx {lt_ptr (*) (lt_ptr @var{ptr}, size_t @var{size})} lt_dlrealloc
@deftypevarx {void (*) (lt_ptr @var{ptr})} lt_dlfree
-These variables are set to @code{malloc} and @code{free}, by default,
-but you can set them to any other functions that provides equivalent
-functionality. However, you must not modify their values after calling
-any libltdl function other than @code{lt_dlpreopen_default} or the macro
+These variables are set to @code{malloc}, @code{realloc} and @code{free} by
+default, but you can set them to any other functions that provide equivalent
+functionality. If you change any of these function pointers, you will almost
+certainly need to change all three to point into the same malloc library.
+Strange things will happen if you allocate memory from one library, and then
+pass it to an implementation of @code{free} that doesn't know what book
+keeping the allocator used.
+
+You must not modify any of their values after calling any libltdl function
+other than @code{lt_dlpreopen_default} or the macro
@code{LTDL_SET_PRELOADED_SYMBOLS}.
@end deftypevar
#else
#define LT_DLMALLOC(tp, n) ((tp *) lt_dlmalloc ((n) * sizeof(tp)))
-#define LT_DLREALLOC(tp, p, n) ((tp *) rpl_realloc ((p), (n) * sizeof(tp)))
+#define LT_DLREALLOC(tp, p, n) ((tp *) lt_dlrealloc ((p), (n) * sizeof(tp)))
#define LT_DLFREE(p) \
LT_STMT_START { if (p) (p) = (lt_dlfree (p), (lt_ptr) 0); } LT_STMT_END
lt_ptr addr;
size_t size;
{
- lt_ptr mem = realloc (addr, size);
+ lt_ptr mem = lt_dlrealloc (addr, size);
if (size && !mem)
LT_DLMUTEX_SETERROR (LT_DLSTRERROR (NO_MEMORY));
return mem;