aboutsummaryrefslogtreecommitdiff
path: root/gcc/config.gcc
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@libertysurf.fr>2004-11-22 23:26:11 +0100
committerEric Botcazou <ebotcazou@gcc.gnu.org>2004-11-22 22:26:11 +0000
commit181674429bc9e230b405b98694ab423c8bdb42eb (patch)
tree429455b0553bb86246e8d7679840ae2346140ce4 /gcc/config.gcc
parent515a17919798a2c9597b2cf02660b9b07afd3fc4 (diff)
downloadgcc-181674429bc9e230b405b98694ab423c8bdb42eb.zip
gcc-181674429bc9e230b405b98694ab423c8bdb42eb.tar.gz
gcc-181674429bc9e230b405b98694ab423c8bdb42eb.tar.bz2
re PR target/18444 (Multithreading broken on Unix95-class platforms)
PR target/18444 * configure.ac (threading): Accept 'posix95'. * configure: Regenerate. * config.gcc (i[34567]86-*-solaris2*): On Solaris up to 2.6, include sol26.h and default to posix95 threads if have_pthread_h. (sparc-*-solaris2*): Likewise. * gthr.h: Include gthr-posix95.h if _PTHREADS95 is defined. * gthr-posix95.h: New file. * config/sol26.h: New file. * doc/install.texi (--enable-threads): Document 'posix95'. From-SVN: r91041
Diffstat (limited to 'gcc/config.gcc')
-rw-r--r--gcc/config.gcc44
1 files changed, 38 insertions, 6 deletions
diff --git a/gcc/config.gcc b/gcc/config.gcc
index 0a1e5f4..0b4cef1 100644
--- a/gcc/config.gcc
+++ b/gcc/config.gcc
@@ -1012,7 +1012,12 @@ i[34567]86-*-sco3.2v5*) # 80386 running SCO Open Server 5
;;
i[34567]86-*-solaris2*)
xm_defines="SMALL_ARG_MAX"
- tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h i386/sysv4.h sol2.h i386/sol2.h"
+ tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h i386/sysv4.h sol2.h"
+ case ${target} in
+ *-*-solaris2.[0-6] | *-*-solaris2.[0-6].*)
+ tm_file="${tm_file} sol26.h"
+ esac
+ tm_file="${tm_file} i386/sol2.h"
tmake_file="t-sol2 i386/t-sol2 t-svr4"
c_target_objs="sol2-c.o"
cxx_target_objs="sol2-c.o"
@@ -1044,8 +1049,19 @@ i[34567]86-*-solaris2*)
;;
esac
case ${enable_threads}:${have_pthread_h}:${have_thread_h} in
- "":yes:* | yes:yes:* ) thread_file=posix ;;
- "":*:yes | yes:*:yes ) thread_file=solaris ;;
+ "":yes:* | yes:yes:* )
+ case ${target} in
+ *-*-solaris2.[0-6] | *-*-solaris2.[0-6].*)
+ thread_file=posix95
+ ;;
+ *)
+ thread_file=posix
+ ;;
+ esac
+ ;;
+ "":*:yes | yes:*:yes )
+ thread_file=solaris
+ ;;
esac
;;
i[34567]86-*-sysv5*) # Intel x86 on System V Release 5
@@ -1902,7 +1918,12 @@ sparc64-*-solaris2* | sparcv9-*-solaris2*)
need_64bit_hwint=yes
;;
sparc-*-solaris2*)
- tm_file="${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h sol2.h sparc/sol2.h"
+ tm_file="${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h sol2.h"
+ case ${target} in
+ *-*-solaris2.[0-6] | *-*-solaris2.[0-6].*)
+ tm_file="${tm_file} sol26.h"
+ esac
+ tm_file="${tm_file} sparc/sol2.h"
if test x$gnu_ld = xyes; then
tm_file="${tm_file} sparc/sol2-gld.h"
fi
@@ -1939,8 +1960,19 @@ sparc-*-solaris2*)
tm_p_file="${tm_p_file} sol2-protos.h"
extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
case ${enable_threads}:${have_pthread_h}:${have_thread_h} in
- "":yes:* | yes:yes:* ) thread_file=posix ;;
- "":*:yes | yes:*:yes ) thread_file=solaris ;;
+ "":yes:* | yes:yes:* )
+ case ${target} in
+ *-*-solaris2.[0-6] | *-*-solaris2.[0-6].*)
+ thread_file=posix95
+ ;;
+ *)
+ thread_file=posix
+ ;;
+ esac
+ ;;
+ "":*:yes | yes:*:yes )
+ thread_file=solaris
+ ;;
esac
;;
sparc-*-sysv4*)