The "extern char* sys_siglist" declaration breaks systems with different

Tue Jan 19 00:44:24 1999  Josh MacDonald  <jmacd@axis.hip.berkeley.edu>

	* gstrfuncs.c (g_strsignal): The "extern char* sys_siglist"
	declaration breaks systems with different declarations, like
	mine (FreeBSD).  So, I added a configuration variable to decide
	whether the declaration is neccesary.  Change also appears on
	line 275 of configure.in.
This commit is contained in:
Josh MacDonald 1999-01-19 09:07:28 +00:00 committed by Josh MacDonald
parent a478fc7a3f
commit e6c71cedb9
12 changed files with 566 additions and 481 deletions

View File

@ -1,3 +1,11 @@
Tue Jan 19 00:44:24 1999 Josh MacDonald <jmacd@axis.hip.berkeley.edu>
* gstrfuncs.c (g_strsignal): The "extern char* sys_siglist"
declaration breaks systems with different declarations, like
mine (FreeBSD). So, I added a configuration variable to decide
whether the declaration is neccesary. Change also appears on
line 275 of configure.in.
Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org> Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org>
* Released GLib 1.1.13 * Released GLib 1.1.13

View File

@ -1,3 +1,11 @@
Tue Jan 19 00:44:24 1999 Josh MacDonald <jmacd@axis.hip.berkeley.edu>
* gstrfuncs.c (g_strsignal): The "extern char* sys_siglist"
declaration breaks systems with different declarations, like
mine (FreeBSD). So, I added a configuration variable to decide
whether the declaration is neccesary. Change also appears on
line 275 of configure.in.
Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org> Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org>
* Released GLib 1.1.13 * Released GLib 1.1.13

View File

@ -1,3 +1,11 @@
Tue Jan 19 00:44:24 1999 Josh MacDonald <jmacd@axis.hip.berkeley.edu>
* gstrfuncs.c (g_strsignal): The "extern char* sys_siglist"
declaration breaks systems with different declarations, like
mine (FreeBSD). So, I added a configuration variable to decide
whether the declaration is neccesary. Change also appears on
line 275 of configure.in.
Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org> Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org>
* Released GLib 1.1.13 * Released GLib 1.1.13

View File

@ -1,3 +1,11 @@
Tue Jan 19 00:44:24 1999 Josh MacDonald <jmacd@axis.hip.berkeley.edu>
* gstrfuncs.c (g_strsignal): The "extern char* sys_siglist"
declaration breaks systems with different declarations, like
mine (FreeBSD). So, I added a configuration variable to decide
whether the declaration is neccesary. Change also appears on
line 275 of configure.in.
Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org> Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org>
* Released GLib 1.1.13 * Released GLib 1.1.13

View File

@ -1,3 +1,11 @@
Tue Jan 19 00:44:24 1999 Josh MacDonald <jmacd@axis.hip.berkeley.edu>
* gstrfuncs.c (g_strsignal): The "extern char* sys_siglist"
declaration breaks systems with different declarations, like
mine (FreeBSD). So, I added a configuration variable to decide
whether the declaration is neccesary. Change also appears on
line 275 of configure.in.
Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org> Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org>
* Released GLib 1.1.13 * Released GLib 1.1.13

View File

@ -1,3 +1,11 @@
Tue Jan 19 00:44:24 1999 Josh MacDonald <jmacd@axis.hip.berkeley.edu>
* gstrfuncs.c (g_strsignal): The "extern char* sys_siglist"
declaration breaks systems with different declarations, like
mine (FreeBSD). So, I added a configuration variable to decide
whether the declaration is neccesary. Change also appears on
line 275 of configure.in.
Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org> Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org>
* Released GLib 1.1.13 * Released GLib 1.1.13

View File

@ -1,3 +1,11 @@
Tue Jan 19 00:44:24 1999 Josh MacDonald <jmacd@axis.hip.berkeley.edu>
* gstrfuncs.c (g_strsignal): The "extern char* sys_siglist"
declaration breaks systems with different declarations, like
mine (FreeBSD). So, I added a configuration variable to decide
whether the declaration is neccesary. Change also appears on
line 275 of configure.in.
Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org> Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org>
* Released GLib 1.1.13 * Released GLib 1.1.13

