This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
configure forces use of threads under 10.20
- To: egcs-bugs at egcs dot cygnus dot com
- Subject: configure forces use of threads under 10.20
- From: "John David Anglin" <dave at hiauly1 dot hia dot nrc dot ca>
- Date: Fri, 29 Oct 1999 12:30:07 -0400 (EDT)
Under HP-UX 10.20, if configure finds pthread.h, it enables threads.
It is not possible to disable threads in this situation. The logic
of the test is wrong. What should be done is to disable threads if
pthread.h is not found, and to require the user to explicitly enable
threads (i.e., default is disabled). I have included a small patch
to correct this behaviour under gcc-2.95.2.
Further work on configure is needed if the user wants to use the GNU
pth/pthread implementation in place of the HP DCE implimentation. I
also believe that there are linking problems (i.e., specs needs to be
fixed) if --enable-shared and --enable-threads are both specified.
I haven't attempted to sort this out.
-
J. David Anglin dave.anglin@nrc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6605)
--- configure.in.orig Thu Oct 28 18:23:09 1999
+++ configure.in Thu Oct 28 18:27:23 1999
@@ -940,7 +940,7 @@
then
tm_file="${tm_file} pa/pa-gas.h"
fi
- if test x$enable_threads = x; then
+ if test x$have_pthread_h = x; then
enable_threads=$have_pthread_h
fi
if test x$enable_threads = xyes; then
@@ -959,7 +959,7 @@
then
tm_file="${tm_file} pa/pa-gas.h"
fi
- if test x$enable_threads = x; then
+ if test x$have_pthread_h = x; then
enable_threads=$have_pthread_h
fi
if test x$enable_threads = xyes; then