[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[dotgnu-pnet-commits] pnet ChangeLog configure.in engine/engine.c sup...
From: |
Klaus Treichel |
Subject: |
[dotgnu-pnet-commits] pnet ChangeLog configure.in engine/engine.c sup... |
Date: |
Sun, 09 Dec 2007 21:17:21 +0000 |
CVSROOT: /cvsroot/dotgnu-pnet
Module name: pnet
Changes by: Klaus Treichel <ktreichel> 07/12/09 21:17:20
Modified files:
. : ChangeLog configure.in
engine : engine.c
support : thr_choose.h
Log message:
Add NetBSD threading support.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/pnet/ChangeLog?cvsroot=dotgnu-pnet&r1=1.3523&r2=1.3524
http://cvs.savannah.gnu.org/viewcvs/pnet/configure.in?cvsroot=dotgnu-pnet&r1=1.228&r2=1.229
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/engine.c?cvsroot=dotgnu-pnet&r1=1.2&r2=1.3
http://cvs.savannah.gnu.org/viewcvs/pnet/support/thr_choose.h?cvsroot=dotgnu-pnet&r1=1.9&r2=1.10
Patches:
Index: ChangeLog
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/ChangeLog,v
retrieving revision 1.3523
retrieving revision 1.3524
diff -u -b -r1.3523 -r1.3524
--- ChangeLog 7 Dec 2007 12:36:13 -0000 1.3523
+++ ChangeLog 9 Dec 2007 21:17:20 -0000 1.3524
@@ -1,3 +1,16 @@
+2007-12-09 Klaus Treichel <address@hidden>
+
+ * engine/engine.c: Move thread initialization in front of the creation
+ of the global trace mutex because the thread library has to be
initialized
+ before any thread features can be used.
+ This fixes a bug with pthreads where the global mutex attribute was not
+ initialized when the global trace mutex was created.
+
+ * configure.in, support/thr_choose.h: Add thread support for NetBSD.
+
+ * configure.in: Install the libraries in the correct directory on
+ multi os systems (like x86_64).
+
2007-12-07 Radek Polak <address@hidden>
* engine/debugger.c: Fix debugger crash when watching "this" in struct
Index: configure.in
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/configure.in,v
retrieving revision 1.228
retrieving revision 1.229
diff -u -b -r1.228 -r1.229
--- configure.in 10 Sep 2007 08:38:23 -0000 1.228
+++ configure.in 9 Dec 2007 21:17:20 -0000 1.229
@@ -256,6 +256,9 @@
*-freebsd*)
THREADS=posix
;;
+ *-*-netbsd*)
+ THREADS=posix
+ ;;
*-*-darwin*)
THREADS=posix
;;
@@ -314,6 +317,13 @@
INCLUDES="$INCLUDES -pthread"
THREADLIBS=-pthread
;;
+ *-*-netbsd*)
+ AC_DEFINE(GC_NETBSD_THREADS, 1, [Define to use libgc netbsd thread
support])
+ INCLUDES="$INCLUDES -pthread"
+ THREADLIBS="-lpthread -lrt"
+ AC_DEFINE(_REENTRANT, 1, [Define to use the reentrant versions of
library functions])
+ AC_DEFINE(_PTHREADS, 1, [Define to enable pthread support])
+ ;;
*-*-darwin*)
AC_DEFINE(GC_DARWIN_THREADS, 1, [Define to use libgc darwin thread
support])
INCLUDES="$INCLUDES -pthread"
@@ -672,6 +682,16 @@
esac],[tools=true])
AM_CONDITIONAL(PNET_TOOLS, test x$tools = xtrue)
+dnl Check for building on a multi os system
+if test x$GCC = xyes ; then
+ multi_os_directory=`$CC -print-multi-os-directory`
+ case $multi_os_directory in
+ .) ;; # Avoid trailing /.
+ *) libdir=$libdir/$multi_os_directory ;;
+ esac
+fi
+AC_SUBST(libdir)
+
dnl Set up libffi-related variables.
AC_SUBST(FFILIBS)
if test x$withffi = xyes ; then
Index: engine/engine.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/engine.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- engine/engine.c 19 Dec 2005 18:00:35 -0000 1.2
+++ engine/engine.c 9 Dec 2007 21:17:20 -0000 1.3
@@ -44,6 +44,10 @@
#ifdef IL_CONFIG_APPDOMAINS
globalEngine = 0;
#endif
+
+ /* Initialize the thread routines */
+ ILThreadInit();
+
#if !defined(IL_CONFIG_REDUCE_CODE) && !defined(IL_WITHOUT_TOOLS)
/* Create the global trace mutex */
if ((globalTraceMutex = ILMutexCreate()) == 0)
@@ -58,9 +62,6 @@
}
#endif
- /* Initialize the thread routines */
- ILThreadInit();
-
/* Initialize the global garbage collector */
ILGCInit(maxSize);
Index: support/thr_choose.h
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/support/thr_choose.h,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- support/thr_choose.h 1 Nov 2005 19:14:19 -0000 1.9
+++ support/thr_choose.h 9 Dec 2007 21:17:20 -0000 1.10
@@ -37,10 +37,10 @@
#if !defined(IL_NO_THREADS)
#if defined(linux) || defined(__linux) || defined(__linux__) || \
defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__sun) || \
- defined(__APPLE__)
+ defined(_NetBSD__) || defined(__APPLE__)
#if defined(GC_LINUX_THREADS) || defined(GC_FREEBSD_THREADS) || \
defined(GC_OPENBSD_THREADS) || defined(GC_SOLARIS_THREADS) || \
- defined(GC_DARWIN_THREADS)
+ defined(GC_NETBSD_THREADS) || defined(GC_DARWIN_THREADS)
#define IL_USE_PTHREADS
#endif
#endif
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [dotgnu-pnet-commits] pnet ChangeLog configure.in engine/engine.c sup...,
Klaus Treichel <=