Fix DLLMAP_FILES, some files have moved.
Drop heap limit patches which never helped anything. Set ac_cv_header_pthread_np_h=yes. ok robert@ (maintainer)
This commit is contained in:
parent
3dd667b407
commit
42d0cef88f
@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.103 2016/10/31 11:45:07 robert Exp $
|
||||
# $OpenBSD: Makefile,v 1.104 2016/11/07 11:52:25 ajacoutot Exp $
|
||||
|
||||
USE_WXNEEDED= Yes
|
||||
|
||||
@ -6,6 +6,7 @@ COMMENT= cross platform, open source .NET developement framework
|
||||
|
||||
V= 4.6.1
|
||||
DISTNAME= mono-${V}.5
|
||||
REVISION= 0
|
||||
|
||||
CATEGORIES= lang devel
|
||||
|
||||
@ -52,7 +53,8 @@ AUTOCONF_VERSION=2.69
|
||||
CONFIGURE_STYLE=autoconf
|
||||
CONFIGURE_ENV= LDFLAGS="-L${LOCALBASE}/lib" \
|
||||
CPPFLAGS="-I${LOCALBASE}/include" \
|
||||
ac_cv_header_execinfo_h=no
|
||||
ac_cv_header_execinfo_h=no \
|
||||
ac_cv_header_pthread_np_h=yes
|
||||
|
||||
.if ${MACHINE_ARCH} == "i386"
|
||||
CONFIGURE_ENV+= CFLAGS="-march=i586"
|
||||
@ -67,10 +69,10 @@ CONFIGURE_ARGS= --with-gc=included \
|
||||
|
||||
TEST_TARGET=check
|
||||
|
||||
DLLMAP_FILES= mcs/class/Managed.Windows.Forms/System.Windows.Forms/MimeIcon.cs \
|
||||
DLLMAP_FILES= mcs/class/System.Windows.Forms/System.Windows.Forms/MimeIcon.cs \
|
||||
mcs/tools/mono-shlib-cop/mono-shlib-cop.exe.config \
|
||||
mcs/class/System/System.IO/FAMWatcher.cs \
|
||||
mcs/class/Managed.Windows.Forms/System.Windows.Forms/X11DesktopColors.cs \
|
||||
mcs/class/System.Windows.Forms/System.Windows.Forms/X11DesktopColors.cs \
|
||||
mcs/class/Mono.Cairo/Samples/gtk/OldAndBusted.cs \
|
||||
data/config
|
||||
|
||||
|
@ -1,39 +0,0 @@
|
||||
$OpenBSD: patch-libgc_misc_c,v 1.2 2016/07/13 08:21:38 ajacoutot Exp $
|
||||
|
||||
From pkgsrc:
|
||||
Behave when address space limits are in place:
|
||||
(1) Default heap limit to 75% of available address space.
|
||||
(2) Limit GC marker threads to 4MB/8MB (32bit vs 64bit) stack space.
|
||||
As Mono tries to create 16 such threads by default, the default
|
||||
stack size on AMD64 would eat 2GB VA alone.
|
||||
|
||||
--- libgc/misc.c.orig Thu Jun 23 19:54:33 2016
|
||||
+++ libgc/misc.c Thu Jun 23 20:07:51 2016
|
||||
@@ -18,6 +18,7 @@
|
||||
#include <stdio.h>
|
||||
#include <limits.h>
|
||||
#ifndef _WIN32_WCE
|
||||
+#include <sys/resource.h>
|
||||
#include <signal.h>
|
||||
#endif
|
||||
|
||||
@@ -766,6 +767,19 @@ void GC_init_inner()
|
||||
initial_heap_sz = divHBLKSZ(initial_heap_sz);
|
||||
}
|
||||
}
|
||||
+#ifdef RLIMIT_AS
|
||||
+ {
|
||||
+ /*
|
||||
+ * If there is a VA limit for the process,
|
||||
+ * keep the heap under 75% if that limit.
|
||||
+ */
|
||||
+ struct rlimit lim;
|
||||
+ if (!getrlimit(RLIMIT_AS, &lim)) {
|
||||
+ if (lim.rlim_cur != RLIM_INFINITY && lim.rlim_cur == (word)lim.rlim_cur)
|
||||
+ GC_set_max_heap_size(lim.rlim_cur / 2 + lim.rlim_cur / 4);
|
||||
+ }
|
||||
+ }
|
||||
+#endif
|
||||
{
|
||||
char * sz_str = GETENV("GC_MAXIMUM_HEAP_SIZE");
|
||||
if (sz_str != NULL) {
|
@ -1,32 +0,0 @@
|
||||
$OpenBSD: patch-libgc_pthread_support_c,v 1.1 2016/07/13 08:21:38 ajacoutot Exp $
|
||||
|
||||
From pkgsrc:
|
||||
Behave when address space limits are in place:
|
||||
(1) Default heap limit to 75% of available address space.
|
||||
(2) Limit GC marker threads to 4MB/8MB (32bit vs 64bit) stack space.
|
||||
As Mono tries to create 16 such threads by default, the default
|
||||
stack size on AMD64 would eat 2GB VA alone.
|
||||
|
||||
--- libgc/pthread_support.c.orig Thu Jun 9 17:01:54 2016
|
||||
+++ libgc/pthread_support.c Wed Jul 13 09:18:37 2016
|
||||
@@ -595,6 +595,20 @@ static void start_mark_threads()
|
||||
}
|
||||
}
|
||||
# endif /* HPUX || GC_DGUX386_THREADS */
|
||||
+# if defined(__OpenBSD__)
|
||||
+# define MAX_STACK_SIZE (1024 * 1024 *sizeof(word))
|
||||
+ {
|
||||
+ size_t old_size;
|
||||
+ int code;
|
||||
+
|
||||
+ if (pthread_attr_getstacksize(&attr, &old_size) != 0)
|
||||
+ ABORT("pthread_attr_getstacksize failed\n");
|
||||
+ if (old_size > MAX_STACK_SIZE) {
|
||||
+ if (pthread_attr_setstacksize(&attr, MAX_STACK_SIZE) != 0)
|
||||
+ ABORT("pthread_attr_setstacksize failed\n");
|
||||
+ }
|
||||
+ }
|
||||
+# endif
|
||||
# ifdef CONDPRINT
|
||||
if (GC_print_stats) {
|
||||
GC_printf1("Starting %ld marker threads\n", GC_markers - 1);
|
Loading…
x
Reference in New Issue
Block a user