blob: 5c90baa1f2acdfbe4278cb6e09e0952f3bfef671 (
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
$NetBSD: patch-am,v 1.1.1.1 2009/01/04 00:21:36 adrianp Exp $
--- config.threads.in.orig 2005-03-16 07:59:16.000000000 +0900
+++ config.threads.in
@@ -48,6 +48,8 @@ case $host in
use_threads=false ;;
*-freebsd*)
use_threads=false ;;
+*-dragonfly*)
+ use_threads=false ;;
*-bsdi[234]*)
# Thread signals do not work reliably on some versions of BSD/OS.
use_threads=false ;;
@@ -121,7 +123,7 @@ then
AC_MSG_RESULT(native)
LIBS="-lpthread $LIBS"
else
- if test ! -d $LOCALBASE/pthreads
+ if test ! -d $LOCALBASE/pthreads -a ! -f /usr/include/pthread.h
then
AC_MSG_RESULT(none)
AC_MSG_ERROR("could not find thread libraries")
@@ -129,13 +131,21 @@ then
if $use_threads
then
- AC_MSG_RESULT(mit-pthreads/unproven-pthreads)
- pkg="$LOCALBASE/pthreads"
- lib1="-L$pkg/lib -Wl,-R$pkg/lib"
- lib2="-lpthread -lm -lgcc -lpthread"
- LIBS="$lib1 $lib2 $LIBS"
- CPPFLAGS="$CPPFLAGS -I$pkg/include"
- STD_CINCLUDES="$STD_CINCLUDES -I$pkg/include"
+ if test -f /usr/include/pthread.h
+ then
+ AC_MSG_RESULT(native pthreads)
+ LIBS="-lpthread $LIBS"
+ CPPFLAGS="$CPPFLAGS -I/usr/inclue"
+ STD_CINDLUES="$STD_CINDLUES -I/usr/include"
+ else
+ AC_MSG_RESULT(mit-pthreads/unproven-pthreads)
+ pkg="$LOCALBASE/pthreads"
+ lib1="-L$pkg/lib -Wl,-R$pkg/lib"
+ lib2="-lpthread -lm -lgcc -lpthread"
+ LIBS="$lib1 $lib2 $LIBS"
+ CPPFLAGS="$CPPFLAGS -I$pkg/include"
+ STD_CINCLUDES="$STD_CINCLUDES -I$pkg/include"
+ fi
fi
fi
fi
|