adding jordi as contributor
[mono.git] / web / faq
1 <a href="#basics">Basics</a><br>
2 <a href="#ximian">The Ximian Role in the Mono project</a><br>
3 <a href="#gnome">Mono and GNOME</a><br>
4 <a href="#gui">Building GUI applications with Mono</a><br>
5 <a href="#msft">Mono and Microsoft</a><br>
6 <a href="#platforms">Mono platforms</a><br>
7 <a href="#compatibility">Compatibility</a></br>
8 <a href="#pnpproject">Mono and the Portable.NET Project</a><br>
9 <a href="#webservices">Web Services</a><br>
10 <a href="#asp">Mono and ASP.NET</a><br>
11 <a href="#ado">Mono and ADO.NET</a><br>
12 <a href="#monodoc">MonoDoc</a><br>
13 <a href="#devel">Development Tools and Issues</a><br>
14 <a href="#java">Mono and Java</a><br>
15 <a href="#extending">Extending Mono</a><br>
16 <a href="#portability">Portability</a><br>
17 <a href="#reuse">Reusing Existing Code</a><br>
18 <a href="#gcc">Mono and GCC</a><br>
19 <a href="#performance">Performance</a><br>
20 <a href="#licensing">Licensing</a><br>
21 <a href="#patents">Patents</a><br>
22 <a href="#etc">Miscellaneous Questions</a><br>
23 <a href="#problems">Mono Common Problems</a><br>
24
25 A <a
26 href="http://www.es.gnome.org/documentacion/articulos/mono-puf/mono-puf/">Spanish
27 translation</a> is also available
28
29 <a name="basics"></a>
30 ** Basics
31
32 Q: What is Mono exactly?
33
34 A: The Mono Project is an open development initiative sponsored by
35    Ximian that is working to develop an open source, Unix
36    version of the Microsoft .NET development platform.  Its objective
37    is to enable Unix developers to build and
38    deploy cross-platform .NET Applications.  The project will
39    implement various technologies developed by Microsoft that have now
40    been submitted to the ECMA for standardization.
41
42    The Mono project has also sparked a lot of interest in developing
43    C#-based components, libraries and frameworks.  Today Mono is not
44    limited to implement the .NET Framework, but also contains other
45    components.  Some of the components of the Mono platform were
46    developed by the Mono team, and some others we have incorporated
47    from other open source efforts, the most important ones:
48
49    <ul>
50         <li><a
51         href="http://remoting-corba.sourceforge.net/">Remoting.CORBA</a>: A
52         CORBA implementation for Mono.
53
54         <li>Ginzu: An implementation on top of Remoting for the <a
55         href="http://www.zeroc.com">ICE</a> stack
56
57         <li><a href="http://gtk-sharp.sf.net">Gtk#</a>: Bindings for
58         the popular Gtk+ GUI toolkit for Unix and Windows systems.
59         Other bindings are available: Diacanvas-Sharp and MrProject.
60
61         <li><a
62         href="http://www.icsharpcode.net/OpenSource/SharpZipLib/Default.aspx">#ZipLib</a>:
63         A library to manipulate various kinds of compressed files and
64         archives (Zip and tar).
65
66         <li>GlGen (available from the Mono CVS): Bindings for OpenGL.
67
68         <li>Mono.LDAP: LDAP access for .NET apps.
69
70         <li>Mono.Data: We ship support for Postgress, MySql, Sybase,
71         DB2, SqlLite, Tds (SQL server protocol) and Oracle databases. 
72
73         <li>Mono.Cairo: Bindings for the <a
74         href="http://www.cairographics.org">Cairo</a> rendering
75         engine (Our System.Drawing is implemented on top of this).
76
77         <li>Mono.Posix: Bindings for building POSIX applications using
78         C#. 
79
80         <li>Mono.Http: Support for creating custom, embedded HTTP
81         servers and common HTTP handlers for your applications.
82    </ul>
83
84 Q: What is the difference between Mono and the .NET Initiative?
85
86 A: The ".NET Initiative" is a somewhat nebulous company-wide effort by
87    Microsoft, one part of which is a cross-platform development
88    framework.  Mono is an implementation of the development framework,
89    but not an implementation of anything else related to the .NET
90    Initiative, such as Passport, software-as-a-service, or
91    corporate re-branding.
92
93 Q: What technologies are included in Mono?
94
95 A: Mono contains a number of components useful for building new
96    software:
97
98         <ul>
99                 * A Common Language Infrastructure (CLI) virtual
100                   machine that contains a class loader, Just-in-time
101                   compiler, and a garbage collecting runtime.
102
103                 * A class library that can work with any language
104                   which works on the CLR.  Both .NET compatible class
105                   libraries as well as Mono-provided class libraries
106                   are included.
107
108                 * A compiler for the C# language.  In the future we
109                   might work on other compilers that target the Common
110                   Language Runtime.
111         </ul>
112
113
114    Windows has compilers that target the virtual machine from <a
115    href="http://msdn.microsoft.com/net/thirdparty/default.asp#lang">a
116    number of languages:</a> Managed C++, Java Script, Eiffel,
117    Component Pascal, APL, Cobol, Perl, Python, Scheme,
118    Smalltalk, Standard ML, Haskell, Mercury and Oberon.
119
120    The CLR and the Common Type System (CTS) enables applications and
121    libraries to be written in a collection of different languages that
122    target the byte code
123
124    This means for example that if you define a class to do algebraic
125    manipulation in C#, that class can be reused from any other
126    language that supports the CLI.  You could create a class in C#,
127    subclass it in C++ and instantiate it in an Eiffel program. 
128
129    A single object system, threading system, class libraries, and
130    garbage collection system can be shared across all these languages.
131    
132 Q: Where can I find the specification for these technologies?
133
134 A: You can find the information here:
135  
136
137    C# <a href="http://www.ecma.ch/ecma1/STAND/ecma-334.htm">http://www.ecma.ch/ecma1/STAND/ecma-334.htm</a>
138
139    CLI <a href="http://www.ecma.ch/ecma1/STAND/ecma-335.htm">http://www.ecma.ch/ecma1/STAND/ecma-335.htm</a>
140
141 Q: Will you implement the .NET Framework SDK class libraries?
142
143 A: Yes, we will be implementing the APIs of the .NET Framework SDK
144    class libraries. 
145
146 Q: Will you offer an ECMA-compliant set of class libraries?
147
148 A: Eventually we will.  Our current focus is on inter-operating
149    with the Microsoft SDK, but we will also offer an ECMA compliant
150    set of libraries. 
151
152 Q: What does the name "Mono" mean?
153
154 A: Mono is the word for `monkey' in Spanish. We like monkeys.
155
156 Q: Is Mono usable?
157
158 A: The JIT engine is usable on Intel x86 machines.  An interpreter
159    can be used on other non-Intel x86 machines.  
160
161    The class libraries are mature enough to run some real applications
162    (the compiler for instance, and every day more and more applications
163    are natively developed with Mono).
164
165 Q: When will you ship it?
166
167 A: Different parts of Mono will achieve usability at different stages,
168    once we are comfortable with the compiler, we will release "Mono Core",
169    which contains everything needed to develop applications with the base
170    class libraries, this will happen soon and in the meantime you can 
171    download daily snapshots of our work. Also the full ASP.NET support is 
172    close to completion. 
173
174    Other higher level class libraries (ASP.NET, ADO.NET, WinForms) will
175    be released when they become stable. 
176
177 Q: When will Mono 1.0 ship?
178
179 A: We are planning on releasing Mono 1.0 (Mono Core) which will ship all the
180    components of Mono that are known to be stable in Q4 2003/Q1 2004.
181
182    This release will lack System.Windows.Forms  and
183    Enterprise.Services, as they will not be production ready on this timeframe.
184
185    Mono 1.2 should come in Q2 2004 and include the missing components
186    libraries that will make Mono feature-compatible with .NET 1.0
187
188 Q: What major components will you include in Mono?
189
190 A: Hopefully everything that Microsoft ships on their Framework
191    (ADO.NET, ASP.NET, WinForms), and we encourage third party developers to 
192    create reusable components that work on both Mono and Windows.
193
194 Q: How can I contribute?
195
196 A: Check the <a href="contributing.html">contributing</a> section. 
197
198 Q: Aren't you just copying someone else's work?
199
200 A: We are interested in providing the best tools for programmers to
201    develop applications for Free Operating Systems.  We also want to help
202    provide the interoperability that will allow those systems to fit in
203    with other standards.
204
205    For more background, read the <a href="http://www.go-mono.com/rationale.html">Mono
206    Project white paper</a>.
207    the project.
208
209 Q: Miguel said once that Mono was being implemented in COBOL. Is that true?.
210
211 A: No. It was a joke.
212
213
214 <a name="ximian"></a> 
215
216 ** The Ximian Role in the Mono Project
217
218 Q: Why is Ximian working on .NET?
219
220 A: Ximian is interested in providing the best tools for programmers to
221    develop applications for Free Operating Systems.  
222
223    For more information, read the project <a
224    href="rationale.html">rationale</a> page.
225
226 Q: Will Ximian be able to take on a project of this size?  
227
228 A: Of course not. Ximian a supporter of the Mono project, but the only way
229    to implement something of this size is for the entire free software
230    community to get involved. Visit the <a href="contributing.html">contributing</a> 
231    page if you'd like to help out.
232
233 Q: What pieces will Ximian be working on?
234
235 A: We will devote most of our resources to work on the pieces which are
236    on the critical path to release a development and execution
237    environment. Once the project is at a stage where it is useful in
238    the real world, it will achieve a critical mass of developers to
239    improve it further.
240
241 Q: Will Ximian offer Mono commercially?
242
243 A: When Mono is ready to be shipped Ximian will offer a commercial
244    support and services for Mono. 
245
246 Q: Does Ximian provide consulting services around Mono?
247
248 A: Yes, Ximian does provide consulting services around Mono to
249    make it suitable to your needs.  Porting the runtime engine,
250    customizing it, working on specific classes or tuning the code
251    for your particular needs. 
252
253 Q: Will you wait until Mono is finished?
254
255 A: Mono will ship on various stages as they mature.  Some people
256    require only a subset of the technologies, those will ship first.
257
258    More advanced features will take more time to develop.  A support
259    time line will be available in June 2002.
260
261 <a name="gnome"></a> 
262 ** Mono and GNOME
263
264 Q: How is Mono related to GNOME?
265
266 A: In a number of ways.  This project was born out of the need of
267    providing improved tools for the GNOME community, and will use
268    existing components that have been developed for GNOME when they
269    are available.  For example, we plan to use Gtk+ and Libart to
270    implement Winforms and the Drawing2D API and are considering
271    GObject support.
272
273 Q: Has the GNOME Foundation or the GNOME team adopted Mono?
274
275 A: Mono is too new to be adopted by those groups. We hope that the
276    tools that we will provide will be adopted by free software
277    programmers including the GNOME Foundation members and the GNOME
278    project generally.
279
280 Q: Should GNOME programmers switch over to Mono now?
281
282 A: It is still far to early for discussions of "switching over."  No
283    pieces of Mono will be ready within the next six months, and a
284    complete implementation is roughly one year away.
285
286    We encourage GNOME developers to continue using the existing tools,
287    libraries and components.  Improvements made to GNOME will have an
288    impact on Mono, as they would be the "back-end" for various classes.
289
290 Q: Will Mono include compatibility with Bonobo components? What is the
291    relationship between Mono and Bonobo?
292
293 A: Yes, we will provide a set of classes for implementing and using
294    Bonobo components from within Mono.  Mono should allow you to write
295    Bonobo components more easily, just like .NET on Windows allows you
296    to export .NET components to COM.
297
298 Q: Does Mono depend on GNOME?
299
300 A: No, Mono does not depend on GNOME.  We use a few packages produced by
301    the GNOME team like the `glib' library.  
302
303 Q: But will I be able to build GNOME applications?
304
305 A: Yes, we will enable people to write GNOME applications using Mono.
306
307 Q: Do you have C# bindings for GNOME?.
308
309 A: Yes, we currently bind libgnome, libgnomecanvas, and libgnomeui --
310    although I dare say I have no idea how functional the bindings are
311    outside of what I tested in the sample app. I imagine other libraries 
312    under the GNOME framework will be added on an as-needed (and as-requested) 
313    basis...although a truly good bonobo binding will have to wait on the CORBA 
314    remoting support which has been started recently.
315
316 <a name="gui"></a>
317 ** GUI applications
318
319 Q: Will Mono enable GUI applications to be authored?
320
321 A: Yes, you will be able to build GUI applications.  Indeed, that is our
322    main focus.  We will provide both the Windows.Forms API and the Gtk# API.
323
324 Q: What is the difference between Gtk# and System.Windows.Forms?
325
326 A: Gtk# is a set of bindings for the Gtk+ toolkit for C# (and other
327    CIL-enabled languages).  System.Windows.Forms is an API defined
328    by Microsoft to build GUI applications.
329
330 Q: Why not implement System.Windows.Forms on top of Gtk# or Qt#?
331
332 A: Compatibility.
333
334    Although it is possible to run simple Windows.Forms applications
335    with the Gtk#-based backend of Windows.Forms, it is very unlikely
336    that the implementation will ever implement everything needed for
337    full compatibility with Windows.Forms.
338
339    The reason is that Windows.Forms is not a complete toolkit, and to
340    work around this problem some of the underlying Win32 foundation is
341    exposed to the programmer in the form of exposing the Windows
342    message handler (WndProc).  Any control can override this method.
343    Also developers often P/Invoke into Win32 to get to functionality
344    that was not wrapped. 
345
346    To achieve full compatibility, we would have to emulate this, and
347    it would take too long.
348
349    For more details see the <a href="winforms.html">winforms page</a>
350
351 Q: Wine applications do not look like native applications, what are
352    you going to do about this?  
353
354 A: We have already a few patches into our version of Windows.Forms
355    that makes Wine use the colors and font settings from your desktop,
356    improving the integration a lot.   In the future, we will continue
357    to improve this interoperability scenario.
358
359 Q: Will I be able to run my smart clients on systems powered by Mono?
360
361 A: As long as your applications are 100% .NET and do not make use
362    of P/Invoke to call Win32 functions, your smart client applications
363    will run on Mono platforms.
364
365 Q: Where can I learn more about Gtk#?
366
367 A: The following <a href="http://gtk-sharp.sourceforge.net>link</a> sends you to the page of the project.
368
369 Q: What can I do with Gtk#?. 
370
371 A: Gtk# is becoming very usable and you can create applications and
372    applets like those you see in a GNOME desktop environment. It's 
373    easy to install so it's worth a try. 
374
375 Q: How can I compile my HelloWorld.cs which uses Gtk#?.
376
377 A: Try: mcs --unsafe -o HelloWorld.exe -r glib-sharp -r pango-sharp -r
378         atk-sharp -r gdk-sharp -r gtk-sharp -r gdk-imaging-sharp
379         HelloWorld.cs
380
381 Q: Is there any way how to connect DataAdapter to some GTK# controls?
382
383 A: There is a sample file called `DbClient' in gtk-sharp/samples that you
384    might to look at.  It is a sample program in Gtk# that adds/updates/deletes 
385    information on a Postgress database. When we have the new table/tree widgets, 
386    I am sure someone would write an adapter for System.Data (in Gtk2 the 
387    tree/list widgets are written using a view/model, so you only need to write 
388    a model that maps to the database). You can have a look at 
389    gtk-sharp/sample/DbClient, where there is a GTK# application that uses 
390    System.Data. It does not use DataAdapter, but DataReader though.
391
392 Q: Do you have an estimate for when Windows.Forms will be released?
393
394 A: We do not know, volunteers are working on this, but there is no set
395    date yet.  The current approach is using the Wine Library to implement
396    it.
397
398 Q: Do you have a comparission chart about the various toolkit
399    offerings?
400
401 A: A document explaining this is available at: <a
402    href="http://primates.ximian.com/~miguel/toolkits.html">http://primates.ximian.com/~miguel/toolkits.html</a>.
403
404 <a name="msft"></a>
405 ** Mono and Microsoft
406
407 Q: Is Microsoft helping Ximian with this project?
408
409 A: There is no high level communication between Ximian and Microsoft
410    at this point, but engineers who work on .NET or the ECMA groups
411    have been very friendly, and very nice to answer our questions, or
412    clarify part of the specification for us. 
413
414    Microsoft is interested in other implementations of .NET and are
415    willing to help make the ECMA spec more accurate for this purpose.
416
417    Ximian was also invited to participate in the ECMA committee
418    meetings for C# and the CLI.
419
420 Q: Is Microsoft or Corel paying Ximian to do this?
421
422 A: No.
423
424 Q: Do you fear that Microsoft will change the spec and render Mono
425    useless?
426
427 A: No.  Microsoft proved with the CLI and the C# language that it was
428    possible to create a powerful foundation for many languages to
429    inter-operate.  We will always have that.  
430
431    Even if changes happened in the platform which were undocumented,
432    the existing platform would a value on its own.
433
434 Q: Are you writing Mono from the ECMA specs?
435
436 A: Yes, we are writing them from the ECMA specs and the published
437    materials in print about .NET.
438
439 Q: If my applications use Mono, will I have to pay a service fee?
440
441 A: No.  Mono is not related to Microsoft's initiative of
442    software-as-a-service.
443
444 Q: Is the Mono Project is related to the Microsoft Hailstorm effort?  Is
445    Ximian endorsing Hailstorm?  
446
447 A: No.  The Mono Project is focused on providing a compatible set of
448    tools for the Microsoft .NET development platform.  It does not
449    address, require, or otherwise endorse the MS Passport-based
450    Hailstorm single sign-on system that is part of Windows XP and
451    other services.
452
453 Q: Will Mono or .NET applications depend on Microsoft Passport?
454
455 A: No. MS Passport is unrelated to running .NET compatible applications
456    produced with the Mono tools.  The only thing you will need is a
457    just-in-time compiler (JIT).
458
459 Q: If Microsoft will release a port of their .NET platform under the
460    `Shared Source' license, why should I bother with anything else?
461
462 A: The Shared Source implementation will be expensive and its uses
463    will be tightly restricted, especially for commercial use. We are
464    working towards an implementation that will grant a number of
465    important rights to recipients: use for any purpose,
466    redistribution, modification, and redistribution of modifications.
467
468    This is what we call <a
469    href="http://www.gnu.org/philosophy/free-sw.html">Free Software</a>
470
471 Q: Is Mono a free implementation of Passport?
472
473 A: No. Mono is just a runtime, a compiler and a set of class
474    libraries.
475
476 Q: Will the System.Web.Security.PassportIdentity class mean
477    that my software will depend on Passport?
478    
479 A: No.  Applications may use that API to contact a Passport site, but
480    are not required to do so.
481
482    As long as your application does not use Passport, you will not
483    need Passport.  
484
485 Q: Will Mono running on Linux make Passport available for Linux?
486
487 A: No.  However, the Passport toolkit for Linux-based web servers is
488    available from Microsoft.
489
490 Q: Will Mono allow me to run Microsoft Office on Linux?
491
492 A: No, it will not.  Microsoft Office is a Windows application.  To
493    learn more about running Windows applications on Intel Unix systems
494    refer to <a href="http://www.winehq.com">the Wine Project</a>.
495
496 Q: Can mono run the WebMatrix?
497
498 A: No. That requires System.Windows.Forms support which is not
499    currently implemented.
500
501 Q: Does mono have something like Passport? 
502    Will mono have a server side Passport/Similar framework for XSP as well as client classes?
503
504 A: Not yet, but the client side API for authentication is not the problem. 
505    We will likely have a lot of other authentication APIs, like the Liberty
506    Alliance APIs. The problem is people on the web provider end that might use 
507    this for authentication.
508
509 <a name="platforms"></a>
510 ** Mono Platforms 
511
512 Q: What operating systems does Mono run on?
513
514 A: Mono is known to run on Linux, Unix and Windows systems.   
515
516 Q: What architectures does Mono support?
517
518 A: Mono today ships with a Just-in-Time compiler for x86-based
519    systems.  It is tested regularly on Linux, FreeBSD and Windows
520    (with the XP/NT core).
521
522    There is also an interpreter, which is slower that runs on the
523    s390, SPARC and PowerPC architectures.
524
525 Q: Can Mono run on Windows 9x, or ME editions?
526
527 A: Mono requires Unicode versions of Win32 APIs to run,
528    and only a handful of *W functions is supported under Win9x.
529
530    There is Microsoft Layer for Unicode that provides implementation
531    of these APIs on 9x systems.
532
533    Unfortunately it uses linker trick for delayed load that is not
534    supported by ld, so some sort of adapter is necessary.
535    
536    You will need MSLU and one of the following libs to link Mono to
537    unicows.dll <a
538    href="http://mono.eurosoft.od.ua/files/unimono.zip">http://mono.eurosoft.od.ua/files/unimono.zip</a>
539    or alternatively search the net for "libunicows".
540
541    No changes to Mono source code required, the only thing is to make
542    sure that linker will resolve imports to adapter library instead of
543    Win32 libs. This is achieved by inserting -lunimono before
544    -lkerner32/user32 in the linker's specs file.
545
546 Q: Why support Windows, when you can run the real thing?
547
548 A: There are various reasons:
549
550    <ul>
551       <li> About half the contributors to Mono are Windows developers.
552            They have many different for contributing to the effort, and
553            we find it very important to let those developers run the runtime on Windows without forcing
554            them to use a new operating system. 
555           
556       <li> Supporting Windows helps us identify the portable portions
557            of Mono from the non-portable versions of it, helping Mono
558            become more portable in the future.
559
560       <li> Mono does not heavily modify the windows registry, update system DLLs,
561            install DLLs to the Windows/System32 path.  Another words, I knew Mono would
562            not cause any legacy enterprise applications to stop working - and it
563            hasn't.  However, our CIO er is againt it because of the changes that would
564            be made to Windows 2000, such as, affecting security.
565    </ul>
566
567 <a name="compatibility"></a>
568 ** Compatibility
569
570 Q: Can Mono run applications developed with the Microsoft.NET framework?
571
572 A: Yes, Mono can run applications developed with the Microsoft .NET Framework
573    on Unix.  There are a few caveats to keep in mind: Mono has not
574    been completed yet, so a few API calls might be missing; And in
575    some cases the Mono behavior *might* be incorrect.
576
577 Q: Will missing API entry points be implemented?
578
579 A: Yes, the goal of Mono is to implement precisely the .NET Framework
580    API (as well as compile-time selectable subsets, for those
581    interested in a lighter version of Mono).
582
583 Q: If the behavior of an API call is different, will you fix it?
584
585 A: Yes, we will.  But we will need your assistance for this.  If you find a bug
586    in the Mono implementation, please fill a bug report in <a
587    href="http://bugzilla.ximian.com">http://bugzilla.ximian.com</a>.
588    Do not assume we know about the problem, we might not, and using the bug tracking
589    system helps us organize the development process.
590
591 Q: Can I develop my applications on Windows, and deploy on a supported
592    Mono platform (like Linux)?
593
594 A: Yes, you can.  
595
596    As of today, Mono is not 100% finished, so it is sometimes useful
597    to compile the code with Mono, to find out if your application
598    depends on unimplemented functionality. 
599
600 Q: Will applications run out the box with Mono?
601
602 A: Sometimes they will.  But sometimes a .NET application might invoke
603    Win32 API calls, or assume certain patterns that are not correct
604    for cross-platform applications.
605
606 Q: What is a 100% .NET application?
607
608 A: A `100% .NET application' is one that only uses the APIs defined
609    under the System namespace and does not use P/Invoke.  These
610    applications would in theory run unmodified on Windows, Linux,
611    HP-UX, Solaris, MacOS X and others. 
612
613    Note that this requirement also holds for all assemblies used by the
614    application.  If one of them is Windows-specific, then the entire program
615    is not a 100% .NET application.
616
617    Furthermore, a 100% .NET application must not contain non-standard data
618    streams in the assembly.  For example, Visual Studio .NET will insert a 
619    <tt>#-</tt> stream into assemblies built under the "Debug" target.  
620    This stream contains debugging information for use by Visual Studio .NET; 
621    however, this stream can not be interpreted by Mono (unless you're willing 
622    to donate support).
623
624    Thus, it is recommended that all Visual Studio .NET-compiled code be
625    compiled under the Release target before it is executed under Mono.
626
627 Q: Can I execute my Visual Studio .NET program (Visual Basic .NET, Visual C#,
628    Managed Extensions for C++, etc.) under Mono?
629
630 A: Yes, with some reservations.
631
632    The .NET program must either be a 100% .NET application, or (somehow) have
633    all dependent assemblies available on all desired platforms.  (How to do so
634    is outside the bounds of this FAQ.)
635
636    Mono must also have an implementation for the .NET assemblies used.  For
637    example the System.EnterpriseServices namespace is part of .NET, but it
638    has not been implemented in Mono.  Thus, any applications using this
639    namespace will not run under Mono.
640
641    With regards to languages, C# applications tend to be most portable.
642
643    Visual Basic .NET applications are portable, but Mono's 
644    Microsoft.VisualBasic.dll implementation is incomplete.  It is recommended 
645    to either avoid using this assembly in your own code, only use the 
646    portions that Mono has implemented, or to help implement the missing
647    features.  Additionally, you can set 'Option Strict On', which
648    eliminates the implicit calls to the unimplemented
649    Microsoft.VisualBasic.CompilerServices.ObjectType class.  
650    (Thanks to Jörg Rosenkranz.)
651
652    Managed Extensions for C++ is least likely to operate under Mono.  Mono
653    does not support mixed mode assemblies (that is, assemblies containing both
654    managed and unmanaged code, which Managed C++ can produce).  You need a
655    fully-managed assembly to run under Mono, and getting the Visual C++ .NET
656    compiler to generate such an executable can be difficult.  You need to use
657    only the .NET-framework assemblies, not the C libraries (you can't use
658    <b>printf</b>(3) for example.), and you need to use
659    the linker options <tt>/nodefaultlib /entry:main mscoree.lib</tt> in
660    addition to the <tt>/clr</tt> compiler flag.  You can still use certain
661    compiler intrinsic functions (such as <b>memcpy</b>(3)) and the STL.
662    You should also see <a 
663    href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vcmex/html/vcgrfconvertingmanagedextensionsforcprojectsfrommixed-modetopureil.asp"
664    >Converting Managed Extensions for C++ Projects from Mixed Mode to Pure
665    Intermediate Language</a> at MSDN.
666    Finally, you can use PEVERIFY.EXE from the .NET SDK to determine if the 
667    assembly is fully managed.
668
669    Thanks to Serge Chaban for the linker flags to use.
670
671 <a name="pnpproject"></a>
672 ** Mono and Portable.NET
673
674 Q: What are the differences between Mono and Portable.NET?
675
676 A: Most of Mono is being written using C#, with only
677    a few parts written in C (The JIT engine, the runtime, the
678    interfaces to the garbage collection system).  
679
680    It is easier to describe what is unique about Mono:
681    <ul>
682      <li> An advanced native-code compilation engine: Both
683           just-in-time compilation (JIT) and pre-compilation of CIL
684           bytecodes into native code are supported.
685
686      <li> A foundation for code optimization: The new code generator in
687           Mono builds on the experience of our first JIT engine, and enables
688           us to implement various advanced compiler optimization
689           tricks.  With an SSA-framework, plenty of new optimizations are possible. 
690
691           The current list of optimizations are: Peephole postpass,
692           Branch optimizations, Inline method calls, Constant folding, Constant
693           propagation, Copy propagation, Dead code elimination, Linear scan
694           global reg allocation, Conditional moves, Emit per-domain code,
695           Instruction scheduling, Intrinsic method implementations, Tail
696           recursion and tail calls, Loop related optimizations, Fast x86 FP
697           compares, Leaf procedures optimizations
698
699      <li> A self-hosting C# compiler written in C#, which is clean, easy
700           to maintain.
701
702      <li> Focus on the .NET Framework: we are tracking down the .NET
703           Framework API definition, as we believe it is the API people
704           will be most familiar with.
705
706      <li> A multi-platform runtime engine: both a JIT engine and an
707           interpreter exist.  The JIT engine runs currently on x86
708           systems, while the interpreter works on SPARC, StrongARM,
709           s390 and PowerPC systems.  
710
711           Our new compilation engine is being ported to the PowerPC.
712
713      <li> Supports Linux, BSD, Windows and Solaris at this point.
714
715      <li> The JIT engine is written using a portable instruction
716           selector which not only generates good code but
717           is also the foundation to re-target the JIT engine to other
718           systems.  
719
720      <li> Full support for remoting in the runtime.
721
722      <li> The C# compiler, the JIT engine and the class libraries are
723           mature enough that the whole system has been self-hosting
724           since April 2002.  This means that we develop Mono
725           completely with itself at this point.
726
727           By forcing ourselves to use our own code to develop our
728           tools, we bug fix problems rapidly, and the system is
729           overall more robust and tested than if we did not.
730
731      <li> We have a great community of developers, without which Mono
732           would not be possible.
733    </ul>
734
735    In general, Mono is more mature and complete since it has been used
736    to develop itself, which is a big motivator for stability and
737    correctness, while Portable.NET remains pretty much an untested
738    platform.
739
740 Q: I hear Mono keeps changing the P/Invoke API, why?
741
742 A: We are just fixing our implementation to be compatible with the
743    Microsoft implementation.  In other words, the Mono P/Invoke API is
744    more complete when compared to the Portable.NET version, hence
745    various pieces of software that depend on this extended
746    functionality fail to work properly with Portable.NET.
747
748 <a name="webservices"></a>
749 ** Web Services
750
751 Q: How is Mono related to Web Services?
752
753 A: Mono is only related to Web Services in that it will implement the
754    same set of classes that have been authored in the .NET Framework
755    to simplify and streamline the process of building Web Services.
756
757    But most importantly, Mono is an Open Source implementation of the
758    .NET Framework.
759
760 Q: Can I author Web Services with Mono?
761
762 A: You will be able to write Web Services on .NET that run on Mono and
763    vice-versa. 
764
765 Q: If Mono implements the SDK classes, will I be able to write and
766    execute .NET Web Services with it?
767    
768 A: Yes.  When the project is finished, you will be able to use the
769    same technologies that are available through the .NET Framework SDK
770    on Windows to write Web Services.
771
772 Q: What about Soup?  Can I use Soup without Mono?
773
774 A: Soup is a library for GNOME applications to create SOAP servers and
775    SOAP clients, and can be used without Mono.  You can browse the
776    source code for soup using <a
777    href="http://cvs.gnome.org/bonsai">GNOME's Bonsai</a>.
778
779 Q: Can I use CORBA?
780
781 A: Yes. The CLI contains enough information about a class that
782    exposing it to other RPC systems (like CORBA) is really simple, and
783    does not even require support from an object.  
784
785    <a href="http://remoting-corba.sourceforge.net/">Remoting.CORBA</a> is
786    a CORBA implementation that is gaining momentum.
787
788    Building an implementation of the Bonobo interfaces once this is ready
789    should be relatively simple. 
790
791 Q: Can I serialize my objects to other things other than XML?
792
793 A: Yes, although the serializing tools have not yet been planned, and
794    you would probably have to implement them yourself.
795
796 Q: Will Mono use ORBit?
797
798 A: There are a few advantages in using ORBit, like reusing existing code
799    and leveraging all the work done on it.  Michael Meeks has posted
800    a few <a href="http://lists.ximian.com/archives/public/mono-list/2002-September/008592.html">reasons</a>,
801    as well as some <a href="http://lists.ximian.com/archives/public/mono-list/2002-September/008657.html">ideas</a>
802    that could be used to reuse ORBit.
803
804    Most users are likely to choose a native .NET solution, like <a href="http://cvs.gnome.org/bonsai">Remoting.CORBA</a>
805
806
807 <a name="monodoc"></a>
808 ** MonoDoc
809
810 Q: What is MonoDoc?
811
812 A: MonoDoc is a graphical documentation browser for the Mono class
813    libraries. Currently, monodoc consists of a Gtk# application and is
814    in heavy development.
815
816 <a name="devel"></a>
817 ** Development Tools and Issues
818
819 Q: I am having trouble compiling a new version of Mono from CVS, it 
820    complains about my runtime being out of sync.
821
822 A: To upgrade your class libraries and compiler, see the 
823    INSTALL.txt in the MCS directory.
824
825    The single biggest source of confusion seems to be the "Your
826    runtime is out of sync" messages.  Realize that this is *normal*
827    while BUILDING.  Think about it: you're building a new class
828    library with the old runtime.  If the new class library references
829    a function that the old runtime knows nothing about, the runtime
830    system issues this warning.
831
832    Basically what needs to happen is for a new mono runtime to be
833    compiled, then the corlib class library be compiled, and once this
834    is done, install the new runtime, followed by corlib.
835
836    Once this is done, you can continue building your entire
837    environment.
838
839    For instance you just need to:
840    1.- Upgrade your Mono runtime (you might better do it with the 
841    mono-build.sh script available in the <a 
842    href="http://www.go-mono.com">download</a> page.
843    2.- Get the latest mono-lite tarball from the daily snapshots 
844    <a href="http://www.go-mono.com/daily/">page</a>, unzip and 
845    untar and copy all the dll files to your install path lib 
846    directory (typically pointed by the $MONO_PATH variable).
847    Copy all the exe files to the install path bin directory.
848    3.- Then checkout or update your mcs CVS copy. Then follow 
849    the steps described in mcs/INSTALL.txt.
850
851 Q: Will it be possible to use the CLI features without using byte codes
852    or the JIT?
853
854 A: Yes. The CLI engine will be made available as a shared library.
855    The garbage collection engine, the threading abstraction, the
856    object system, the dynamic type code system and the JIT will be
857    available for C developers to integrate with their applications if
858    they wish to do so. 
859
860 Q: Will you have new development tools?
861
862 A: With any luck, Free Software enthusiasts will contribute tools to
863    improve the developer environment.  These tools could be developed
864    initially using the Microsoft implementation of the CLI and then
865    executed later with Mono.
866
867    We are recommending people to use and contribute to existing
868    projects like SharpDevelop, Anjuta and Eclipse.
869
870 Q: What kind of rules make the Common Intermediate Language useful for
871    JITers?
872
873 A: The main rule is that the stack in the CLI is not a general purpose
874    stack.   You are not allowed to use it for other purposes than
875    computing values and passing arguments to functions or return
876    values.  
877
878    At any given call or return instruction, the types on the stack
879    have to be the same independently of the flow of execution of your
880    code. 
881
882 Q: Is it true that the CIL is ideal for JITing and not efficient for
883    interpreters?
884
885 A: The CIL is better suited to be JITed than JVM byte codes, but you
886    can interpret them as trivially as you can interpret JVM byte
887    codes. 
888
889 Q: Isn't it a little bit confusing to have the name of "XSP" (the same 
890    as in the Apache Project) for the ASP.NET support in Mono?.
891
892 A: In Mono, xsp is just the name of the C# code generator for ASP.NET 
893    pages. In the Apache Project, it is a term for the "eXtensible Server 
894    Pages" technology so as they are very different things, they don't 
895    conflict.
896
897 Q: Is there any plan to develop an aspx server for Mono?.
898
899 A: The XSP reference server is available and you can also use mod_mono
900    with Apache.
901
902 Q: Is there any way I can develop the class libraries using Linux yet?
903
904 A: Yes.  Mono has been self hosting since May 2002.
905
906 Q: Is there any way I can install a known working copy of mono in /usr, 
907    and an experimental copy somewhere else, and have both copies use 
908    their own libraries? (I'm still not very good at library paths in 
909    Linux)
910
911 A: Yes. Just use two installation prefixes.
912
913 Q: How should I write tests or a tests suite?
914
915 A: If you do a test suite for C#, you might want to keep it 
916    independent of the Mono C# compiler, so that other compiler 
917    implementations can later use it.  
918
919 Q: Would it be too terrible to have another corlib signed as mscorlib? 
920
921 A: We rename corlib to mscorlib also when saving the PE files, in fact, 
922    the runtime can execute program created by mono just fine.  
923
924 Q: Is it possible to build a C# file to some sort of intermediate format which 
925    can linked into a final module, like the traditional .c -> .o -> .so path? 
926    
927 A: You can use: 
928
929         mcs /target:library file1.cs, mcs /target:library file2.cs, 
930         mcs /target:exe file1.dll file2.dll /out:mybin.exe
931
932 Q: Is there any plans for implementing remoting in the near future?
933
934 A: The remoting infrastructure is in place.  We have implementations
935    of the TcpChannel, HttpChannel and the Soap and Binary Formatters.
936    They are compatible with .NET.
937
938    However, some classes from the library may have a different binary
939    representation, because they may have a different internal data
940    structure, so for example you won't be able to exchange a Hastable
941    object between Mono and MS.NET. It should not be a problem if you
942    are using primitive types, arrays or your own classes. In any case,
943    could you post a test case?
944
945
946 Q: My C code uses the __stdcall which is not availble on Linux, how can I
947    make the code portable Windows/Unix across platforms?
948
949 A: Replace the __stdcall attribute with the STDCALL macro, and include this
950    in your C code for newer gcc versions:
951
952         #ifndef STDCALL
953         #define STDCALL __attribute__((stdcall))
954         #endif
955
956 Q: I want to be able to execute Mono binaries, without having to use the "mono"
957    command.  How can I do this?
958
959 A: From Carlos Perelló:
960
961    <i>I think that the best solution is the binfmt feature with the
962    wrapper that exists with Debian packages at:
963
964    <a href="http://www.debianplanet.org/mono/dists/unstable/main/source/admin/">http://www.debianplanet.org/mono/dists/unstable/main/source/admin/</a>
965
966    If you want use it with Big endian machines, you should apply a patch
967    (<a href="http://carlos.pemas.net/debian/mono/binfmt-detector-cli.c.diff">http://carlos.pemas.net/debian/mono/binfmt-detector-cli.c.diff</a>)
968
969    It works really good and lets you use wine also, it reads the .exe file
970    headers and check if it's a .net executable.
971
972    This way you just execute: ./my-cool-mono-application.exe and it works
973    without the need of any wrapper.</i>
974
975 Q: I see funny characters when I run programs, what is the problem?
976
977 A: (From Peter Williams and Gonzalo Paniagua):
978
979    This is Red Hat 9 (probably) using UTF8 on its console; the bytes are
980    the UTF8 endianness markers.   You can do:
981  
982          LC_ALL=C mono myexe.exe
983
984    And they wont show up.
985
986    Alternatively, you can do:
987
988         $ echo -e "\033%G"
989
990    to enable UTF-8 on the console.
991
992 <a name="asp">
993 ** Mono and ASP.NET
994
995 Q: Does Mono support ASP.NET?
996
997 A: Yes. 
998
999    Mono supports ASP.NET, we have shown an unmodified IBuySpy
1000    installation running on Mono as well as various other programs.  You can
1001    try it yourself downloading the XSP server. 
1002
1003 Q: Do I need install cygwin to work on ASP.NET in mono or Linux is enough since 
1004    it is self host right now.
1005
1006 A: Linux is enough.
1007
1008 Q: How can I run ASP.NET-based applications with Mono?
1009
1010 A: You need the Mono runtime and a hosting web server.  Currently we distribute a 
1011    small web server called `xsp' which is used to debug applications, or you can choose
1012    to use Daniel's Apache 2 module.
1013
1014 Q: Any plan to make ASP.NET in mono works with Apache in Linux?.
1015
1016 A: Daniel has authored an Apache2 Module for Mono that hosts the ASP.NET runtime
1017    and is available here: <a
1018    href="http://apacheworld.org/modmono/">http://apacheworld.org/modmono/</a>
1019
1020 Q: Will you support Apache 1?
1021
1022 A: Modules developed for Apache 2 are not compatible with Apache 1.3
1023    Daniel plans to support Apache 1.3 in the future but the current focus is on
1024    Apache 2, because of the better support for threading and Windows.
1025
1026 Q: Can I run Apache 1 and Apache 2 on the same machine?
1027
1028    You can always keep a copy of Apache 2 running in parallel with your Apache
1029    1.3 (either different port or using a reverse proxy).
1030
1031    You can also bind the two servers to different IP addresses on the
1032    same physical machine.
1033
1034 <a name="ado">
1035 ** Mono and ADO.NET
1036
1037 Q: What is the status of ADO.NET support?. Could I start migrating 
1038    applications from MS.NET to Mono?.
1039
1040 A: You could start right now using the ADO.NET support in mono, of course,
1041    if you want to help filling the missing gaps while you develop your app
1042    :-) Well, what I mean is that we're not that far to having full ADO.NET
1043    support in Mono, and we've got a lot of working things, so if we could
1044    get more help, we'd finish it really soon :-)
1045
1046 Q: In developing the data architecture for the application are there and
1047    objects I should stay away from in order to insure the smoothest possible
1048    transition (minimum code rewrite) to Mono's ADO.NET implementation?  (For
1049    example, strongly typed datasets versus untyped datasets, etc...)
1050
1051 A: We are implementing all the classes in Microsoft .NET's System.Data, so
1052    you can be sure that things will work the same in Mono as with the Microsoft
1053    implementation. 
1054
1055 Q: Does Mono can to connect to Sybase by using Mono.Data.*?
1056
1057 A: Yes. use Mono.Data.SybaseClient. First of all you have to create a
1058    SybaseConnection, and then, from it, use it as any other
1059    IDbConnection-based class.
1060
1061 <a name="java">
1062 ** Mono and Java
1063    
1064 Q: Why don't you use Java?  After all, there are many languages that
1065    target the Java VM.
1066
1067 A: You can get very good tools for doing Java development on free
1068    systems right now.  <a href="http://www.redhat.com">Red Hat</a> has
1069    contributed a <a href="http://gcc.gnu.org">GCC</a> <a
1070    href="http://gcc.gnu.org/java">front-end for Java</a> that can take
1071    Java sources or Java byte codes and generate native executables; <a
1072    href="http://www.transvirtual.com">Transvirtual</a> has implemented
1073    <a href="http://www.kaffe.org">Kaffe</a> a JIT engine for Java;
1074    Intel also has a Java VM called <a
1075    href="http://www.intel.com/research/mrl/orp">ORP</a>.
1076
1077    The JVM is not designed to be a general purpose virtual machine.
1078    The Common Intermediate Language (CIL), on the other hand, is
1079    designed to be a target for a
1080    wide variety of programming languages, and has a set of rules
1081    designed to be optimal for JITers.
1082
1083 Q: Could Java target the CLI?
1084
1085 A: Yes, Java could target the CLI, Microsoft's J# compiler does that.
1086
1087    The <a href="http://weblog.ikvm.net/">IKVM</a> project builds a
1088    Java runtime that works on top of .NET and on top of Mono.  IKVM is
1089    essentially a JIT compiler that translates from JVM bytecodes into
1090    CIL instructions, and then lets the native JIT engine take over. 
1091
1092 Q: Is it possible to write a JVM byte code to CIL converter?
1093
1094 A: Yes, it is possible.  Here are a few starting point:
1095
1096         <ul>
1097                 * A byte code representation is really a flattened forest of
1098                   trees.  Look at the Mono JIT engine to see how we compute
1099                   the basic blocks (this is used to figure out the "trees").
1100
1101                   The forest is just an array of trees.
1102
1103                   Indeed, run the JIT engine with -d (mono -d prog.exe) and
1104                   you will see how these trees look like.
1105
1106                   You will have to do something similar for Java.
1107
1108                 * Each "forest of trees" has a meaning.  This meaning can now
1109                   be translated into the equivalent "meaning" in CLR-land.
1110         </ul>
1111
1112    See also the <a href="http://weblog.ikvm.net/">IKVM project</a>
1113
1114 Q: Could mono become a hybrid CIL/java platform?
1115
1116 A: No. It is quite far from the philosophy of the project. The idea of Mono 
1117    is, to have only _one_ VM, on which all can run. And if there existing a 
1118    binary-converter from Java-.class to IL and if there existing something 
1119    like J-Sharp on Mono, you can write programs in Java, which than can run 
1120    on Mono. You do not need two bindings (like your example: GTK-Sharp _and_ 
1121    Java-Gnome). You need only _one_ of it (GTK-Sharp). Thats the idea of Mono.
1122    An other point is, that there are no people, who use Open Source-JVMs. They 
1123    all prefer Suns original. But for Unix there don't exist a .NET-Framework. 
1124    So it is possible, that in the future Mono is the standard .NET for Unixes.
1125
1126 Q: Do you plan to implement a Javascript compiler?
1127
1128 A: Yes.  The beginnings of the JScript compiler can be found on CVS.
1129    Cesar coordinates this effort.
1130
1131 Q: Can Mono or .NET share system classes (loaded from mscore.dll and other 
1132    libs) or will it behave like Sun's Java VM?
1133
1134 A: What you can do with mono is to load different applications in their own
1135    application domain: this is a feature of the CLR that allows sandboxing
1136    applications inside a single process space. This is usualy exploited to
1137    compartmentalize different parts of the same app, but it can also be
1138    effectively used to reduce the startup and memory overhead.
1139    Using different appdomains the runtime representation of types and
1140    methods is shared across applications.
1141
1142 <a name="extending"></a>
1143 ** Extending Mono
1144
1145 Q: Would you allow other classes other than those in the
1146    specification?
1147
1148 A: Yes.  The Microsoft class collection is very big, but it is by no
1149    means complete.  It would be nice to have a port of `Camel' (the
1150    Mail API used by Evolution inspired by Java Mail) for Mono
1151    applications.  
1152
1153    You might also want to look into implementing CORBA for Mono.  Not
1154    only because it would be useful, but because it sounds like a fun
1155    thing to do, given the fact that the CLI is such a type rich
1156    system. 
1157
1158    For more information on extending Mono, see our <a
1159    href="ideas.html">ideas</a> page.
1160
1161 Q: Do you plan to Embrace and Extend .NET?
1162
1163 A: Embracing a good technology is good.  Extending technologies in
1164    incompatible ways is bad for the users, so we do not plan on 
1165    extending the technologies.
1166
1167    If you have innovative ideas, and want to create new classes, we 
1168    encourage you to make those classes operate correctly well in both
1169    Mono and .NET.
1170
1171    Today Mono ships with a number of extra libraries that were
1172    developed either by members of the Mono community, or other
1173    groups.  
1174
1175 Q: Is there any way I can develop the class libraries using Linux yet?
1176
1177 A: Yes.  Mono has been selfhosting since March 2002. 
1178
1179 Q: Is there any way I can install a known working copy of mono in /usr, 
1180    and an experimental copy somewhere else, and have both copies use 
1181    their own libraries? (I'm still not very good at library paths in 
1182    Linux)
1183
1184 A: Yes. Just use two installation prefixes.
1185
1186
1187 <a name="portability"></a>
1188 ** Portability
1189
1190 Q: Will Mono only work on Linux?
1191
1192 A: Currently, we are doing our work on Linux-based systems and
1193    Windows.  We do not expect many Linux-isms in the code, so it
1194    should be easy to port Mono to other UNIX variants.   
1195
1196 Q: What about Mono on non Linux-based systems?
1197
1198 A: Our main intention at Ximian is to be able to develop GNOME
1199    applications with Mono, but if you are interested in providing a
1200    port of the Winforms classes to other platforms (frame buffer or
1201    MacOS X for example), we would gladly integrate them, as long
1202    they are under an open source license.  
1203
1204 Q: What operating systems/CPUs do you support
1205
1206 A: Mono currently runs on Linux, Windows, Solaris and FreeBSD.
1207    There is a JIT engine available for x86 processors that can
1208    generate code and optimizations tailored for a particular CPU.
1209
1210    Interpreters exist for the SPARC, PowerPC and StrongARM CPUs.
1211
1212 Q: Does Mono run on Windows?
1213
1214 A: Yes.   You can get pre-compiled
1215    binaries from <a href="http://www.go-mono.com/download.html">http://www.go-mono.com/download.html</a>
1216
1217 Q: Does Mono run on Linux?
1218
1219 A: Yes.  You can get pre-compiled
1220    binaries from <a href="http://www.go-mono.com/download.html">http://www.go-mono.com/download.html</a>
1221
1222 Q: Will I require Cygwin to run mono?
1223
1224 A: No.  Cygwin is only required to build Mono.
1225
1226 Q: Will Mono depend on GNOME?
1227
1228 A: It will depend only if you are using a particular assembly (for
1229    example, for doing GUI applications).  If you are just interested
1230    in Mono for implementing a `Hello World Enterprise P2P Web
1231    Service', you will not need any GNOME components.
1232
1233 Q: Is anyone working on porting Mono to IA-64?
1234
1235 A: Nobody is working on such port.
1236
1237 Q: If I were about to start a Mono port to IA-64,would the same lburg code 
1238    generator work for IA-64 also? or anything else need to be used for code 
1239    generation(as the processor architecture is totally different from IA32)
1240
1241 A: The lburg approach can be use for any processor architecture. But you might
1242    think in another better approach.
1243
1244 Q: Do you plan to port Rhino to C#?.
1245
1246 A: Eto Demerzal has started a Rhino port to C#.
1247
1248 Q: Has anyone succeeded in building a Mac version of the C# environment. 
1249    If so can you explain how?  
1250
1251 A: You could try to check with the Darwin people, or the Fink people.
1252    Mono/C# is self hosting on Linux/PPC which is the hard part, so it
1253    should be relatively simple to get it to work on MacOS
1254
1255 <a name="reuse"></a>
1256 ** Reusing Existing Code
1257
1258 Q: What projects will you reuse or build upon?
1259
1260 A: We want to get Mono in the hands of programmers soon.  We are
1261    interested in reusing existing open source software.
1262
1263 Q: What about Intel's research JIT framework, ORP?
1264
1265 A: At this time, we are investigating whether we can use elements of
1266    ORP for Mono.   ORP is a research JIT engine that has a clearly
1267    defined API that splits the JIT from the GC system and the actual
1268    byte code implementation.
1269
1270    We are using some pieces of ORP (Their code generation interface)
1271    and we use it as a source of inspiration for optimizations.  Paolo
1272    and Dietmar consider ORP as being one of the best JIT engines out
1273    there (and their research work and papers are very useful if you are
1274    interested in JIT technology).
1275
1276 Q: What about using GNU Lightning?
1277
1278 A: We are not using GNU Lightning.  Our JIT is using an instruction
1279    selector based on tree-pattern matching, and a code generation
1280    interface that is very tied to the current architecture.
1281
1282 Q: Will I be able to use Microsoft SQL Server 2000 or will I need to switch
1283    to a specific Open Source Database. Will I need to recode?
1284
1285 A: There should not be any need to recode.
1286
1287 Q: What do I need to watch out for when programming in VB.NET so that I'm
1288    sure to be able to run those apps on Linux?
1289
1290 A: Not making any P/Invoke or DLL calls should and not using anything in
1291    the Microsoft.* namespaces should suffice. Also do not use any 
1292    Methods/Classes marked as "This type/method supports the .NET Framework 
1293    infrastructure and is not intended to be used directly from your code." 
1294    even if you know what these classes/methods do.
1295
1296 Q: Will built-in reporting be supported for crystal reports? This is a
1297    heavily used part of our system.
1298
1299 A: Probably not. Crystal Reports are propriety. Someone may try to emulate
1300    the behavior, but no-one has yet volunteered.
1301
1302 Q: Who about writing to the registry? As I understand it, Linux does not have
1303    a counterpart to the registry. Should I avoid relying on that feature?
1304
1305 A: Try to avoid it. Although there would be a emulation for registry in
1306    Mono too. GNOME does have a registry like mechanism for configuration. But
1307    Even if gnome has a configuration system similar to the registry, the keys 
1308    will not be equal, so you will probably end up having to do some runtime 
1309    detection, and depending on this load an assembly that has your 
1310    platform-specific hacks.
1311
1312 Q: System.Data.SqlClient with FreeTDS, will you port parts of these to C# and 
1313    use them?
1314
1315 A: if their license is compatible with mono's, yes, we'd think about porting 
1316    them. If not, we'll continue with the plan of using FreeTDS.
1317
1318 <a name="gcc"></a>
1319 ** Mono and GCC
1320
1321 Q: Are you working on a GCC front-end to C#? A GCC back-end that will
1322    generate CIL images? What about making a front-end to GCC that
1323    takes CIL images and generates native code?
1324
1325 A: We are currently seeking volunteers for those projects.
1326    Visit the <a href="contributing.html">contributing</a> section if
1327    you are interested.
1328
1329 Q: But would this work around the GPL in the GCC compiler and allow
1330    people to work on non-free front-ends?
1331
1332 A: People can already do this by targeting the JVM byte codes (there
1333    are about 130 compilers for various languages that target the JVM).
1334
1335 Q: Why are you writing a JIT engine instead of a front-end to GCC?
1336
1337 A: We want the JIT engine and runtime engine because they will be able
1338    to execute CIL executables generated on Windows, and so no recompilation 
1339    will be necessary.
1340
1341 <a name="performance"></a>
1342 ** Performance
1343
1344 Q: How fast will Mono be?
1345
1346 A: We can not predict the future, but a conservative estimate is that
1347    it would be at least `as fast as other JIT engines'.
1348
1349    We would like to ship various JIT engines with Mono, just like
1350    Microsoft has done with their .NET development platform. We could
1351    provide a faster, JIT for fast load times but lower performance,
1352    and an and an optimizing JIT that would be slower at generating
1353    code but produce more optimal output.
1354
1355    The CIL has some advantages over the Java byte code:  it is really
1356    an intermediate representation and there are a number of
1357    restrictions on how you can emit CIL code that simplify creating
1358    better JIT engines.
1359
1360    For example, on the CIL, the stack is not really an abstraction
1361    available for the code generator to use at will.  Rather, it is a
1362    way of creating a postfix representation of the parsed tree.  At
1363    any given call point or return point, the contents of the stack are
1364    expected to contain the same object types independently of how the
1365    instruction was reached.
1366
1367 <a name="licensing"></a>
1368 ** Licensing
1369
1370 Q: Will I be able to write proprietary applications that run with
1371    Mono?
1372
1373 A: Yes.  The licensing scheme is planned to allow proprietary
1374    developers to write applications with Mono.
1375    
1376 Q: What license or licenses are you using for the Mono Project?
1377
1378 A: The C# Compiler is released under the terms of the <a 
1379    href="http://www.opensource.org/licenses/gpl-license.html">GNU GPL</a>.  The runtime
1380    libraries are under the <a
1381    href="http://www.opensource.org/licenses/lgpl-license.html">GNU
1382    Library GPL</a>.  And the class libraries are released
1383    under the terms of the <a
1384    href="http://www.opensource.org/licenses/mit-license.html">MIT X11</a>
1385    license.
1386
1387    The Mono runtime and the Mono C# Compiler are also available under
1388    a proprietary license for those who can not use the LGPL and the
1389    GPL in their code.  
1390
1391    For licensing details, contact <a
1392    href="mailto:mono-licensing@ximian.com">mono-licensing@ximian.com</a>
1393
1394
1395 Q: I would like to contribute code to Mono under a particular
1396    license. What licenses will you accept?
1397
1398 A: We will have to evaluate the licenses for compatibility first,
1399    but as a general rule, we will accept the code under the same
1400    terms of the "container" module. 
1401
1402 <a name="patents"></a>
1403 ** Patents
1404
1405 Q: Could patents be used to completely disable Mono (either submarine
1406    patents filed now, or changes made by Microsoft specifically to
1407    create patent problems)?
1408
1409 A: First some background information.
1410
1411    The .NET Framework is divided in two parts: the ECMA/ISO covered
1412    technologies and the other technologies developed on top of it like
1413    ADO.NET, ASP.NET and Windows.Forms.
1414
1415    Mono implements the ECMA/ISO covered parts, as well as being a
1416    project that aims to implement the higher level blocks like
1417    ASP.NET, ADO.NET and Windows.Forms.  
1418
1419    The Mono project has gone beyond both of those components and has
1420    developed and integrated third party class libraries, the most
1421    important being: Debugging APIs, integration with the Gnome
1422    platform (Accessibility, Pango rendering, Gdk/Gtk, Glade, GnomeUI),
1423    Mozilla, OpenGL, extensive database support (Microsoft only
1424    supports a couple of providers out of the box, while Mono has
1425    support for 11 different providers), our POSIX integration
1426    libraries and finally the embedded API (used to add scripting to
1427    applications and host the CLI, or for example as an embedded
1428    runtime in Apache). 
1429
1430    The core of the .NET Framework, and what has been patented by
1431    Microsoft falls under the ECMA/ISO submission.  Jim Miller at
1432    Microsoft has made a statement on the patents covering ISO/ECMA,
1433    (he is one of the inventors listed in the patent): <a
1434    href="https://mailserver.di.unipi.it/pipermail/dotnet-sscli/msg00218.html">here</a>.
1435
1436    Basically a grant is given to anyone who want to implement those
1437    components for free and for any purpose.
1438
1439    The controversial elements are the ASP.NET, ADO.NET and
1440    Windows.Forms subsets.  Those are convenient for people who need
1441    full compatibility with the Windows platform, but are not required
1442    for the open source Mono platform, nor integration with today's
1443    Mono's rich support of Linux. 
1444
1445    The Mono strategy for dealing with these technologies is as
1446    follows: (1) work around the patent by using a different
1447    implementation technique that retains the API, but changes the
1448    mechanism; if that is not possible, we would (2) remove the pieces
1449    of code that were covered by those patents, and also (3) find prior
1450    art that would render the patent useless.
1451  
1452    Not providing a patented capability would weaken the
1453    interoperability, but it would still provide the free software /
1454    open source software community with good development tools, which
1455    is the primary reason for developing Mono.  
1456
1457    The patents do not apply in countries where software patents are
1458    not allowed.
1459
1460    For Linux server and desktop development, we only need the ECMA
1461    components, and things that we have developed (like Gtk#) or Apache
1462    integration.  
1463
1464 Q: Is Mono only an implementation of the .NET Framework?
1465
1466 A: Mono implements both the .NET Framework, as well as plenty of class
1467    libraries that are either Unix specific, <a
1468    href="http://www.gnome.org">Gnome</a> specific, or that are not
1469    part of the .NET Framework but people find useful. 
1470
1471    The following map shows the relationship between the components:
1472
1473    <img src="http://primates.ximian.com/~miguel/tmp/map.png">
1474
1475 <a name="etc"></a> 
1476 ** Miscellaneous Questions
1477
1478 Q: You say that the CLI allows multiple languages to execute on the
1479    same environment.  Isn't this the purpose of CORBA?
1480
1481 A: The key difference between CORBA (and COM) and the CLI is that the
1482    CLI allows "data-level interoperability" because every
1483    language/component uses the same data layout and memory management.
1484
1485    This means you can operate directly upon the data types that someone
1486    else provides, without having to go via their interfaces.  It also
1487    means you don't have to "marshal" (convert) parameters (data
1488    layouts are the same, so you can just pass components directly) and
1489    you don't have to worry about memory management, because all
1490    languages/components share the same garbage collector and address
1491    space.  This means much less copying and no need for reference
1492    counting.
1493
1494 Q: Will you support COM?
1495
1496 A: The runtime will support XPCOM on Unix systems and COM on Windows.
1497    Most of the code for dynamic trampolines exists already.
1498
1499 Q: Will Ximian offer certifications on Mono or related technologies?. 
1500
1501 A: It's possible. But there is no plan about this. So the short answer is no.
1502
1503 Q: Are there any Boehm's GC binaries?
1504
1505 A: Yes. You can find RPMs <a href="http://java.thn.htu.se/~toor/">here</a>, though
1506    if your distribution provides the correct packages, you should use those.
1507    The suggested version of the Boehm GC is 6.1.
1508
1509 Q: How can I report a bug?
1510
1511 A: The best thing is to track down the bug and provide a simple test to
1512    reproduce the bug. You can then add the bug to the 
1513    <a href="http://bugzilla.ximian.com/enter_bug.cgi">bugtracking system</a>.
1514
1515    Please provide information about what version of mono you're using
1516    and any relevant details to be able to reproduce the bug. Note that
1517    bugs reported on the mailing-list may be easily forgotten, so it's
1518    better to file them in the <a href="http://bugzilla.ximian.com/enter_bug.cgi">bug tracking system</a>.
1519
1520 Q: Does mcs support the same command line options as the MS C# 
1521    compiler?
1522
1523 A: The Mono C# compiler now supports the same command line
1524    arguments as the Microsoft C# compiler does.
1525
1526 Q: How about getting searchable archives on lists.ximian.com? 
1527
1528 A: You can perform a search on the mono-related mailing lists 
1529    <a href="http://www.go-mono.com/mailing-lists.html">here</a>.
1530
1531 Q: When using mono from cvs or from a snapshot, I get an error messaage
1532    saying that Mono and the runtime are out of sync. How do I fix that?
1533
1534 A: If you use mono from cvs, you need to be prepared for changes in the
1535    runtime internals. This means that you should keep a working setup 
1536    before blindling updating (a working setup may just be the last released
1537    tarball or a recent binary snapshot).
1538    Usually, compiling corlib with mcs before recompiling the C runtime does
1539    the right thing (but occasionally you may need to do it the other 
1540    way around).
1541
1542 Q: Why are you going for a GtkHtml implementation?
1543
1544 A: GtkHTML is just a lightweight HTML rendering engine that does not
1545    support CSS, so we need it to look decent for those of us that will 
1546    be using the documentation in our day-to-day work on Linux. The 
1547    Web-based interfaces lack the agility that you get from a native GUI
1548    tool to browse your documentation. Probably later on, we will write 
1549    scripts and generate a full documentation set that is web-browsable, 
1550    but we need a command-line and GUI tools that we can use natively on 
1551    Linux when disconnected from the Web (and that has better 
1552    interactions than a web page).
1553
1554 Q: Is there a command-line tool that allows me to access .NET interactively?
1555
1556 A: There are several but one that is free software and uses MCS is the one
1557    Dennis Lu from Rice University is working on; a REPL C# interpreter.
1558
1559 Q: Is it possible to use Visual C++ with Mono?.
1560
1561 A: It's possible to run VC++ generated apps under Mono, but we do not
1562    provide a Manager C++ compiler ourselves.
1563
1564 Q: Does Mono support generics?.
1565
1566 A: Mono doesn't support generics currently but a lot of work is being 
1567    done towards it.
1568
1569 <a name="problems"></a>
1570 ** Mono Common Problems
1571
1572    If you are having problems compiling or running Mono software
1573    or if you think that you found a bug, etc. Please visit the
1574    <a href="http://monoevo.sf.net/mono-common-problems.html">Mono Common Problems</a> document and try there. 
1575
1576 ** Credits
1577
1578    The FAQ contains material contributed by Miguel de Icaza, Jaime Anguiano, Lluis Sánchez.