Flush
[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="#pnpproject">Mono and the Portable.NET Project</a><br>
7 <a href="#webservices">Web Services</a><br>
8 <a href="#devel">Development Tools and Issues</a><br>
9 <a href="#java">Mono and Java</a><br>
10 <a href="#extending">Extending Mono</a><br>
11 <a href="#portability">Portability</a><br>
12 <a href="#reuse">Reusing Existing Code</a><br>
13 <a href="#gcc">Mono and GCC</a><br>
14 <a href="#performance">Performance</a><br>
15 <a href="#licensing">Licensing</a><br>
16 <a href="#etc">Miscellaneous Questions</a><br>
17
18
19 <a name="basics"></a>
20 ** Basics
21
22 Q: What is Mono exactly?
23
24 A: The Mono Project is an open development initiative sponsored by
25    Ximian that is working to develop an open source, Linux-based
26    version of the Microsoft .NET development platform.  Its objective
27    is to enable Linux developers to build and
28    deploy cross-platform .NET Applications.  The project will
29    implement various technologies developed by Microsoft that have now
30    been submitted to the ECMA for standardization.
31
32 Q: What is the difference between Mono and the .NET Initiative?
33
34 A: The ".NET Initiative" is a somewhat nebulous company-wide effort by
35    Microsoft, one part of which is a cross-platform development
36    framework.  Mono is an implementation of the development framework,
37    but not an implementation of anything else related to the .NET
38    Initiative, such as Passport, software-as-a-service, or
39    corporate rebranding.
40
41 Q: What technologies are included in Mono?
42
43 A: Mono contains a number of components useful for building new
44    software:
45
46         <ul>
47                 * A Common Language Infrastructure (CLI) virtual
48                   machine that contains a class loader, Just-in-time
49                   compiler, and a garbage collecting runtime.
50
51                 * A class library that can work with any language
52                   which works on the CLR.
53
54                 * A compiler for the C# language.  In the future we
55                   might work on other compilers that target the Common
56                   Language Runtime.
57         </ul>
58
59
60    Windows has compilers that target the virtual machine from <a
61    href="http://msdn.microsoft.com/net/thirdparty/default.asp#lang">a
62    number of languages:</a> Managed C++, Java Script, Eiffel,
63    Component Pascal, APL, Cobol, Oberon, Perl, Python, Scheme,
64    Smalltalk, Standard ML, Haskell, Mercury and Oberon.
65
66    The CLR and the Common Type System (CTS) enables applications and
67    libraries to be written in a collection of different languages that
68    target the byte code
69
70    This means for example that if you define a class to do algebraic
71    manipulation in C#, that class can be reused from any other
72    language that supports the CLI.  You could create a class in C#,
73    subclass it in C++ and instantiate it in an Eiffel program. 
74
75    A single object system, threading system, class libraries, and
76    garbage collection system can be shared across all these languages.
77    
78 Q: Where can I find the specification for these technologies?
79
80 A: You can find the work-in-progress documentation from the T3G ECMA
81    group here:
82  
83    <a href="http://www.dotnetexperts.com">http://www.dotnetexperts.com</a>
84
85 Q: Will you implement the .NET Framework SDK class libraries?
86
87 A: Yes, we will be implementing the APIs of the .NET Framework SDK
88    class libraries. 
89
90 Q: Will you offer an ECMA-compliant set of class libraries?
91
92 A: Eventually we will.  Our current focus is on interoperating
93    with the Microsoft SDK, but we will also offer an ECMA compliant
94    set of libraries. 
95
96 Q: What does the name "Mono" mean?
97
98 A: Mono is the word for `monkey' in Spanish. We like monkeys.
99
100 Q: Is Mono usable?
101
102 A: The JIT engine is usable on Intel x86 machines.  An interpreter
103    can be used on other non-Intel x86 machines.  
104
105    The class libraries are not yet mature enough to run real applications,
106    but if you are interested in trying out Mono, you can definetly start
107    testing things out as many programs run.
108
109    The C# compiler has made significant progress, it can even compile
110    itself now, but it can not yet be ran with our class libraries as
111    they are missing some features. 
112
113 Q: When will you ship it?
114
115 A: It is premature to target a shipdate for the code, but we
116    anticipate that it will be available some time in the middle of
117    2002.
118
119 Q: How can I contribute?
120
121 A: Check the <a href="contributing.html">contributing</a> section. 
122
123 Q: Aren't you just copying someone else's work?
124
125 A: We are interested in providing the best tools for programmers to
126    develop applications for Free Operating Systems.  We also want to help
127    provide the interoperability that will allow those systems to fit in
128    with other standards.
129
130    For more background, read the <a href="http://www.go-mono.com/rationale.html">Mono
131    Project white paper</a>.
132    the project.
133
134
135 <a name="ximian"></a> 
136
137 ** The Ximian Role in the Mono Project
138
139 Q: Why is Ximian working on .NET?
140
141 A: Ximian is interested in providing the best tools for programmers to
142    develop applications for Free Operating Systems.  
143
144    For more information, read the project <a
145    href="rationale.html">rationale</a> page.
146
147 Q: Will Ximian be able to take on a project of this size?  
148
149 A: Of course not. Ximian a supporter of the Mono project, but the only way
150    to implement something of this size is for the entire free software
151    community to get involved. Visit the <a href="contributing.html">contributing</a> 
152    page if you'd like to help out.
153
154 Q: What pieces will Ximian be working on?
155
156 A: We will devote most of our resources to work on the pieces which are
157    on the critical path to release a development and execution
158    environment. Once the project is at a stage where it is useful in
159    the real world, it will achieve a critical mass of developers to
160    improve it further.
161
162 Q: Will Ximian offer Mono commercially?
163
164 A: When Mono is ready to be shipped Ximian will offer a commercial
165    support and services for Mono. 
166
167 Q: Will you wait until Mono is finished?
168
169 A: Mono will ship on various stages as they mature.  Some people
170    require only a subset of the technologies, those will ship first.
171
172    More advanced features will take more time to develop.  A support
173    timeline will be available in June 2002.
174
175 <a name="gnome"></a> 
176 ** Mono and GNOME
177
178 Q: How is Mono related to GNOME?
179
180 A: In a number of ways.  This project was born out of the need of
181    providing improved tools for the GNOME community, and will use
182    existing components that have been developed for GNOME when they
183    are available.  For example, we plan to use Gtk+ and Libart to
184    implement Winforms and the Drawing2D API and are considering
185    GObject support.
186
187 Q: Has the GNOME Foundation or the GNOME team adopted Mono?
188
189 A: Mono is too new to be adopted by those groups. We hope that the
190    tools that we will provide will be adopted by free software
191    programmers including the GNOME Foundation members and the GNOME
192    project generally.
193
194 Q: Should GNOME programmers switch over to Mono now?
195
196 A: It is still far to early for discussions of "switching over."  No
197    pieces of Mono will be ready within the next six months, and a
198    complete implementation is roughly one year away.
199
200    We encourage GNOME developers to continue using the existing tools,
201    libraries and components.  Improvements made to GNOME will have an
202    impact on Mono, as they would be the "backend" for various classes.
203
204 Q: Will Mono include compatibility with Bonobo components? What is the
205    relationship between Mono and Bonobo?
206
207 A: Yes, we will provide a set of classes for implementing and using
208    Bonobo components from within Mono.  Mono should allow you to write
209    Bonobo components more easily, just like .NET on Windows allows you
210    to export .NET components to COM.
211
212 Q: Does Mono depend on GNOME?
213
214 A: No, Mono does not depend on GNOME.  We use a few packages produced by
215    the GNOME team like the `glib' library.  
216
217 Q: But will I be able to build GNOME applications?
218
219 A: Yes, we will enable people to write GNOME applications using Mono.
220
221 <a name="gui"></a>
222 ** GUI applications
223
224 Q: Will Mono enable GUI applications to be authored?
225
226 A: Yes, you will be able to build GUI applications.  Indeed, that is our
227    main focus.  We will provide both the Windows.Forms API and the Gtk# AP(I.
228
229 Q: What is the difference between Gtk# and System.Windows.Forms?
230
231 A: Gtk# is a set of bindings for the Gtk+ toolkit for C# (and other
232    CIL-enabled languages).  System.Windows.Forms is an API defined
233    by Microsoft to build GUI applications.
234
235 Q: Will I be able to run my smart clients on systems powered by Mono?
236
237 A: As long as your applications are 100% .NET and do not make use
238    of P/Invoke to call Win32 functions, your smart client applications
239    will run on Mono platforms.
240
241 <a name="msft"></a>
242 ** Mono and Microsoft
243
244 Q: Is Microsoft helping Ximian with this project?
245
246 A: No. Ximian CTO Miguel de Icaza had a friendly conversation with
247    Microsoft software architect David Stutz, but that's about the
248    extent of the contact. Microsoft is interested in other
249    implementations of .NET and are willing to help make the ECMA spec
250    more accurate for this purpose.
251
252    Ximian representatives have also spoken with Sam Ruby at the ECMA
253    TG3 committee to discuss the same issues.
254
255 Q: Is Microsoft or Corel paying Ximian to do this?
256
257 A: No.
258
259 Q: Do you fear that Microsoft will change the spec and render Mono
260    useless?
261
262 A: No.  Microsoft proved with the CLI and the C# language that it was
263    possible to create a powerful foundation for many languages to
264    interoperate.  We will always have that.  
265
266    Even if changes happened in the platform which were undocumented,
267    the existing platform would a value on its own.
268
269 Q: Are you writing Mono from the ECMA specs?
270
271 A: Yes, we are writing them from the ECMA specs and the published
272    materials in print about .NET.
273
274 Q: If my applications use Mono, will I have to pay a service fee?
275
276 A: No.  Mono is not related to Microsoft's initiative of
277    software-as-a-service.
278
279 Q: Is the Mono Project is related to the Microsoft Hailstorm effort?  Is
280    Ximian endorsing Hailstorm?  
281
282 A: No.  The Mono Project is focused on providing a compatible set of
283    tools for the Microsoft .NET development platform.  It does not
284    address, require, or otherwise endorse the MS Passport-based
285    Hailstorm single sign-on system that is part of Windows XP and
286    other services.
287
288 Q: Will Mono or .NET applications depend on Microsoft Passport?
289
290 A: No. MS Passport is unrelated to running .NET compatible applications
291    produced with the Mono tools.  The only thing you will need is a
292    just-in-time compiler (JIT).
293
294 Q: What is a 100% .NET application?
295
296 A: A `100% .NET application' is one that only uses the APIs defined
297    under the System namespace and does not use PInvoke.  These
298    applications would in theory run unmodified on Windows, Linux,
299    HP-UX, Solaris, MacOS X and others. 
300
301 Q: If Microsoft will release a port of their .NET platform under the
302    `Shared Source' license, why should I bother with anything else?
303
304 A: The Shared Source implementation will be expensive and its uses
305    will be tightly restricted, especially for commercial use. We are
306    working towards an implementation that will grant a number of
307    important rights to recipients: use for any purpose,
308    redistribution, modification, and redistribution of modifications.
309
310    This is what we call <a
311    href="http://www.gnu.org/philosophy/free-sw.html">Free Software</a>
312
313 Q: Is Mono a free implementation of Passport?
314
315 A: No. Mono is just a runtime, a compiler and a set of class
316    libraries.
317
318 Q: Will the System.Web.Security.PassportIdentity class mean
319    that my software will depend on Passport?
320    
321 A: No.  Applications may use that API to contact a Passport site, but
322    are not required to do so.
323
324    As long as your application does not use Passport, you will not
325    need Passport.  
326
327 Q: Will Mono running on Linux make Passport available for Linux?
328
329 A: No.  However, the Passport toolkit for Linux-based web servers is
330    available from Microsoft.
331
332 Q: Will Mono allow me to run Microsoft Office on Linux?
333
334 A: No, it will not.  Microsoft Office is a Windows application.  To
335    learn more about running Windows applications on Intel Unix systems
336    refer to <a href="http://www.winehq.com">the Wine Project</a>.
337
338 <a name="pnpproject"></a>
339 ** Mono and Portable.NET
340
341 Q: What are the differences between Mono and Portable.NET?
342
343 A: Most of Mono is being written using C#, with only
344    a few parts written in C (The JIT engine, the runtime, the
345    interfaces to the garbage collection system).  The Portable.NET
346    Project is using C for development.
347
348 <a name="webservices"></a>
349 ** Web Services
350
351 Q: How is Mono related to Web Services?
352
353 A: Mono is only related to Web Services in that it will implement the
354    same set of classes that have been authored in the .NET Framework
355    to simplify and streamline the process of building Web Services.
356
357    But most importantly, Mono is an Open Source implementation of the
358    .NET Framework.
359
360 Q: Can I author Web Services with Mono?
361
362 A: You will be able to write Web Services on .NET that run on Mono and
363    viceversa. 
364
365 Q: If Mono implements the SDK classes, will I be able to write and
366    execute .NET Web Services with it?
367    
368 A: Yes.  When the project is finished, you will be able to use the
369    same technologies that are available through the .NET Framework SDK
370    on Windows to write Web Services.
371
372 Q: What about Soup?  Can I use Soup without Mono?
373
374 A: Soup is a library for GNOME applications to create SOAP servers and
375    SOAP clients, and can be used without Mono.  You can browse the
376    source code for soup using <a
377    href="http://cvs.gnome.org/bonsai">GNOME's Bonsai</a>.
378
379 Q: Can I use CORBA?
380
381 A: Yes. The CLI contains enough information about a class that
382    exposing it to other RPC systems (like CORBA) is really simple, and
383    does not even require support from an object.  
384
385    We will be implementing CORBA interoperation as an extension to the
386    Mono classes so that we can integrate with Bonobo, just like
387    Microsoft provides COM interoperation classes and support
388    mechanisms. 
389
390 Q: Can I serialize my objects to other things other than XML?
391
392 A: Yes, although the serializing tools have not yet been planned, and
393 you would probably have to implement them yourself.
394
395 <a name="devel"></a>
396 ** Development Tools and Issues
397
398 Q: Will it be possible to use the CLI features without using bytecodes
399    or the JIT?
400
401 A: Yes. The CLI engine will be made available as a shared library.
402    The garbage collection engine, the threading abstraction, the
403    object system, the dynamic type code system and the JIT will be
404    available for C developers to integreate with their applications if
405    they wish to do so. 
406
407 Q: Will you have new development tools?
408
409 A: With any luck, Free Software enthusiasts will contribute tools to
410    improve the developer environment.  These tools could be developed
411    initially using the Microsoft implementation of the CLI and then
412    executed later with Mono.
413
414 Q: What kind of rules make the Common Intermediate Language useful for
415    JITers?
416
417 A: The main rule is that the stack in the CLI is not a general purpose
418    stack.   You are not allowed to use it for other purposes than
419    computing values and passing arguments to functions or return
420    values.  
421
422    At any given call or return instruction, the types on the stack
423    have to be the same independently of the flow of execution of your
424    code. 
425
426 Q: Is it true that the CIL is ideal for JITing and not efficient for
427    interpreters?
428
429 A: The CIL is better suited to be JITed than JVM byte codes, but you
430    can interpret them as trivially as you can interpret JVM byte
431    codes. 
432
433 <a name="java">
434 ** Mono and Java
435    
436 Q: Why don't you use Java?  After all, there are many languages that
437    target the Java VM.
438
439 A: You can get very good tools for doing Java development on free
440    systems right now.  <a href="http://www.redhat.com">Red Hat</a> has
441    contributed a <a href="http://gcc.gnu.org">GCC</a> <a
442    href="http://gcc.gnu.org/java">frontend for Java</a> that can take
443    Java sources or Java byte codes and generate native executables; <a
444    href="http://www.transvirtual.com">Transvirtual</a> has implemented
445    <a href="http://www.kaffe.org">Kaffe</a> a JIT engine for Java;
446    Intel also has a Java VM called <a
447    href="http://www.intel.com/research/mrl/orp">ORP</a>.
448
449    The JVM is not designed to be a general purpose virtual machine.
450    The Common Intermediate Language (CIL), on the other hand, is
451    designed to be a target for a
452    wide variety of programming languages, and has a set of rules
453    designed to be optimal for JITers.
454
455 Q: Could Java target the CLI?
456
457 A: Yes, Java could target the CLI.  We have details on a <a
458    href="ideas.html#guavac">project</a> that someone could take on to
459    make this happen.  
460
461    Microsoft has an implemenation of the Java language called J# that
462    can target the CIL execution engine. 
463
464 Q: Is it possible to write a JVM byte code to CIL convertor?
465
466 A: Yes, it is possible.  Here are a few starting point:
467
468         <ul>
469                 * A byte code representation is really a flattened forest of
470                   trees.  Look at the Mono JIT engine to see how we compute
471                   the basic blocks (this is used to figure out the "trees").
472
473                   The forest is just an array of trees.
474
475                   Indeed, run the JIT engine with -d (mono -d prog.exe) and
476                   you will see how these trees look like.
477
478                   You will have to do something similar for Java.
479
480                 * Each "forest of trees" has a meaning.  This meaning can now
481                   be translated into the equivalent "meaning" in CLR-land.
482         </ul>
483
484 <a name="extending"></a>
485 ** Extending Mono
486
487 Q: Would you allow other classes other than those in the
488    specification?
489
490 A: Yes.  The Microsoft class collection is very big, but it is by no
491    means complete.  It would be nice to have a port of `Camel' (the
492    Mail API used by Evolution inspired by Java Mail) for Mono
493    applications.  
494
495    You might also want to look into implementing CORBA for Mono.  Not
496    only because it would be useful, but because it sounds like a fun
497    thing to do, given the fact that the CLI is such a type rich
498    system. 
499
500    For more information on extending Mono, see our <a
501    href="ideas.html">ideas</a> page.
502
503 Q: Do you plan to Embrace and Extend .NET?
504
505 A: Embracing a good technology is good.  Extending technologies in
506    incompatible ways is bad for the users, so we do not plan on 
507    extending the technologies.
508
509    If you have innovative ideas, and want to create new classes, we 
510    encourage you to make those classes operate correctly well in both
511    Mono and .NET
512
513 <a name="portability"></a>
514 ** Portability
515
516 Q: Will Mono only work on Linux?
517
518 A: Currently, we are doing our work on Linux-based systems and
519    Windows.  We do not expect many Linux-isms in the code, so it
520    should be easy to port Mono to other UNIX variants.   
521
522 Q: What about Mono on non X-based systems?
523
524 A: Our main intention at Ximian is to be able to develop GNOME
525    applications with Mono, but if you are interested in providing a
526    port of the Winform classes to other platforms (frame buffer or
527    MacOS X for example), we would gladly integrate them, as long
528    they are under an open source license.  
529
530 Q: Will Mono run on Windows?
531
532 A: We hope so.  Currently some parts of Mono only run on Windows
533    (the C# compiler is a .NET executable) and other parts have only
534    been compiled on Linux, but work on Windows with Cygwin.
535
536 Q: Will Mono depend on GNOME?
537
538 A: It will depend only if you are using a particular assembly (for
539    example, for doing GUI applications).  If you are just interested
540    in Mono for implementing a `Hello World Enterprise P2P Web
541    Service', you will not need any GNOME components.
542
543 <a name="reuse"></a>
544 ** Reusing Existing Code
545
546 Q: What projects will you reuse or build upon?
547
548 A: We want to get Mono in the hands of programmers soon.  We are
549    interested in reusing existing open source software.
550
551 Q: What about Intel's research JIT framework, ORP?
552
553 A: At this time, we are investigating whether we can use elements of
554    ORP for Mono.   ORP is a research JIT engine that has a clearly
555    defined API that splits the JIT from the GC system and the actual
556    byte code implementation.
557
558 Q: What about using GNU Lightning?
559
560 A: We are also researching <a
561    href="http://www.gnu.org/software/lightning/lightning.html">GNU
562    Lightning</a>.
563
564 <a name="gcc"></a>
565 ** Mono and GCC
566
567 Q: Are you working on a GCC front-end to C#? A GCC backend that will
568    generate CIL images? What about making a front-end to GCC that
569    takes CIL images and generates native code?
570
571 A: We are currently seeking volunteers for those projects.
572    Visit the <a href="contributing.html">contributing</a> section if
573    you are interested.
574
575 Q: But would this work around the GPL in the GCC compiler and allow
576    people to work on non-free front-ends?
577
578 A: People can already do this by targeting the JVM byte codes (there
579    are about 130 compilers for various languages that target the JVM).
580
581 Q: Why are you writing a JIT engine instead of a front-end to GCC?
582
583 A: We want the JIT engine and runtime engine because they will be able
584    to execute CIL executables generated on Windows, and so no recompilation 
585    will be necessary.
586
587 <a name="performance"></a>
588 ** Performance
589
590 Q: How fast will Mono be?
591
592 A: We can not predict the future, but a conservative estimate is that
593    it would be at least `as fast as other JIT engines'.
594
595    We would like to ship various JIT engines with Mono, just like
596    Microsoft has done with their .NET development platform. We could
597    provide a faster, JIT for fast load times but lower performance,
598    and an and an optimizing JIT that would be slower at generating
599    code but produce more optimal output.
600
601    The CIL has some advantages over the Java byte code:  it is really
602    an intermediate representation and there are a number of
603    restrictions on how you can emit CIL code that simplify creating
604    better JIT engines.
605
606    For example, on the CIL, the stack is not really an abstraction
607    available for the code generator to use at will.  Rather, it is a
608    way of creating a postfix representation of the parsed tree.  At
609    any given call point or return point, the contents of the stack are
610    expected to contain the same object types independently of how the
611    instruction was reached.
612
613 <a name="licensing"></a>
614 ** Licensing
615
616 Q: Will I be able to write proprietary applications that run with
617    Mono?
618
619 A: Yes.  The licensing scheme is planned to allow proprietary
620    developers to write applications with Mono.
621    
622 Q: What license or licenses are you using for the Mono Project?
623
624 A: The C# Compiler is released under the terms of the <a 
625    href="http://www.opensource.org/licenses/gpl-license.html">GNU GPL</a>.  The runtime
626    libraries are under the <a
627    href="http://www.opensource.org/licenses/lgpl-license.html">GNU
628    Library GPL</a>.  And the class libraries are released
629    under the terms of the <a
630    href="http://www.opensource.org/licenses/mit-license.html">MIT X11</a>
631    license.
632
633 Q: I would like to contribute code to Mono under a particular
634    license. What licenses will you accept?
635
636 A: We will have to evaluate the licenses for compatibility first,
637    but as a general rule, we will accept the code under the same
638    terms of the "container" module. 
639
640 <a name="etc"></a>
641 ** Miscellaneous Questions
642
643 Q: You say that the CLI allows multiple languages to execute on the
644    same environment.  Isn't this the purpose of CORBA?
645
646 A: The key difference between CORBA (and COM) and the CLI is that the
647    CLI allows "data-level interoperability" because every
648    language/component uses the same data layout and memory management.
649
650    This means you can operate directly upon the datatypes that someone
651    else provides, without having to go via their interfaces.  It also
652    means you don't have to "marshall" (convert) parameters (data
653    layouts are the same, so you can just pass components directly) and
654    you don't have to worry about memory managment, because all
655    languages/components share the same garbage collector and address
656    space.  This means much less copying and no need for reference
657    counting.
658
659 Q: Will you support COM?
660
661 A: The runtime will support XPCOM on Unix systems and COM on Windows.
662    Most of the code for dynamic trampolines exists already.
663