2 .\" mono-config configuration page.
5 .\" Miguel de Icaza (miguel@gnu.org)
6 .\" Paolo Molaro (lupus@ximian.com)
10 mono-config \- Mono runtime file format configuration
12 The Mono runtime will load configuration data from the
13 installation prefix /etc/mono/config file, the ~/.mono/config or from
14 the file pointed by the MONO_CONFIG environment variable.
16 For each assembly loaded a config file with the name:
17 /path/to/the/assembly.exe.config is loaded as well as the
18 ~/.mono/assemblies/ASSEMBLY/ASSEMBLY.EXT.config file.
20 This file controls the behavior of the runtime.
22 The file contains an XML-like file with various sections, all of them
25 section (It actually uses GMarkup
28 This page describes the Unix-specific and Mono-specific extensions to
29 the configuration file; For complete details, see the
30 http://www.mono-project.com/Config web page.
31 .SH <dllmap> directive
32 You use the dllmap directive to map shared libraries referenced by
33 P/Invoke in your assemblies to a different shared library.
35 This is typically used to map Windows libraries to Unix library names.
38 element takes two attributes:
41 This should be the same string used in the DllImport attribute
44 This should be the name of the library where the function can be found:
45 this name should be suitable for use with the platform native shared library
46 loading routines (dlopen etc.), so you may want to check the manpages for that, too.
47 .SH <dllentry> directive
48 This directive can be used to map a specific dll/function pair to a different
49 library and also a different function name. It should appear inside a
51 element with only the dll attribute specified.
55 element takes 3 attributes:
58 This is the target library, where the function can be found.
61 This is the name of the fuction as it appears in the metadata: it is the name
62 of the P/Invoke method.
65 This is the name of the function to lookup instead of the name specified in the
67 .SH Mapping based on operating system and cpu
72 elements allow the following two attributes which make it easy to use a single
73 configuration file and support multiple operating systems and architectures with
74 different mapping requirements:
77 This is the name of the operating system for which the mapping should be applied.
78 Allowed values are: linux, osx, solaris, freebsd, openbsd, netbsd, windows, aix, hpux.
81 This is the name of the architecture for which the mapping should be applied.
82 Allowed values are: x86, x86-64, sparc, ppc, s390, s390x, arm, mips, alpha, hppa, ia64.
84 The attribute value for both attributes can be a comma-separated list of the allowed
85 values. Additionally, the first character may be a
87 to reverse the meaning. An attribute value of "!windows,osx", for example, would mean
88 that the entry is considered on all operating systems, except on Windows and OS X.
89 No spaces are allowed in any part of the value.
91 Note that later entries will override the entries defined earlier in the file.
93 The following example maps references to the `cygwin1.dll' shared
94 library to the `libc.so.6' file.
97 <dllmap dll="cygwin1.dll" target="libc.so.6"/>
101 This one maps the following C# method:
104 static extern void somefunction ();
110 , but to the same function in the library
112 when running under the Solaris and FreeBSD operating systems.
116 <dllentry dll="libdifferent.so" name="somefunction" target="differentfunction" />
117 <dllentry os="solaris,freebsd" dll="libanother.so" name="somefunction" target="differentfunction" />
123 .BR mono(1), monodis(1), mint(1)