2005-03-24 Sebastien Pouliot <sebastien@ximian.com>
[mono.git] / README
1
2 This is Mono.
3
4 1. Installation
5 2. Using Mono
6 3. Directory Roadmap
7
8 1. Compilation and Installation
9 ===============================
10
11    a. Build Requirements
12    ---------------------
13
14         To build Mono, you will need the following components:
15
16                 * pkg-config
17
18                   Available from: http://www.freedesktop.org/Software/pkgconfig
19
20                 * glib 2.4
21
22                   Available from: http://www.gtk.org/
23
24         Optional dependencies:
25
26                 * libgdiplus
27
28                   If you want to get support for System.Drawing, you will need to get
29                   Libgdiplus.
30
31     b. Building the Software
32     ------------------------
33         
34         If you obtained this package as an officially released tarball,
35         this is very simple, use configure and make:
36
37                 ./configure --prefix=/usr/local
38                 make
39                 make install
40
41         Mono supports a JIT engine on x86, SPARC, S/390, AMD64 and PowerPC systems.
42
43         If you obtained this as a snapshot, you will need an existing
44         Mono installation.  To upgrade your installation, unpack both
45         mono and mcs:
46
47                 tar xzf mcs-XXXX.tar.gz
48                 tar xzf mono-XXXX.tar.gz
49                 mv mono-XXX mono
50                 mv mcs-XXX mcs
51                 cd mono
52                 ./autogen.sh --prefix=/usr/local
53                 make
54
55     c. Building the software from SVN
56     ---------------------------------
57
58         If you are building the software from SVN, make sure that you
59         have up-to-date mcs and mono sources:
60
61                 svn co svn+ssh://USER@mono-cvs.ximian.com/source/trunk/mono
62                 svn co svn+ssh://USER@mono-cvs.ximian.com/source/trunk/mcs
63
64         Then, go into the mono directory, and configure:
65
66                 cd mono
67                 ./autogen.sh --prefix=/usr/local
68                 make
69
70         This will automatically go into the mcs/ tree and build the
71         binaries there.
72
73         This assumes that you have a working mono installation, and that
74         there's a C# compiler named 'mcs', and a corresponding IL
75         runtime called 'mono'.  You can use two make variables
76         EXTERNAL_MCS and EXTERNAL_RUNTIME to override these.  e.g., you
77         can say
78
79           make EXTERNAL_MCS=/foo/bar/mcs EXTERNAL_RUNTIME=/somewhere/else/mono
80         
81         If you don't have a working Mono installation
82         ---------------------------------------------
83
84         If you don't have a working Mono installation, an obvious choice
85         is to install the latest released packages of 'mono' for your
86         distribution and try from the beginning.
87
88         You can also try a slightly more risky approach that should work
89         almost all the time.  
90
91         This works by first getting the latest version of the 'monolite'
92         distribution, which contains just enough to run the 'mcs'
93         compiler.  You do this with:
94
95                 make get-monolite-latest
96
97         This will download and automatically gunzip and untar the
98         tarball, and place the files appropriately so that you can then
99         just run:
100
101                 make
102
103         To ensure that you're using the 'monolite' distribution, you can
104         also try passing EXTERNAL_MCS=false on the make command-line.
105
106         Testing and Installation
107          ------------------------
108
109         You can run (part of) the mono and mcs testsuites with the command:
110
111                 make check
112
113         All tests should pass.  
114
115         If you want more extensive tests, including those that test the
116         class libraries, you need to re-run 'configure' with the
117         '--enable-nunit-tests' flag, and try
118
119                 make -k check
120
121         Expect to find a few testsuite failures.  As a sanity check, you
122         can compare the failures you got with
123
124                 http://go-mono.com/tests/displayTestResults.php
125
126         You can now install mono with:
127
128                 make install
129
130         Failure to follow these steps may result in a broken installation. 
131
132 2. Using Mono
133 =============
134
135         Once you have installed the software, you can run a few programs:
136
137         * runtime engine
138
139                 mono program.exe
140           or
141                 mint program.exe
142
143         * C# compiler
144
145                 mcs program.cs
146
147         * CIL Disassembler
148
149                 monodis program.exe
150
151         See the man pages for mono(1), mint(1), monodis(1) and mcs(2)
152         for further details.
153
154 3. Directory Roadmap
155 ====================
156
157         doc/
158                 Contains the web site contents.
159
160         docs/
161                 Technical documents about the Mono runtime.
162
163         data/
164                 Configuration files installed as part of the Mono runtime.
165
166         mono/
167                 The core of the Mono Runtime.
168
169                 metadata/
170                         The object system and metadata reader.
171
172                 jit/
173                         The Just in Time Compiler.
174
175                 dis/
176                         CIL executable Disassembler
177
178                 cli/
179                         Common code for the JIT and the interpreter.
180
181                 io-layer/
182                         The I/O layer and system abstraction for 
183                         emulating the .NET IO model.
184
185                 cil/
186                         Common Intermediate Representation, XML
187                         definition of the CIL bytecodes.
188
189                 interp/
190                         Interpreter for CLI executables.
191
192                 arch/
193                         Architecture specific portions.
194
195         man/
196
197                 Manual pages for the various Mono commands and programs.
198
199         scripts/
200
201                 Scripts used to invoke Mono and the corresponding program.
202
203         runtime/
204
205                 A directory that contains the Makefiles that link the
206                 mono/ and mcs/ build systems.