diff --git a/ChangeLog b/ChangeLog index 32425b49b..05717d99f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2001-04-19 Sebastian Wilhelmi + + * configure.in: Removed bashism in test for the pkg-config + version. + + * configure.in: Rewrote test for multithread flag. Now uses + localtime_r, which hopefully has a consistent prototype across + different platforms. Also it uses a clever double EGREP trick + instead of compiling, which could give false positives. Thanks to + Dan Winship for the hint. + Wed Apr 18 17:35:38 2001 Owen Taylor * gutils.c (_glib_gettext): Add missing static pointed diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index 32425b49b..05717d99f 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,14 @@ +2001-04-19 Sebastian Wilhelmi + + * configure.in: Removed bashism in test for the pkg-config + version. + + * configure.in: Rewrote test for multithread flag. Now uses + localtime_r, which hopefully has a consistent prototype across + different platforms. Also it uses a clever double EGREP trick + instead of compiling, which could give false positives. Thanks to + Dan Winship for the hint. + Wed Apr 18 17:35:38 2001 Owen Taylor * gutils.c (_glib_gettext): Add missing static pointed diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 32425b49b..05717d99f 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,14 @@ +2001-04-19 Sebastian Wilhelmi + + * configure.in: Removed bashism in test for the pkg-config + version. + + * configure.in: Rewrote test for multithread flag. Now uses + localtime_r, which hopefully has a consistent prototype across + different platforms. Also it uses a clever double EGREP trick + instead of compiling, which could give false positives. Thanks to + Dan Winship for the hint. + Wed Apr 18 17:35:38 2001 Owen Taylor * gutils.c (_glib_gettext): Add missing static pointed diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12 index 32425b49b..05717d99f 100644 --- a/ChangeLog.pre-2-12 +++ b/ChangeLog.pre-2-12 @@ -1,3 +1,14 @@ +2001-04-19 Sebastian Wilhelmi + + * configure.in: Removed bashism in test for the pkg-config + version. + + * configure.in: Rewrote test for multithread flag. Now uses + localtime_r, which hopefully has a consistent prototype across + different platforms. Also it uses a clever double EGREP trick + instead of compiling, which could give false positives. Thanks to + Dan Winship for the hint. + Wed Apr 18 17:35:38 2001 Owen Taylor * gutils.c (_glib_gettext): Add missing static pointed diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 32425b49b..05717d99f 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,14 @@ +2001-04-19 Sebastian Wilhelmi + + * configure.in: Removed bashism in test for the pkg-config + version. + + * configure.in: Rewrote test for multithread flag. Now uses + localtime_r, which hopefully has a consistent prototype across + different platforms. Also it uses a clever double EGREP trick + instead of compiling, which could give false positives. Thanks to + Dan Winship for the hint. + Wed Apr 18 17:35:38 2001 Owen Taylor * gutils.c (_glib_gettext): Add missing static pointed diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 32425b49b..05717d99f 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,14 @@ +2001-04-19 Sebastian Wilhelmi + + * configure.in: Removed bashism in test for the pkg-config + version. + + * configure.in: Rewrote test for multithread flag. Now uses + localtime_r, which hopefully has a consistent prototype across + different platforms. Also it uses a clever double EGREP trick + instead of compiling, which could give false positives. Thanks to + Dan Winship for the hint. + Wed Apr 18 17:35:38 2001 Owen Taylor * gutils.c (_glib_gettext): Add missing static pointed diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 32425b49b..05717d99f 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,14 @@ +2001-04-19 Sebastian Wilhelmi + + * configure.in: Removed bashism in test for the pkg-config + version. + + * configure.in: Rewrote test for multithread flag. Now uses + localtime_r, which hopefully has a consistent prototype across + different platforms. Also it uses a clever double EGREP trick + instead of compiling, which could give false positives. Thanks to + Dan Winship for the hint. + Wed Apr 18 17:35:38 2001 Owen Taylor * gutils.c (_glib_gettext): Add missing static pointed diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 32425b49b..05717d99f 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,14 @@ +2001-04-19 Sebastian Wilhelmi + + * configure.in: Removed bashism in test for the pkg-config + version. + + * configure.in: Rewrote test for multithread flag. Now uses + localtime_r, which hopefully has a consistent prototype across + different platforms. Also it uses a clever double EGREP trick + instead of compiling, which could give false positives. Thanks to + Dan Winship for the hint. + Wed Apr 18 17:35:38 2001 Owen Taylor * gutils.c (_glib_gettext): Add missing static pointed diff --git a/configure.in b/configure.in index ae2ff8f94..fc041bfee 100644 --- a/configure.in +++ b/configure.in @@ -154,7 +154,9 @@ if test x$PKG_CONFIG = xno ; then AC_MSG_ERROR([*** pkg-config not found. See http://pkgconfig.sourceforge.net]) fi -if ! pkg-config --atleast-pkgconfig-version 0.5 ; then +if pkg-config --atleast-pkgconfig-version 0.5 ; then + : +else AC_MSG_ERROR([*** pkg-config too old; version 0.5 or better required.]) fi @@ -1004,17 +1006,22 @@ if test x"$have_threads" != xnone; then G_THREAD_CFLAGS="$G_THREAD_CFLAGS -D_POSIX4A_DRAFT10_SOURCE" esac - # if we are not finding the ctime_r function, then we probably are + # if we are not finding the localtime_r function, then we probably are # not using the proper multithread flag glib_save_CPPFLAGS="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $G_THREAD_CFLAGS" - AC_TRY_COMPILE([#include ], - [time_t t; char b[30]; ctime_r (&t, b);], , - [AC_TRY_COMPILE([#include ], - [time_t t; char b[30]; ctime_r (&t, b, 30);], , - AC_MSG_WARN($FLAG_DOES_NOT_WORK))]) + # First we test, whether localtime_r is declared in time.h + # directly. Then we test wether a macro localtime_r exists, in + # which case localtime_r in the test program is replaced and thus + # if we still find localtime_r in the output, it is not defined as + # a macro. + + AC_EGREP_CPP([[^a-zA-Z1-9_]localtime_r[^a-zA-Z1-9_]], [#include ], , + [AC_EGREP_CPP([[^a-zA-Z1-9_]localtime_r[^a-zA-Z1-9_]], [#include + localtime_r(a,b)], + AC_MSG_WARN($FLAG_DOES_NOT_WORK))]) CPPFLAGS="$glib_save_CPPFLAGS"