2002-03-15 Martin Baulig <martin@gnome.org>
[mono.git] / man / mcs.1
1 .TH mcs 1 "6 January 2001"
2 .SH NAME 
3 mcs \- Mono Compiler Suite.
4 .SH SYNOPSIS
5 .B mcs 
6 [option] [source-files]
7 .SH DESCRIPTION
8 mcs is the Mono C# compiler, an implementation of the ECMA-334
9 specification.  You can pass one or more options to drive the
10 compiler, and a set of source files.  Extra options or arguments can
11 be provided in a response file.  Response files are referenced by
12 prepending the @ symbol to the response file name.
13 .PP
14 C# source files must end with a ".cs" extension.  Compilation of C#
15 source code requires all the files that make up a library, module or
16 executable to be provided on the command line.  There is no support
17 for partial compilation.  To achieve the benefits of partial
18 compilation, you should compile programs into their own assemblies,
19 and later reference them with the "-r" flag.
20 .PP
21 The Mono C# compiler generates images (.exe files) that contain CIL
22 byte code that can be executed by any system that implements a Common
23 Language Infrastructure virtual machine such as the Microsoft .NET
24 runtime engine on Windows or the Mono runtime engine on Unix systems.
25 Executables are not bound to a specific CPU or operating system.
26 .PP
27 .SH OPTIONS
28 .TP
29 .I \-\-about
30 Displays information about the Mono C# compiler
31 .TP
32 .I \-\-checked
33 Sets the default compilation mode to `checked'.  This makes all
34 the math operations checked (the default is unchecked).
35 .TP
36 .I \-\-define SYMBOL
37 Defines a symbol named SYMBOL.  This can be tested in the source code
38 by the pre-processor.
39 .TP
40 .I \-\-fatal 
41 This is used for debugging the compiler.  This makes the error emission
42 generate an exception that can be caught by a debugger.
43 .TP
44 .I \-\-stacktrace
45 Generates a stack trace at the time the error is reported, useful for
46 debugging the compiler.
47 .TP
48 .I \-L PATH
49 Directs the compiler to look for libraries in the specified path.
50 Multiple paths can be provided.
51 .TP
52 .I \-\-nostdlib
53 Use this flag if you want to compile the core library.  This makes the
54 compiler load its internal types from the assembly being compiled.
55 .TP
56 .I \-\-nowarn XXX
57 Makes the compiler ignore warning XXX.
58 .TP
59 .I \-o FNAME
60 Names the output file to be generated.
61 .TP
62 .I \-\-optimize
63 Turns on optimizations in the compiler.  
64 .TP
65 .I \-\-parse
66 Used for benchmarking.  The compiler will only parse its input files.
67 .TP
68 .I \-\-probe X L
69 Probes for the code to generate an error named `X' in line `L'.  This
70 is only used by the test suite.
71 .TP
72 .I \-\-target KIND
73 Used to specify the desired target.  The possible values are: exe,
74 winexe, library and module.  
75 .TP
76 .I \-\-timestamp
77 Another debugging flag.  Used to display the times at various points
78 in the compilation process.
79 .TP
80 .I \-\-unsafe
81 Enables compilation of unsafe code.
82 .TP
83 .I \-\-werror
84 Treat warnings as errors.
85 .TP
86 .I \-\-wlevel LEVEL
87 Sets the warning level.  0 is the lowest warning level, and 4 is the
88 highest.  The default is 2.
89 .TP
90 .I \-r ASSEMBLY
91 Reference the named assembly.  Use this to use classes from the named
92 assembly in your program.
93 .TP
94 .I \-v 
95 Debugging. Turns on verbose yacc parsing.
96 .TP
97 .I \-\-
98 Use this to stop option parsing, and allow option-looking parameters
99 to be passed on the command line.
100 .PP
101 .SH NOTES
102 During compilation the MCS compiler defines the __MonoCS__ symbol,
103 this can be used by pre-processor instructions to compile Mono C#
104 compiler specific code.
105 .SH AUTHORS
106 The Mono C# Compiler was written by Miguel de Icaza and Ravi Pratap at
107 Ximian. 
108 .PP
109 .SH LICENSE
110 The Mono Compiler Suite is released under the terms of the GNU GPL.
111 Please read the accompanying `COPYING' file for details.  Alternative
112 licenses are available from Ximian.
113 .PP
114 .SH BUGS
115 To report bugs in the compiler, you can use `bug-buddy', or you can
116 file bug reports in our bug tracking system:
117 http://bugzilla.ximian.com.
118 .SH MAILING LIST
119 The Mono Mailing List is available at: mono-list-request@ximian.com
120 .SH MORE INFORMATION
121 The Mono C# compiler is developed by Ximian, Inc
122 (http://www.ximian.com) (http://www.ximian.com) and is based on the
123 ECMA C# language standard available here:
124 http://www.ecma.ch/ecma1/STAND/ecma-334.htm
125
126