summaryrefslogtreecommitdiffstats
path: root/unix
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2013-08-14 14:40:40 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2013-08-14 14:40:40 (GMT)
commitc4aa43f6610f7f0f1001cdec79b606032f2a146a (patch)
tree94e91ae3890b4925326560afe5560319949c4c6d /unix
parentcb022ef5bd73c2dcf81758815c2b7812e33cb7f5 (diff)
parent34f83405d31dbe1b95f1608c91f483f9170c4d23 (diff)
downloadtcl-c4aa43f6610f7f0f1001cdec79b606032f2a146a.zip
tcl-c4aa43f6610f7f0f1001cdec79b606032f2a146a.tar.gz
tcl-c4aa43f6610f7f0f1001cdec79b606032f2a146a.tar.bz2
merge trunk
Diffstat (limited to 'unix')
-rwxr-xr-xunix/configure4
-rw-r--r--unix/tcl.m44
-rw-r--r--unix/tclUnixTest.c4
3 files changed, 10 insertions, 2 deletions
diff --git a/unix/configure b/unix/configure
index 6edeccd..e96afb9 100755
--- a/unix/configure
+++ b/unix/configure
@@ -4821,6 +4821,9 @@ echo "$as_me: WARNING: Don't know how to find pthread lib on your system - you m
# Does the pthread-implementation provide
# 'pthread_attr_setstacksize' ?
+ ac_saved_libs=$LIBS
+ LIBS="$LIBS $THREADS_LIBS"
+
for ac_func in pthread_attr_setstacksize pthread_atfork
do
@@ -4923,6 +4926,7 @@ _ACEOF
fi
done
+ LIBS=$ac_saved_libs
else
TCL_THREADS=0
fi
diff --git a/unix/tcl.m4 b/unix/tcl.m4
index a7c6b2d..71f4f97 100644
--- a/unix/tcl.m4
+++ b/unix/tcl.m4
@@ -676,7 +676,11 @@ AC_DEFUN([SC_ENABLE_THREADS], [
# Does the pthread-implementation provide
# 'pthread_attr_setstacksize' ?
+
+ ac_saved_libs=$LIBS
+ LIBS="$LIBS $THREADS_LIBS"
AC_CHECK_FUNCS(pthread_attr_setstacksize pthread_atfork)
+ LIBS=$ac_saved_libs
else
TCL_THREADS=0
fi
diff --git a/unix/tclUnixTest.c b/unix/tclUnixTest.c
index 0d5b683..021e0f6 100644
--- a/unix/tclUnixTest.c
+++ b/unix/tclUnixTest.c
@@ -572,8 +572,8 @@ TestforkObjCmd(
"Cannot fork", NULL);
return TCL_ERROR;
}
-#ifndef HAVE_PTHREAD_ATFORK
- /* Only needed when pthread_atfork is not present. */
+#if !defined(HAVE_PTHREAD_ATFORK) || defined(MAC_OSX_TCL)
+ /* Only needed when pthread_atfork is not present or on OSX. */
if (pid==0) {
Tcl_InitNotifier();
}