blob: ea66f47f410cb001bb2b3083fed06e912d85cb0a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
if test "$GCC" = yes; then
THREAD_CPPFLAGS="-pthread"
else
# The -Kno_host is for a bug in the compiler. See -hackers
# discussion on 7-8/Aug/2003.
cat >conftest.c <<__EOF__
extern char *strcpy(char *, const char *);
static void f(char *p, int n){
strcpy(p+n,"");
}
void g(void){
f(0, 0);
}
__EOF__
if $CC -c -O -Kinline conftest.c >conftest.err 2>&1; then
CFLAGS="-O -Kinline"
else
CFLAGS="-O -Kinline,no_host"
fi
rm -f conftest.*
THREAD_CPPFLAGS="-K pthread"
fi
# tools/thread/thread_test must be run
THREAD_CPPFLAGS="$THREAD_CPPFLAGS -D_REENTRANT"
# Disabled because flags are required for all apps using libpq.
# Waiting to see if other platforms need this too. 2004-03-22
#THREAD_SUPPORT=yes
# verified UnixWare 7.1.4 2004-03-18
STRERROR_THREADSAFE=yes
GETPWUID_THREADSAFE=yes
GETHOSTBYNAME_THREADSAFE=yes
|