[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#819402: mono: dllmap for non-linux arches



Package: src:mono
Version: 3.2.8+dfsg-10
Severity: normal
Tags: patch
User: debian-bsd@lists.debian.org
Usertags: kfreebsd

Hi,

In mono-config(5) files, dllmap can be limited to a specific platform
such as os="linux".  Currently, GNU/kFreeBSD is (and someday Hurd will
be) defined as os="unknownOS", and so ignores those mappings.

DLL mappings marked as os="linux" seem totally appropriate for
GNU/kFreeBSD, or any other Debian system (whereas those marked
os="freebsd" are typicaly not).

So in this context, "os" does not determine kernel-specific
functionality to use;  just the naming of system libraries.

It seems best to interpret os="linux" as referring to any GNU
libc-based platform.  Please consider the attached patch to do
that.

I tested on kfreebsd-amd64 where this change fixes a Mono application
(OpenRA) to work seamlessly.

Thank you.

-- System Information:
Debian Release: stretch/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: kfreebsd-amd64 (x86_64)

Kernel: kFreeBSD 10.1-0-amd64
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
From: Steven Chamberlain <steven@pyro.eu.org>
Subject: mono-config: let os=linux include other glibc platforms
Date: Mon, 28 Mar 2016 00:56:15 +0100

For the purposes of mono-config(5), let GNU libc-based platforms such
as GNU/kFreeBSD or Hurd be matched by os="linux" (rather than
"unknownOS").

dllmap entries for os="linux" are appropriate for those platforms.

--- a/mono/metadata/mono-config.c
+++ b/mono/metadata/mono-config.c
@@ -21,7 +21,7 @@
 
 #if defined(TARGET_PS3)
 #define CONFIG_OS "CellOS"
-#elif defined(__linux__)
+#elif defined(__linux__) || defined(__GLIBC__)
 #define CONFIG_OS "linux"
 #elif defined(__APPLE__)
 #define CONFIG_OS "osx"

Reply to: