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