mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-12 13:49:22 +01:00
Factor out repeated thread test into a m4_define(); when cross-compiling,
Wed Dec 11 15:10:25 2002 Owen Taylor <otaylor@redhat.com> * configure.in: Factor out repeated thread test into a m4_define(); when cross-compiling, assume that AC_LINK_IFELSE() is good enough for thinking that -pthread[s] is OK. (More of #58786) * m4macros/glib-gettext.m4: Fix typo. (Manish Singh)
This commit is contained in:
parent
a16cef0867
commit
d67044c391
@ -1,3 +1,12 @@
|
|||||||
|
Wed Dec 11 15:10:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* configure.in: Factor out repeated thread test into
|
||||||
|
a m4_define(); when cross-compiling, assume that
|
||||||
|
AC_LINK_IFELSE() is good enough for thinking that
|
||||||
|
-pthread[s] is OK. (More of #58786)
|
||||||
|
|
||||||
|
* m4macros/glib-gettext.m4: Fix typo. (Manish Singh)
|
||||||
|
|
||||||
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* configure.in: Version 2.1.4, interface age 1.
|
* configure.in: Version 2.1.4, interface age 1.
|
||||||
|
@ -1,3 +1,12 @@
|
|||||||
|
Wed Dec 11 15:10:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* configure.in: Factor out repeated thread test into
|
||||||
|
a m4_define(); when cross-compiling, assume that
|
||||||
|
AC_LINK_IFELSE() is good enough for thinking that
|
||||||
|
-pthread[s] is OK. (More of #58786)
|
||||||
|
|
||||||
|
* m4macros/glib-gettext.m4: Fix typo. (Manish Singh)
|
||||||
|
|
||||||
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* configure.in: Version 2.1.4, interface age 1.
|
* configure.in: Version 2.1.4, interface age 1.
|
||||||
|
@ -1,3 +1,12 @@
|
|||||||
|
Wed Dec 11 15:10:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* configure.in: Factor out repeated thread test into
|
||||||
|
a m4_define(); when cross-compiling, assume that
|
||||||
|
AC_LINK_IFELSE() is good enough for thinking that
|
||||||
|
-pthread[s] is OK. (More of #58786)
|
||||||
|
|
||||||
|
* m4macros/glib-gettext.m4: Fix typo. (Manish Singh)
|
||||||
|
|
||||||
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* configure.in: Version 2.1.4, interface age 1.
|
* configure.in: Version 2.1.4, interface age 1.
|
||||||
|
@ -1,3 +1,12 @@
|
|||||||
|
Wed Dec 11 15:10:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* configure.in: Factor out repeated thread test into
|
||||||
|
a m4_define(); when cross-compiling, assume that
|
||||||
|
AC_LINK_IFELSE() is good enough for thinking that
|
||||||
|
-pthread[s] is OK. (More of #58786)
|
||||||
|
|
||||||
|
* m4macros/glib-gettext.m4: Fix typo. (Manish Singh)
|
||||||
|
|
||||||
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* configure.in: Version 2.1.4, interface age 1.
|
* configure.in: Version 2.1.4, interface age 1.
|
||||||
|
@ -1,3 +1,12 @@
|
|||||||
|
Wed Dec 11 15:10:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* configure.in: Factor out repeated thread test into
|
||||||
|
a m4_define(); when cross-compiling, assume that
|
||||||
|
AC_LINK_IFELSE() is good enough for thinking that
|
||||||
|
-pthread[s] is OK. (More of #58786)
|
||||||
|
|
||||||
|
* m4macros/glib-gettext.m4: Fix typo. (Manish Singh)
|
||||||
|
|
||||||
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* configure.in: Version 2.1.4, interface age 1.
|
* configure.in: Version 2.1.4, interface age 1.
|
||||||
|
@ -1,3 +1,12 @@
|
|||||||
|
Wed Dec 11 15:10:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* configure.in: Factor out repeated thread test into
|
||||||
|
a m4_define(); when cross-compiling, assume that
|
||||||
|
AC_LINK_IFELSE() is good enough for thinking that
|
||||||
|
-pthread[s] is OK. (More of #58786)
|
||||||
|
|
||||||
|
* m4macros/glib-gettext.m4: Fix typo. (Manish Singh)
|
||||||
|
|
||||||
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* configure.in: Version 2.1.4, interface age 1.
|
* configure.in: Version 2.1.4, interface age 1.
|
||||||
|
@ -1,3 +1,12 @@
|
|||||||
|
Wed Dec 11 15:10:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* configure.in: Factor out repeated thread test into
|
||||||
|
a m4_define(); when cross-compiling, assume that
|
||||||
|
AC_LINK_IFELSE() is good enough for thinking that
|
||||||
|
-pthread[s] is OK. (More of #58786)
|
||||||
|
|
||||||
|
* m4macros/glib-gettext.m4: Fix typo. (Manish Singh)
|
||||||
|
|
||||||
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
Wed Dec 11 14:28:50 2002 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* configure.in: Version 2.1.4, interface age 1.
|
* configure.in: Version 2.1.4, interface age 1.
|
||||||
|
48
configure.in
48
configure.in
@ -1269,6 +1269,21 @@ G_THREAD_LIBS=
|
|||||||
G_THREAD_LIBS_EXTRA=
|
G_THREAD_LIBS_EXTRA=
|
||||||
G_THREAD_CFLAGS=
|
G_THREAD_CFLAGS=
|
||||||
|
|
||||||
|
dnl
|
||||||
|
dnl Test program for basic POSIX threads functionality
|
||||||
|
dnl
|
||||||
|
m4_define([glib_thread_test],[
|
||||||
|
#include <pthread.h>
|
||||||
|
int check_me = 0;
|
||||||
|
void* func(void* data) {return check_me = 42;}
|
||||||
|
main()
|
||||||
|
{ pthread_t t;
|
||||||
|
void *ret;
|
||||||
|
pthread_create (&t, 0, func, 0);
|
||||||
|
pthread_join (t, &ret);
|
||||||
|
exit (check_me != 42 || ret != 42);
|
||||||
|
}])
|
||||||
|
|
||||||
if test x"$have_threads" != xno; then
|
if test x"$have_threads" != xno; then
|
||||||
|
|
||||||
if test x"$have_threads" = xposix; then
|
if test x"$have_threads" = xposix; then
|
||||||
@ -1279,19 +1294,17 @@ if test x"$have_threads" != xno; then
|
|||||||
for flag in pthread pthreads; do
|
for flag in pthread pthreads; do
|
||||||
glib_save_CFLAGS="$CFLAGS"
|
glib_save_CFLAGS="$CFLAGS"
|
||||||
CFLAGS="$CFLAGS -$flag"
|
CFLAGS="$CFLAGS -$flag"
|
||||||
AC_TRY_RUN([#include <pthread.h>
|
AC_TRY_RUN(glib_thread_test,
|
||||||
int check_me = 0;
|
glib_flag_works=yes,
|
||||||
void* func(void* data) {return check_me = 42;}
|
glib_flag_works=no,
|
||||||
main()
|
AC_LINK_IFELSE(glib_thread_test,
|
||||||
{ pthread_t t;
|
glib_flag_works=yes,
|
||||||
void *ret;
|
glib_flag_works=no))
|
||||||
pthread_create (&t, 0, func, 0);
|
|
||||||
pthread_join (t, &ret);
|
|
||||||
exit (check_me != 42 || ret != 42);
|
|
||||||
}],
|
|
||||||
[G_THREAD_CFLAGS=-$flag
|
|
||||||
G_THREAD_LIBS=-$flag])
|
|
||||||
CFLAGS="$glib_save_CFLAGS"
|
CFLAGS="$glib_save_CFLAGS"
|
||||||
|
if test $glib_flag_works = yes ; then
|
||||||
|
G_THREAD_CFLAGS=-$flag
|
||||||
|
G_THREAD_LIBS=-$flag
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -1408,16 +1421,7 @@ case $have_threads in
|
|||||||
LIBS="$glib_save_LIBS $add_thread_lib"
|
LIBS="$glib_save_LIBS $add_thread_lib"
|
||||||
|
|
||||||
AC_MSG_CHECKING(for pthread_create/pthread_join$IN)
|
AC_MSG_CHECKING(for pthread_create/pthread_join$IN)
|
||||||
AC_TRY_RUN([#include <pthread.h>
|
AC_TRY_RUN(glib_thread_test,
|
||||||
int check_me = 0;
|
|
||||||
void* func(void* data) {check_me = 42;}
|
|
||||||
main()
|
|
||||||
{ pthread_t t;
|
|
||||||
void *ret;
|
|
||||||
pthread_create (&t, $defattr, func, 0);
|
|
||||||
pthread_join (t, &ret);
|
|
||||||
exit (check_me != 42);
|
|
||||||
}],
|
|
||||||
[AC_MSG_RESULT(yes)
|
[AC_MSG_RESULT(yes)
|
||||||
G_THREAD_LIBS="$add_thread_lib"
|
G_THREAD_LIBS="$add_thread_lib"
|
||||||
break],
|
break],
|
||||||
|
@ -26,7 +26,7 @@ dnl
|
|||||||
|
|
||||||
# GLIB_LC_MESSAGES
|
# GLIB_LC_MESSAGES
|
||||||
#--------------------
|
#--------------------
|
||||||
glib_DEFUN([glib_LC_MESSAGES],
|
glib_DEFUN([GLIB_LC_MESSAGES],
|
||||||
[AC_CHECK_HEADERS([locale.h])
|
[AC_CHECK_HEADERS([locale.h])
|
||||||
if test $ac_cv_header_locale_h = yes; then
|
if test $ac_cv_header_locale_h = yes; then
|
||||||
AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
|
AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user