On Sep 1, 2000, Alexandre Oliva [EMAIL PROTECTED] wrote:
On Sep 1, 2000, Patrick Tullmann [EMAIL PROTECTED] wrote:
I think something isn't quite right in the shared-library detection
code in configure. (Quite possible when cross-compiling to the
OSKit.) But, this patch at least lets my build complete...
Any objections?
I think the right fix is to arrange for all references to shlib_ext to
be enclosed in #ifdef LTDL_SHLIB_EXT/#endif.
Please try this patch:
Index: ChangeLog
from Alexandre Oliva [EMAIL PROTECTED]
* libltdl/ltdl.c (load_deplibs): Don't append shlib_ext; use
lt_dlopenext() instead.
Index: libltdl/ltdl.c
===
RCS file: /home/cvs/libtool/libltdl/ltdl.c,v
retrieving revision 1.82.2.3
diff -u -p -r1.82.2.3 ltdl.c
--- libltdl/ltdl.c 2000/09/04 01:52:04 1.82.2.3
+++ libltdl/ltdl.c 2000/09/04 06:08:40
@@ -1165,10 +1165,10 @@ load_deplibs(handle, deplibs)
ret = 0;
goto cleanup;
}
- names = lt_dlmalloc(depcount * sizeof(char*));
+ names = (char**)lt_dlmalloc(depcount * sizeof(char*));
if (!names)
goto cleanup;
- handles = lt_dlmalloc(depcount * sizeof(lt_dlhandle*));
+ handles = (lt_dlhandle*)lt_dlmalloc(depcount * sizeof(lt_dlhandle*));
if (!handles)
goto cleanup;
depcount = 0;
@@ -1185,9 +1185,9 @@ load_deplibs(handle, deplibs)
*end = 0; /* set a temporary string terminator */
if (strncmp(p, "-l", 2) == 0) {
name = lt_dlmalloc(3+ /* "lib" */
- strlen(p+2)+strlen(shlib_ext)+1);
+ strlen(p+2)+1);
if (name)
- sprintf(name, "lib%s%s", p+2, shlib_ext);
+ sprintf (name, "lib%s", p+2);
} else
name = strdup(p);
if (name)
@@ -1202,7 +1202,7 @@ load_deplibs(handle, deplibs)
}
/* load the deplibs (in reverse order) */
for (i = 0; i depcount; i++) {
- lt_dlhandle handle = lt_dlopen(names[depcount-1-i]);
+ lt_dlhandle handle = lt_dlopenext(names[depcount-1-i]);
if (!handle) {
int j;
for (j = 0; j i; j++)
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicampoliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist*Please* write to mailing lists, not to me