From 6cbb186b4c78f6704c3849f68e46159f01d31950 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Love=20H=C3=B6rnquist=20=C3=85strand?= Date: Wed, 27 Apr 2005 08:34:07 +0000 Subject: [PATCH] Add support for Solaris, Irix, and modern Linux. From David Love git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14973 ec53bebd-3082-4978-b11e-865c3cabbd6b --- cf/pthreads.m4 | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/cf/pthreads.m4 b/cf/pthreads.m4 index 897f594de..592494c87 100644 --- a/cf/pthreads.m4 +++ b/cf/pthreads.m4 @@ -15,6 +15,13 @@ if test "$enable_pthread_support" = maybe; then case "$host" in *-*-solaris2*) enable_pthread_support=yes + if test "$GCC" = yes; then + PTHREADS_CFLAGS=-pthreads + PTHREADS_LIBS=-pthreads + else + PTHREADS_CFLAGS=-mt + PTHREADS_LIBS=-mt + fi ;; *-*-netbsd*) enable_pthread_support="if running netbsd 1.6T or newer" @@ -24,12 +31,20 @@ case "$host" in *-*-freebsd5*) enable_pthread_support=yes ;; -*-*-linux2[4-9]*) - enable_pthread_support=yes +*-*-linux* | *-*-linux-gnu) + case `uname -r` in + 2.*) + enable_pthread_support=yes + PTHREADS_CFLAGS=-pthread + ;; + esac ;; *-*-aix*) enable_pthread_support=yes ;; +mips-sgi-irix6.[[5-9]]) # maybe works for earlier versions too + enable_pthread_support=yes + ;; *) enable_pthread_support=no ;;