From: Tim Janik Date: Wed, 21 Oct 1998 18:04:47 +0000 (+0000) Subject: reverted part of the changes from Sebastian Wilhelmi (1998-10-20). don't X-Git-Tag: GLIB_1_1_4~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=634e4a58c6927c6d14673dae6cce479c7f1d9055;p=platform%2Fupstream%2Fglib.git reverted part of the changes from Sebastian Wilhelmi (1998-10-20). don't Wed Oct 21 19:22:58 1998 Tim Janik * configure.in (G_MODULE_HAVE_DLERROR): reverted part of the changes from Sebastian Wilhelmi (1998-10-20). don't specify a specific loading behaviour (i.e. RTLD_NOW) when we are not sure whether it is supplied. changed the return value from (!f2 && f1) to (!f2 || f1) so we default to not needing an underscore. reverted the extra plugin.c building, because .lo files are not ELF libraries, this can't work. This needs further investigation on Solaris... Wed Oct 21 19:58:27 1998 Tim Janik * gmodule.c (g_module_symbol): fixed a string pointer bug that could cause garbage error messages from g_module_symbol() for systems that NEED_USCORE. --- diff --git a/ChangeLog b/ChangeLog index db364d4..e4a7a34 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +Wed Oct 21 19:22:58 1998 Tim Janik + + * configure.in (G_MODULE_HAVE_DLERROR): reverted part of the changes + from Sebastian Wilhelmi (1998-10-20). don't specify a specific loading + behaviour (i.e. RTLD_NOW) when we are not sure whether it is supplied. + changed the return value from (!f2 && f1) to (!f2 || f1) so we default + to not needing an underscore. reverted the extra plugin.c building, + because .lo files are not ELF libraries, this can't work. This needs + further investigation on Solaris... + Wed Oct 21 17:03:05 1998 Tim Janik * glib.h: diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index db364d4..e4a7a34 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,13 @@ +Wed Oct 21 19:22:58 1998 Tim Janik + + * configure.in (G_MODULE_HAVE_DLERROR): reverted part of the changes + from Sebastian Wilhelmi (1998-10-20). don't specify a specific loading + behaviour (i.e. RTLD_NOW) when we are not sure whether it is supplied. + changed the return value from (!f2 && f1) to (!f2 || f1) so we default + to not needing an underscore. reverted the extra plugin.c building, + because .lo files are not ELF libraries, this can't work. This needs + further investigation on Solaris... + Wed Oct 21 17:03:05 1998 Tim Janik * glib.h: diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index db364d4..e4a7a34 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,13 @@ +Wed Oct 21 19:22:58 1998 Tim Janik + + * configure.in (G_MODULE_HAVE_DLERROR): reverted part of the changes + from Sebastian Wilhelmi (1998-10-20). don't specify a specific loading + behaviour (i.e. RTLD_NOW) when we are not sure whether it is supplied. + changed the return value from (!f2 && f1) to (!f2 || f1) so we default + to not needing an underscore. reverted the extra plugin.c building, + because .lo files are not ELF libraries, this can't work. This needs + further investigation on Solaris... + Wed Oct 21 17:03:05 1998 Tim Janik * glib.h: diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12 index db364d4..e4a7a34 100644 --- a/ChangeLog.pre-2-12 +++ b/ChangeLog.pre-2-12 @@ -1,3 +1,13 @@ +Wed Oct 21 19:22:58 1998 Tim Janik + + * configure.in (G_MODULE_HAVE_DLERROR): reverted part of the changes + from Sebastian Wilhelmi (1998-10-20). don't specify a specific loading + behaviour (i.e. RTLD_NOW) when we are not sure whether it is supplied. + changed the return value from (!f2 && f1) to (!f2 || f1) so we default + to not needing an underscore. reverted the extra plugin.c building, + because .lo files are not ELF libraries, this can't work. This needs + further investigation on Solaris... + Wed Oct 21 17:03:05 1998 Tim Janik * glib.h: diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index db364d4..e4a7a34 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,13 @@ +Wed Oct 21 19:22:58 1998 Tim Janik + + * configure.in (G_MODULE_HAVE_DLERROR): reverted part of the changes + from Sebastian Wilhelmi (1998-10-20). don't specify a specific loading + behaviour (i.e. RTLD_NOW) when we are not sure whether it is supplied. + changed the return value from (!f2 && f1) to (!f2 || f1) so we default + to not needing an underscore. reverted the extra plugin.c building, + because .lo files are not ELF libraries, this can't work. This needs + further investigation on Solaris... + Wed Oct 21 17:03:05 1998 Tim Janik * glib.h: diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index db364d4..e4a7a34 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,13 @@ +Wed Oct 21 19:22:58 1998 Tim Janik + + * configure.in (G_MODULE_HAVE_DLERROR): reverted part of the changes + from Sebastian Wilhelmi (1998-10-20). don't specify a specific loading + behaviour (i.e. RTLD_NOW) when we are not sure whether it is supplied. + changed the return value from (!f2 && f1) to (!f2 || f1) so we default + to not needing an underscore. reverted the extra plugin.c building, + because .lo files are not ELF libraries, this can't work. This needs + further investigation on Solaris... + Wed Oct 21 17:03:05 1998 Tim Janik * glib.h: diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index db364d4..e4a7a34 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,13 @@ +Wed Oct 21 19:22:58 1998 Tim Janik + + * configure.in (G_MODULE_HAVE_DLERROR): reverted part of the changes + from Sebastian Wilhelmi (1998-10-20). don't specify a specific loading + behaviour (i.e. RTLD_NOW) when we are not sure whether it is supplied. + changed the return value from (!f2 && f1) to (!f2 || f1) so we default + to not needing an underscore. reverted the extra plugin.c building, + because .lo files are not ELF libraries, this can't work. This needs + further investigation on Solaris... + Wed Oct 21 17:03:05 1998 Tim Janik * glib.h: diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index db364d4..e4a7a34 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,13 @@ +Wed Oct 21 19:22:58 1998 Tim Janik + + * configure.in (G_MODULE_HAVE_DLERROR): reverted part of the changes + from Sebastian Wilhelmi (1998-10-20). don't specify a specific loading + behaviour (i.e. RTLD_NOW) when we are not sure whether it is supplied. + changed the return value from (!f2 && f1) to (!f2 || f1) so we default + to not needing an underscore. reverted the extra plugin.c building, + because .lo files are not ELF libraries, this can't work. This needs + further investigation on Solaris... + Wed Oct 21 17:03:05 1998 Tim Janik * glib.h: diff --git a/configure.in b/configure.in index d4235c2..e840ba2 100644 --- a/configure.in +++ b/configure.in @@ -433,17 +433,16 @@ if test "$G_MODULE_IMPL" = "G_MODULE_IMPL_DL"; then dnl *** check whether we need preceeding underscores AC_MSG_CHECKING(for preceeding underscore in symbols) AC_CACHE_VAL(glib_cv_uscore,[ - echo "int glib_underscore_test (void) { return 42; }" >plugin.c - ./libtool --mode=compile $CC -c plugin.c >/dev/null 2>&1 AC_TRY_RUN([ #include + int glib_underscore_test (void) { return 42; } int main() { void *f1 = (void*)0, *f2 = (void*)0, *handle; - handle = dlopen ("./plugin.lo", RTLD_NOW ); + handle = dlopen ((void*)0, 0); if (handle) { f1 = dlsym (handle, "glib_underscore_test"); f2 = dlsym (handle, "_glib_underscore_test"); - } return (!f2 && f1); + } return (!f2 || f1); }], glib_cv_uscore=yes, glib_cv_uscore=no, diff --git a/gmodule/ChangeLog b/gmodule/ChangeLog index 07493b4..fecf1d9 100644 --- a/gmodule/ChangeLog +++ b/gmodule/ChangeLog @@ -1,3 +1,9 @@ +Wed Oct 21 19:58:27 1998 Tim Janik + + * gmodule.c (g_module_symbol): fixed a string pointer bug that could + cause garbage error messages from g_module_symbol() for systems that + NEED_USCORE. + Mon Sep 21 01:54:48 1998 Tim Janik * gmodule.h: diff --git a/gmodule/gmodule.c b/gmodule/gmodule.c index 17133ff..bb00dde 100644 --- a/gmodule/gmodule.c +++ b/gmodule/gmodule.c @@ -319,9 +319,13 @@ g_module_symbol (GModule *module, g_return_val_if_fail (symbol != NULL, FALSE); #ifdef G_MODULE_NEED_USCORE - symbol_name = g_strconcat ("_", symbol_name, NULL); - *symbol = _g_module_symbol (module->handle, symbol_name); - g_free (symbol_name); + { + gchar *name; + + name = g_strconcat ("_", symbol_name, NULL); + *symbol = _g_module_symbol (module->handle, name); + g_free (name); + } #else /* !G_MODULE_NEED_USCORE */ *symbol = _g_module_symbol (module->handle, symbol_name); #endif /* !G_MODULE_NEED_USCORE */