View File

@ -1,3 +1,11 @@
Tue Jan 19 00:44:24 1999 Josh MacDonald <jmacd@axis.hip.berkeley.edu>
* gstrfuncs.c (g_strsignal): The "extern char* sys_siglist"
declaration breaks systems with different declarations, like
mine (FreeBSD). So, I added a configuration variable to decide
whether the declaration is neccesary. Change also appears on
line 275 of configure.in.
Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org> Sun Jan 17 17:13:54 CST 1999 Shawn T. Amundson <amundson@gtk.org>
* Released GLib 1.1.13 * Released GLib 1.1.13

View File

@ -65,6 +65,7 @@
#undef NO_FD_SET #undef NO_FD_SET
#undef NO_SYS_ERRLIST #undef NO_SYS_ERRLIST
#undef NO_SYS_SIGLIST #undef NO_SYS_SIGLIST
#undef NO_SYS_SIGLIST_DECL
#undef WITH_SYMBOL_UNDERSCORE #undef WITH_SYMBOL_UNDERSCORE

View File

@ -265,13 +265,23 @@ fi
AC_MSG_CHECKING(for sys_siglist) AC_MSG_CHECKING(for sys_siglist)
AC_TRY_LINK(, [ AC_TRY_LINK(, [
extern char *sys_siglist[]; extern char *sys_siglist[];
sys_siglist[1][0] = 0; strlen (sys_siglist[0]);
], glib_ok=yes, glib_ok=no) ], glib_ok=yes, glib_ok=no)
AC_MSG_RESULT($glib_ok) AC_MSG_RESULT($glib_ok)
if test $glib_ok = no; then if test $glib_ok = no; then
AC_DEFINE(NO_SYS_SIGLIST) AC_DEFINE(NO_SYS_SIGLIST)
fi fi
# Check for sys_siglist decl (see Tue Jan 19 00:44:24 1999 in changelog)
AC_MSG_CHECKING(for sys_siglist declaration)
AC_TRY_COMPILE([#include <signal.h>], [
strlen (sys_siglist[0]);
], glib_ok=yes, glib_ok=no)
AC_MSG_RESULT($glib_ok)
if test $glib_ok = yes; then
AC_DEFINE(NO_SYS_SIGLIST_DECL)
fi
# Check if <sys/select.h> needs to be included for fd_set # Check if <sys/select.h> needs to be included for fd_set
AC_MSG_CHECKING([for fd_set]) AC_MSG_CHECKING([for fd_set])
AC_TRY_COMPILE([#include <sys/types.h>], AC_TRY_COMPILE([#include <sys/types.h>],

View File

@ -759,8 +759,13 @@ g_strsignal (gint signum)
#endif #endif
} }
#else /* NO_SYS_SIGLIST */ #else /* NO_SYS_SIGLIST */
#ifndef NO_SYS_SIGLIST_DECL
/*(see Tue Jan 19 00:44:24 1999 in changelog)*/
extern char *sys_siglist[]; extern char *sys_siglist[];
return sys_siglist [signum]; #endif
return (char*) /* this function should return const --josh */ sys_siglist [signum];
#endif /* NO_SYS_SIGLIST */ #endif /* NO_SYS_SIGLIST */
msg = g_static_private_get (&msg_private); msg = g_static_private_get (&msg_private);

View File

@ -759,8 +759,13 @@ g_strsignal (gint signum)
#endif #endif
} }
#else /* NO_SYS_SIGLIST */ #else /* NO_SYS_SIGLIST */
#ifndef NO_SYS_SIGLIST_DECL
/*(see Tue Jan 19 00:44:24 1999 in changelog)*/
extern char *sys_siglist[]; extern char *sys_siglist[];
return sys_siglist [signum]; #endif
return (char*) /* this function should return const --josh */ sys_siglist [signum];
#endif /* NO_SYS_SIGLIST */ #endif /* NO_SYS_SIGLIST */
msg = g_static_private_get (&msg_private); msg = g_static_private_get (&msg_private);