[smuxi/stable] Server, Frontend-GNOME: use SGen for Mono >= 4
- From: Mirco M. M. Bauer <mmmbauer src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [smuxi/stable] Server, Frontend-GNOME: use SGen for Mono >= 4
- Date: Sun, 6 Dec 2015 10:59:31 +0000 (UTC)
commit 57a0868fed497a9bdb1b9085c52dc9d981d7c0c8
Author: Mirco Bauer <meebey meebey net>
Date: Sun Dec 6 11:56:57 2015 +0100
Server, Frontend-GNOME: use SGen for Mono >= 4
This workarounds a SEGV when using Boehm with Mono >= 4, see
https://bugzilla.opensuse.org/show_bug.cgi?id=955080
src/Frontend-GNOME/smuxi-frontend-gnome.in | 16 ++++++++++------
src/Server/smuxi-server.in | 16 ++++++++++------
2 files changed, 20 insertions(+), 12 deletions(-)
---
diff --git a/src/Frontend-GNOME/smuxi-frontend-gnome.in b/src/Frontend-GNOME/smuxi-frontend-gnome.in
index 9e02ec4..0cdab2a 100644
--- a/src/Frontend-GNOME/smuxi-frontend-gnome.in
+++ b/src/Frontend-GNOME/smuxi-frontend-gnome.in
@@ -5,12 +5,16 @@
MONO_TLS_SESSION_CACHE_TIMEOUT=0
export MONO_TLS_SESSION_CACHE_TIMEOUT
-# HACK: forcibly disabled SGen, as it has a known SEGV bug related to the
-# Mono.Data.Sqlite binding that does not happen with the boehm GC, see:
-# https://smuxi.im/issues/show/1062
-MONO_ENV_OPTIONS="$(echo $MONO_ENV_OPTIONS | sed s/--gc=sgen//)"
-MONO_ENV_OPTIONS="--gc=boehm $MONO_ENV_OPTIONS"
-export MONO_ENV_OPTIONS
+# Mono >= 4 SEGVs with Boehm as GC during startup
+# see https://bugzilla.opensuse.org/show_bug.cgi?id=955080
+if ! mono -V | grep -q -F "version 4."; then
+ # HACK: forcibly disabled SGen, as it has a known SEGV bug related to the
+ # Mono.Data.Sqlite binding that does not happen with the boehm GC, see:
+ # https://smuxi.im/issues/show/1062
+ MONO_ENV_OPTIONS="$(echo $MONO_ENV_OPTIONS | sed s/--gc=sgen//)"
+ MONO_ENV_OPTIONS="--gc=boehm $MONO_ENV_OPTIONS"
+ export MONO_ENV_OPTIONS
+fi
# Smuxi uses an IPC channel for the single application instance feature and it
# also allows to pass links from commandline to an existing Smuxi instance. This
diff --git a/src/Server/smuxi-server.in b/src/Server/smuxi-server.in
index adb1f17..419e4eb 100644
--- a/src/Server/smuxi-server.in
+++ b/src/Server/smuxi-server.in
@@ -5,11 +5,15 @@
MONO_TLS_SESSION_CACHE_TIMEOUT=0
export MONO_TLS_SESSION_CACHE_TIMEOUT
-# HACK: forcibly disabled SGen, as it has a known SEGV bug related to the
-# Mono.Data.Sqlite binding that does not happen with the boehm GC, see:
-# https://smuxi.im/issues/show/1062
-MONO_ENV_OPTIONS="$(echo $MONO_ENV_OPTIONS | sed s/--gc=sgen//)"
-MONO_ENV_OPTIONS="--gc=boehm $MONO_ENV_OPTIONS"
-export MONO_ENV_OPTIONS
+# Mono >= 4 SEGVs with Boehm as GC during startup
+# see https://bugzilla.opensuse.org/show_bug.cgi?id=955080
+if ! mono -V | grep -q -F "version 4."; then
+ # HACK: forcibly disabled SGen, as it has a known SEGV bug related to the
+ # Mono.Data.Sqlite binding that does not happen with the boehm GC, see:
+ # https://smuxi.im/issues/show/1062
+ MONO_ENV_OPTIONS="$(echo $MONO_ENV_OPTIONS | sed s/--gc=sgen//)"
+ MONO_ENV_OPTIONS="--gc=boehm $MONO_ENV_OPTIONS"
+ export MONO_ENV_OPTIONS
+fi
exec mono --debug "@expanded_libdir@/@PACKAGE@/smuxi-server.exe" "$@"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]