Re: [Gc] MinGW pthreads support
Ivan Maidanski
ivmai at mail.ru
Fri Jul 1 13:15:22 PDT 2011
Hi Andy,
AICS, the patch does not force BDWGC to use pthreads-win32 (instead it uses native Win32 threads).
You should define GC_PTHREADS (not GC_THREADS) to force it to (if you really need pthreads on Win32). Otherwise THREADDLLIBS="-lpthread" should be removed.
I think we could just use (choosing Win32 threads for mingw):
*-*-cygwin* | *-*-mingw*)
Regards.
01 07 2011, 17:51 Andy Wingo <wingo at pobox.com>:
> Hey folks,
>
> Jan Nieuwenhuizen's "Grand Unified Builder" project[0] has been carrying
> a patch to enable pthreads on mingw for BDW-GC, using the pthreads-win32
> package[1].
>
> [0] http://lilypond.org/gub/
> [1] http://www.mingw.org/wiki/pthreads_library
>
> It's straightforward. Interested?
>
> --- libgc-7.2.4/configure.ac~ 2011-01-31 23:19:46.556212301 +0100
> +++ libgc-7.2.4/configure.ac 2011-01-31 23:22:07.347644925 +0100
> @@ -197,6 +197,14 @@ case "$THREADS" in
> THREADDLLIBS=""
> win32_threads=true
> ;;
> + *-*-mingw*)
> + AC_DEFINE(GC_THREADS)
> + if test "${enable_parallel_mark}" = yes; then
> + AC_DEFINE(PARALLEL_MARK)
> + fi
> + AC_DEFINE(THREAD_LOCAL_ALLOC)
> + THREADDLLIBS="-lpthread"
> + ;;
> *-*-darwin*)
> AC_DEFINE(GC_DARWIN_THREADS)
> AC_DEFINE(THREAD_LOCAL_ALLOC)
>
> Regards,
>
> Andy
> --
> http://wingolog.org/
> _______________________________________________
> Gc mailing list
> Gc at linux.hpl.hp.com
> http://www.hpl.hp.com/hosted/linux/mail-archives/gc/
More information about the Gc
mailing list