1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-18 17:42:25 +03:00

Check and set thread-safe functions separately, rather than as a single

variable.

Remove thread locking for non-thread-safe functions, instead throw a
compile error.

Platforms will have to re-run tools/thread to record their thread
safety.
This commit is contained in:
Bruce Momjian
2004-02-11 21:44:06 +00:00
parent 15b330b648
commit c6f0559371
12 changed files with 134 additions and 241 deletions

View File

@ -3,4 +3,7 @@ case $host_os in
esac
THREAD_SUPPORT=yes
NEED_REENTRANT_FUNCS=no # verified 4.3 2003-09-26
# verified 4.3.1 2004-02-11
STRERROR_THREADSAFE=yes
GETPWUID_THREADSAFE=yes
GETHOSTBYNAME_THREADSAFE=yes

View File

@ -2,8 +2,7 @@ case $host_cpu in
alpha*) CFLAGS="-O";; # alpha has problems with -O2
esac
THREAD_SUPPORT=yes
NEED_REENTRANT_FUNCS=yes
# tools/thread/thread_test must be run
THREAD_CPPFLAGS="-D_THREAD_SAFE"
case $host_os in
freebsd2*|freebsd3*|freebsd4*) THREAD_LIBS="-pthread";;

View File

@ -1,7 +1,6 @@
# Force _GNU_SOURCE on; plperl is broken with Perl 5.8.0 otherwise
CPPFLAGS="-D_GNU_SOURCE"
THREAD_SUPPORT=yes
NEED_REENTRANT_FUNCS=yes # Debian kernel 2.2 2003-09-27
# tools/thread/thread_test must be run
THREAD_CPPFLAGS="-D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
THREAD_LIBS="-lpthread"

View File

@ -1,2 +1 @@
THREAD_SUPPORT=yes
NEED_REENTRANT_FUNCS=yes # 1.6 2003-09-14
# tools/thread/thread_test must be run

View File

@ -3,8 +3,7 @@ if test "$GCC" != yes ; then
CFLAGS="-O -ieee"
fi
THREAD_SUPPORT=yes
NEED_REENTRANT_FUNCS=no # 4.0 2003-09-13
# tools/thread/thread_test must be run
if test "$GCC" = yes
then THREAD_LIBS="-pthread"
else THREAD_CPPFLAGS="-pthread"

View File

@ -9,8 +9,7 @@ case $host in
i?86-*-solaris*) need_tas=yes; tas_file=solaris_i386.s ;;
esac
THREAD_SUPPORT=yes
NEED_REENTRANT_FUNCS=yes # 5.6 2003-09-13
# tools/thread/thread_test must be run
if test "$GCC" = yes
then THREAD_LIBS="-pthread"
else THREAD_CPPFLAGS="-mt"

View File

@ -24,6 +24,5 @@ __EOF__
THREAD_CPPFLAGS="-K pthread"
fi
THREAD_SUPPORT=yes
NEED_REENTRANT_FUNCS=no # verified 7.1.3 2003-09-03
# tools/thread/thread_test must be run
THREAD_CPPFLAGS="$THREAD_CPPFLAGS -D_REENTRANT"