ICU-227 Fix some pthreads checks for OS390, fix a date..

X-SVN-Rev: 666
This commit is contained in:
Steven R. Loomis 2000-01-20 21:31:01 +00:00
parent 0be3b10b9a
commit 484f05fa88
4 changed files with 72 additions and 62 deletions

View File

@ -12,13 +12,13 @@
<h2>ReadMe: IBM Classes For Unicode</h2>
<p>Version: 12/28/2000<br>
<p>Version: 12/28/1999<br>
</p>
<hr>
<p>COPYRIGHT: <br>
Copyright © 1997-2000 International Business Machines Corporation an others. All Rights
Copyright (c) 1997-2000 International Business Machines Corporation an others. All Rights
Reserved.</p>
<hr>

View File

@ -59,7 +59,7 @@ char pthread_create();
pthread_create();,
eval "ac_ldflag_pthread=yes",
eval "ac_ldflag_pthread=no"),
LIBS="$ac_save_LDFLAGS"
LDFLAGS="$ac_save_LDFLAGS"
])
if eval "test \"`echo $ac_ldflag_pthread`\" = yes"; then
AC_MSG_RESULT(yes)

121
icu4c/source/configure vendored
View File

@ -1602,7 +1602,7 @@ else
eval "ac_ldflag_pthread=no"
fi
rm -f conftest*,
LIBS="$ac_save_LDFLAGS"
LDFLAGS="$ac_save_LDFLAGS"
fi
@ -1614,61 +1614,66 @@ else
fi
fi
echo $ac_n "checking for pthread_mutex_create""... $ac_c" 1>&6
echo "configure:1619: checking for pthread_mutex_create" >&5
if eval "test \"`echo '$''{'ac_cv_func_pthread_mutex_create'+set}'`\" = set"; then
echo $ac_n "checking for pthread_mutex_lock""... $ac_c" 1>&6
echo "configure:1619: checking for pthread_mutex_lock" >&5
if eval "test \"`echo '$''{'ac_cv_func_pthread_mutex_lock'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1624 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char pthread_mutex_create(); below. */
which can conflict with char pthread_mutex_lock(); below. */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
char pthread_mutex_create();
char pthread_mutex_lock();
int main() {
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_pthread_mutex_create) || defined (__stub___pthread_mutex_create)
#if defined (__stub_pthread_mutex_lock) || defined (__stub___pthread_mutex_lock)
choke me
#else
pthread_mutex_create();
pthread_mutex_lock();
#endif
; return 0; }
EOF
if { (eval echo configure:1647: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_pthread_mutex_create=yes"
eval "ac_cv_func_pthread_mutex_lock=yes"
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -rf conftest*
eval "ac_cv_func_pthread_mutex_create=no"
eval "ac_cv_func_pthread_mutex_lock=no"
fi
rm -f conftest*
fi
if eval "test \"`echo '$ac_cv_func_'pthread_mutex_create`\" = yes"; then
if eval "test \"`echo '$ac_cv_func_'pthread_mutex_lock`\" = yes"; then
echo "$ac_t""yes" 1>&6
:
else
echo "$ac_t""no" 1>&6
fi
if test $ac_cv_func_pthread_mutex_lock = yes; then
ICU_USE_THREADS=1
fi
fi
fi
echo $ac_n "checking for wcscpy in -lwcs""... $ac_c" 1>&6
echo "configure:1672: checking for wcscpy in -lwcs" >&5
echo "configure:1677: checking for wcscpy in -lwcs" >&5
ac_lib_var=`echo wcs'_'wcscpy | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@ -1676,7 +1681,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lwcs $LIBS"
cat > conftest.$ac_ext <<EOF
#line 1680 "configure"
#line 1685 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@ -1687,7 +1692,7 @@ int main() {
wcscpy()
; return 0; }
EOF
if { (eval echo configure:1691: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1696: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@ -1721,7 +1726,7 @@ HAVE_DLOPEN=0
#add more libs here..
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
echo "configure:1725: checking for dlopen in -ldl" >&5
echo "configure:1730: checking for dlopen in -ldl" >&5
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@ -1729,7 +1734,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
#line 1733 "configure"
#line 1738 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@ -1740,7 +1745,7 @@ int main() {
dlopen()
; return 0; }
EOF
if { (eval echo configure:1744: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1749: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@ -1774,7 +1779,7 @@ fi
if test $HAVE_DLOPEN = 0; then
echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
echo "configure:1778: checking for shl_load in -ldld" >&5
echo "configure:1783: checking for shl_load in -ldld" >&5
ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@ -1782,7 +1787,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-ldld $LIBS"
cat > conftest.$ac_ext <<EOF
#line 1786 "configure"
#line 1791 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@ -1793,7 +1798,7 @@ int main() {
shl_load()
; return 0; }
EOF
if { (eval echo configure:1797: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1802: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@ -1830,7 +1835,7 @@ fi
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
echo "configure:1834: checking how to run the C preprocessor" >&5
echo "configure:1839: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@ -1845,13 +1850,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
#line 1849 "configure"
#line 1854 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:1855: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:1860: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@ -1862,13 +1867,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
#line 1866 "configure"
#line 1871 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:1872: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:1877: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@ -1879,13 +1884,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
#line 1883 "configure"
#line 1888 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:1889: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:1894: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@ -1913,17 +1918,17 @@ for ac_hdr in inttypes.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:1917: checking for $ac_hdr" >&5
echo "configure:1922: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1922 "configure"
#line 1927 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:1927: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:1932: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@ -1957,14 +1962,14 @@ fi
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
echo "configure:1961: checking whether byte ordering is bigendian" >&5
echo "configure:1966: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_bigendian=unknown
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
#line 1968 "configure"
#line 1973 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
@ -1975,11 +1980,11 @@ int main() {
#endif
; return 0; }
EOF
if { (eval echo configure:1979: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:1984: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
#line 1983 "configure"
#line 1988 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
@ -1990,7 +1995,7 @@ int main() {
#endif
; return 0; }
EOF
if { (eval echo configure:1994: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:1999: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
else
@ -2010,7 +2015,7 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
#line 2014 "configure"
#line 2019 "configure"
#include "confdefs.h"
main () {
/* Are we little or big endian? From Harbison&Steele. */
@ -2023,7 +2028,7 @@ main () {
exit (u.c[sizeof (long) - 1] == 1);
}
EOF
if { (eval echo configure:2027: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
if { (eval echo configure:2032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
else
@ -2055,12 +2060,12 @@ fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
echo "configure:2059: checking for ANSI C header files" >&5
echo "configure:2064: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2064 "configure"
#line 2069 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@ -2068,7 +2073,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2072: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2077: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@ -2085,7 +2090,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
#line 2089 "configure"
#line 2094 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@ -2103,7 +2108,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
#line 2107 "configure"
#line 2112 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@ -2124,7 +2129,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
#line 2128 "configure"
#line 2133 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@ -2135,7 +2140,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
if { (eval echo configure:2139: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
if { (eval echo configure:2144: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
@ -2159,12 +2164,12 @@ EOF
fi
echo $ac_n "checking for int8_t""... $ac_c" 1>&6
echo "configure:2163: checking for int8_t" >&5
echo "configure:2168: checking for int8_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int8_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2168 "configure"
#line 2173 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@ -2192,12 +2197,12 @@ EOF
fi
echo $ac_n "checking for uint8_t""... $ac_c" 1>&6
echo "configure:2196: checking for uint8_t" >&5
echo "configure:2201: checking for uint8_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_uint8_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2201 "configure"
#line 2206 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@ -2225,12 +2230,12 @@ EOF
fi
echo $ac_n "checking for int16_t""... $ac_c" 1>&6
echo "configure:2229: checking for int16_t" >&5
echo "configure:2234: checking for int16_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2234 "configure"
#line 2239 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@ -2258,12 +2263,12 @@ EOF
fi
echo $ac_n "checking for uint16_t""... $ac_c" 1>&6
echo "configure:2262: checking for uint16_t" >&5
echo "configure:2267: checking for uint16_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_uint16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2267 "configure"
#line 2272 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@ -2291,12 +2296,12 @@ EOF
fi
echo $ac_n "checking for int32_t""... $ac_c" 1>&6
echo "configure:2295: checking for int32_t" >&5
echo "configure:2300: checking for int32_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2300 "configure"
#line 2305 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@ -2324,12 +2329,12 @@ EOF
fi
echo $ac_n "checking for uint32_t""... $ac_c" 1>&6
echo "configure:2328: checking for uint32_t" >&5
echo "configure:2333: checking for uint32_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_uint32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2333 "configure"
#line 2338 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@ -2357,12 +2362,12 @@ EOF
fi
echo $ac_n "checking for bool_t""... $ac_c" 1>&6
echo "configure:2361: checking for bool_t" >&5
echo "configure:2366: checking for bool_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_bool_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2366 "configure"
#line 2371 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS

View File

@ -131,7 +131,12 @@ if test $threads = true; then
AC_PTHREAD_FREEBSD
fi
AC_CHECK_FUNC(pthread_mutex_create)
AC_CHECK_FUNC(pthread_mutex_lock)
if test $ac_cv_func_pthread_mutex_lock = yes; then
ICU_USE_THREADS=1
fi
fi
fi