summaryrefslogtreecommitdiff
path: root/lang/mono
diff options
context:
space:
mode:
authorjperkin <jperkin@pkgsrc.org>2018-07-27 20:02:40 +0000
committerjperkin <jperkin@pkgsrc.org>2018-07-27 20:02:40 +0000
commit4fead3afd5f4e2a571a48caa0ba2181508b0001f (patch)
tree6ed531c441c48985bb8d52975234d89268cede41 /lang/mono
parent2e5a0fa9655b70b1baf96d26310bf09f72e5a394 (diff)
downloadpkgsrc-4fead3afd5f4e2a571a48caa0ba2181508b0001f.tar.gz
mono: Switch to pkgsrc boehm-gc on SunOS.
The bundled one has issues with newer GCCs, and the pkgsrc one is newer and optimised, so switching is simpler than trying to retro-fit an old version. Fix --with-gc, this appears to have always been broken, and our --with-gc=none argument actually ended up as --with-gc=included, so make that now explicit. Bump PKGREVISION.
Diffstat (limited to 'lang/mono')
-rw-r--r--lang/mono/Makefile18
-rw-r--r--lang/mono/PLIST.common66
-rw-r--r--lang/mono/distinfo5
-rw-r--r--lang/mono/patches/patch-configure17
-rw-r--r--lang/mono/patches/patch-mono_metadata_boehm-gc.c30
5 files changed, 95 insertions, 41 deletions
diff --git a/lang/mono/Makefile b/lang/mono/Makefile
index dd761a9bc31..f691b388538 100644
--- a/lang/mono/Makefile
+++ b/lang/mono/Makefile
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.178 2018/07/20 03:33:51 ryoon Exp $
+# $NetBSD: Makefile,v 1.179 2018/07/27 20:02:40 jperkin Exp $
DISTNAME= mono-4.0.4.1
-PKGREVISION= 11
+PKGREVISION= 12
CATEGORIES= lang
MASTER_SITES= http://download.mono-project.com/sources/mono/
EXTRACT_SUFX= .tar.bz2
@@ -24,7 +24,7 @@ EXTRACT_USING= gtar
GNU_CONFIGURE= yes
CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFDIR:Q} --with-icu=yes
CONFIGURE_ARGS+= --with-preview=yes --with-libgdiplus=installed
-CONFIGURE_ARGS+= --disable-dtrace --with-gc=none
+CONFIGURE_ARGS+= --disable-dtrace
.include "options.mk"
@@ -134,7 +134,7 @@ SUBST_MESSAGE.fix-libx11= Fixing libX11 search path configuration
SUBST_FILES.fix-libx11= configure
SUBST_SED.fix-libx11= -e 's,@X11BASE@,${X11BASE},g'
-PLIST_VARS= monodoc
+PLIST_VARS= libgc monodoc
.include "../../mk/bsd.prefs.mk"
@@ -147,6 +147,16 @@ SUBST_SED.fix-domlib= -e 's,@DOMAINLIB@,libnsl,g'
SUBST_SED.fix-domlib= -e 's,@DOMAINLIB@,libc,g'
.endif
+# The builtin boehm-gc fails on SunOS with newer GCC, just use the pkgsrc
+# version in any case as it is optimised.
+.if ${OPSYS} == "SunOS"
+.include "../../devel/boehm-gc/buildlink3.mk"
+CONFIGURE_ARGS+= --with-gc=boehm
+.else
+CONFIGURE_ARGS+= --with-gc=included
+PLIST.libgc= yes
+.endif
+
.if ${OPSYS} == "SunOS"
CFLAGS+= -D_XOPEN_SOURCE=600
CONFIGURE_ARGS+= --with-mcs-docs=no
diff --git a/lang/mono/PLIST.common b/lang/mono/PLIST.common
index c64c0fc2768..38973369ffc 100644
--- a/lang/mono/PLIST.common
+++ b/lang/mono/PLIST.common
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST.common,v 1.26 2015/08/25 12:22:59 wiz Exp $
+@comment $NetBSD: PLIST.common,v 1.27 2018/07/27 20:02:40 jperkin Exp $
bin/al
bin/al2
bin/caspol
@@ -1105,36 +1105,36 @@ share/examples/mono/4.5/web.config
share/examples/mono/browscap.ini
share/examples/mono/config
share/examples/mono/mconfig/config.xml
-share/libgc-mono/README
-share/libgc-mono/README.DGUX386
-share/libgc-mono/README.Mac
-share/libgc-mono/README.MacOSX
-share/libgc-mono/README.OS2
-share/libgc-mono/README.amiga
-share/libgc-mono/README.arm.cross
-share/libgc-mono/README.autoconf
-share/libgc-mono/README.changes
-share/libgc-mono/README.contributors
-share/libgc-mono/README.cords
-share/libgc-mono/README.darwin
-share/libgc-mono/README.dj
-share/libgc-mono/README.environment
-share/libgc-mono/README.ews4800
-share/libgc-mono/README.hp
-share/libgc-mono/README.linux
-share/libgc-mono/README.macros
-share/libgc-mono/README.rs6000
-share/libgc-mono/README.sgi
-share/libgc-mono/README.solaris2
-share/libgc-mono/README.uts
-share/libgc-mono/README.win32
-share/libgc-mono/barrett_diagram
-share/libgc-mono/debugging.html
-share/libgc-mono/gc.man
-share/libgc-mono/gcdescr.html
-share/libgc-mono/gcinterface.html
-share/libgc-mono/leak.html
-share/libgc-mono/scale.html
-share/libgc-mono/simple_example.html
-share/libgc-mono/tree.html
+${PLIST.libgc}share/libgc-mono/README
+${PLIST.libgc}share/libgc-mono/README.DGUX386
+${PLIST.libgc}share/libgc-mono/README.Mac
+${PLIST.libgc}share/libgc-mono/README.MacOSX
+${PLIST.libgc}share/libgc-mono/README.OS2
+${PLIST.libgc}share/libgc-mono/README.amiga
+${PLIST.libgc}share/libgc-mono/README.arm.cross
+${PLIST.libgc}share/libgc-mono/README.autoconf
+${PLIST.libgc}share/libgc-mono/README.changes
+${PLIST.libgc}share/libgc-mono/README.contributors
+${PLIST.libgc}share/libgc-mono/README.cords
+${PLIST.libgc}share/libgc-mono/README.darwin
+${PLIST.libgc}share/libgc-mono/README.dj
+${PLIST.libgc}share/libgc-mono/README.environment
+${PLIST.libgc}share/libgc-mono/README.ews4800
+${PLIST.libgc}share/libgc-mono/README.hp
+${PLIST.libgc}share/libgc-mono/README.linux
+${PLIST.libgc}share/libgc-mono/README.macros
+${PLIST.libgc}share/libgc-mono/README.rs6000
+${PLIST.libgc}share/libgc-mono/README.sgi
+${PLIST.libgc}share/libgc-mono/README.solaris2
+${PLIST.libgc}share/libgc-mono/README.uts
+${PLIST.libgc}share/libgc-mono/README.win32
+${PLIST.libgc}share/libgc-mono/barrett_diagram
+${PLIST.libgc}share/libgc-mono/debugging.html
+${PLIST.libgc}share/libgc-mono/gc.man
+${PLIST.libgc}share/libgc-mono/gcdescr.html
+${PLIST.libgc}share/libgc-mono/gcinterface.html
+${PLIST.libgc}share/libgc-mono/leak.html
+${PLIST.libgc}share/libgc-mono/scale.html
+${PLIST.libgc}share/libgc-mono/simple_example.html
+${PLIST.libgc}share/libgc-mono/tree.html
share/mono-2.0/mono/cil/cil-opcodes.xml
diff --git a/lang/mono/distinfo b/lang/mono/distinfo
index 1788e76f701..b85d9e56e1b 100644
--- a/lang/mono/distinfo
+++ b/lang/mono/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.109 2017/08/22 13:43:34 jperkin Exp $
+$NetBSD: distinfo,v 1.110 2018/07/27 20:02:40 jperkin Exp $
SHA1 (mono-4.0.4.1.tar.bz2) = 12f3dbdac92e937cafba1d4e5a168c4cf2620935
RMD160 (mono-4.0.4.1.tar.bz2) = 27c2d2682786444ee52199134cb84cc59894b093
@@ -23,7 +23,7 @@ SHA1 (patch-be) = d1b603478ff8b1acdd2160efe2d88974f62ac20f
SHA1 (patch-bf) = 550c198e41ccc33dd690950754af4557df9b1d1d
SHA1 (patch-bi) = 4d2252c53facafeb8fc7f459759294da5f14dfeb
SHA1 (patch-cc) = d26c9e04f04896f0e7b2edab61cd347d76e0fcaf
-SHA1 (patch-configure) = 20af37b1f87623504d8e70dd6b749eeb3bf0118a
+SHA1 (patch-configure) = 7b80c9e4a63ba3058c06d88c8db14dd1c76f6ca3
SHA1 (patch-da) = 08c7c78aa4c6f1a1de4d34aebe05cd2ed1e7dcfd
SHA1 (patch-data_Makefile.in) = 0c54664b1a59714c6bec02547d70eaa7dee47928
SHA1 (patch-data_mono-nunit.pc.in) = 59e0a932727b842ac90c2d0b702481d62f72cab8
@@ -44,6 +44,7 @@ SHA1 (patch-libgc_misc.c) = 52c68e7b6f1b58f480286bd135591f97a3e13125
SHA1 (patch-man_mprof-report.1) = 0a80c164614cc9af5f01822005193d80f1d89946
SHA1 (patch-mcs_class_System_System.Net.NetworkInformation_IPGlobalProperties.cs) = 2c312a28f24a45ca2802dcbe032fd7007ddd60a3
SHA1 (patch-mono_dis_Makefile.in) = f000112e2712faf29104489e45feae8d6fc45169
+SHA1 (patch-mono_metadata_boehm-gc.c) = 7398638ba62e09eefead5a87661226573eb5f220
SHA1 (patch-mono_metadata_icall.c) = 191a7fccb174855026cb11dd0f6ac450bb920ec7
SHA1 (patch-mono_metadata_mono-perfcounters.c) = 8cfbfa62fe4201a20bc07645ccf6b13487a64fc3
SHA1 (patch-mono_metadata_mono-route.c) = 6eb741efca0a66fae894f7c49fa8f6393079e67f
diff --git a/lang/mono/patches/patch-configure b/lang/mono/patches/patch-configure
index 0d7d3098a15..e96fa42c6f0 100644
--- a/lang/mono/patches/patch-configure
+++ b/lang/mono/patches/patch-configure
@@ -1,6 +1,8 @@
-$NetBSD: patch-configure,v 1.3 2015/08/25 12:23:00 wiz Exp $
+$NetBSD: patch-configure,v 1.4 2018/07/27 20:02:40 jperkin Exp $
---- configure.orig 2015-08-04 07:48:54.000000000 +0000
+Fix --with-gc variables.
+
+--- configure.orig 2015-08-25 22:09:27.000000000 +0000
+++ configure
@@ -3983,7 +3983,7 @@ $as_echo "#define PLATFORM_NO_SYMLINKS 1
mono_cv_clang=no
@@ -45,6 +47,17 @@ $NetBSD: patch-configure,v 1.3 2015/08/25 12:23:00 wiz Exp $
need_link_unlink=yes
$as_echo "#define PTHREAD_POINTER_ID 1" >>confdefs.h
+@@ -20115,8 +20119,8 @@ rm -f core conftest.err conftest.$ac_obj
+
+
+ # Check whether --with-libgc was given.
+-if test "${with_libgc+set}" = set; then :
+- withval=$with_libgc; libgc=$with_gc
++if test "${with_gc+set}" = set; then :
++ withval=$with_gc; libgc=$withval
+ else
+ libgc=$libgc_default
+ fi
@@ -21999,9 +22003,7 @@ done
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Solaris XPG4 support" >&5
$as_echo_n "checking for Solaris XPG4 support... " >&6; }
diff --git a/lang/mono/patches/patch-mono_metadata_boehm-gc.c b/lang/mono/patches/patch-mono_metadata_boehm-gc.c
new file mode 100644
index 00000000000..cf284b8339b
--- /dev/null
+++ b/lang/mono/patches/patch-mono_metadata_boehm-gc.c
@@ -0,0 +1,30 @@
+$NetBSD: patch-mono_metadata_boehm-gc.c,v 1.1 2018/07/27 20:02:40 jperkin Exp $
+
+Support newer boehm-gc.
+
+--- mono/metadata/boehm-gc.c.orig 2015-08-25 22:09:13.000000000 +0000
++++ mono/metadata/boehm-gc.c
+@@ -1334,7 +1334,11 @@ mono_gc_toggleref_add (MonoObject *objec
+ void
+ mono_gc_toggleref_register_callback (MonoToggleRefStatus (*proccess_toggleref) (MonoObject *obj))
+ {
++#if GC_VERSION_MAJOR >= 7
++ GC_set_toggleref_func ((GC_ToggleRefStatus (*) (GC_PTR obj)) proccess_toggleref);
++#else
+ GC_toggleref_register_callback ((int (*) (GC_PTR obj)) proccess_toggleref);
++#endif
+ }
+
+ /* Test support code */
+@@ -1383,7 +1387,11 @@ mono_gc_register_finalizer_callbacks (Mo
+
+ fin_callbacks = *callbacks;
+
++#if GC_VERSION_MAJOR >= 7
++ GC_set_await_finalize_proc ((void (*) (GC_PTR))fin_notifier);
++#else
+ GC_set_finalizer_notify_proc ((void (*) (GC_PTR))fin_notifier);
++#endif
+ }
+
+ #endif /* no Boehm GC */