Flush
[mono.git] / web / faq
diff --git a/web/faq b/web/faq
index 7646c85e73d02e43f47c05adcc56450074e3839d..9a45337118c2e089c7e98e171087c1c6bb50946f 100644 (file)
--- a/web/faq
+++ b/web/faq
@@ -20,6 +20,7 @@
 <a href="#licensing">Licensing</a><br>
 <a href="#patents">Patents</a><br>
 <a href="#etc">Miscellaneous Questions</a><br>
 <a href="#licensing">Licensing</a><br>
 <a href="#patents">Patents</a><br>
 <a href="#etc">Miscellaneous Questions</a><br>
+<a href="#obfuscation">Obfuscation</a></br>
 <a href="#problems">Mono Common Problems</a><br>
 
 A <a
 <a href="#problems">Mono Common Problems</a><br>
 
 A <a
@@ -206,7 +207,7 @@ A: Of course not.  Novell is a supporter of the Mono project, but the only way
    community to get involved. Visit the <a href="contributing.html">contributing</a> 
    page if you'd like to help out.
 
    community to get involved. Visit the <a href="contributing.html">contributing</a> 
    page if you'd like to help out.
 
-Q: What pieces Novell be working on?
+Q: What pieces is Novell working on?
 
 A: We will devote most of our resources to work on the pieces which are
    on the critical path to release a development and execution
 
 A: We will devote most of our resources to work on the pieces which are
    on the critical path to release a development and execution
@@ -313,9 +314,22 @@ A: Gtk# is a set of bindings for the Gtk+ toolkit for C# (and other
    desktop.  System.Windows.Forms is an API defined by Microsoft to
    build GUI applications.
 
    desktop.  System.Windows.Forms is an API defined by Microsoft to
    build GUI applications.
 
-   Windows.Forms is currently being implemented on top of a modified
+Q: What are you using to implement Windows.Forms?
+
+A: Windows.Forms is currently being implemented on top of a modified
    version of Wine that can be used as a library: WineLib.
 
    version of Wine that can be used as a library: WineLib.
 
+   Essentially Wine is used as a library that happens to implement the
+   "Win32" toolkit and our Windows.Forms becomes a managed layer on
+   top of this toolkit.
+
+   There are several advantages in this approach: we get Wndproc
+   message compatibility for free (Wndproc is an overridable method in
+   the Control class and it is used to perform advanced tricks with
+   the GUI toolkit) as well as allowing third-party controls that are
+   used to P/Invoke into Win32 in the Windows world to work out of the
+   box on Linux/MacOS.
+
 Q: Why not implement System.Windows.Forms on top of Gtk# or Qt#?
 
 A: Compatibility.
 Q: Why not implement System.Windows.Forms on top of Gtk# or Qt#?
 
 A: Compatibility.
@@ -378,7 +392,7 @@ A: There is a sample file called `DbClient' in gtk-sharp/samples that you
 
 Q: Do you have an estimate for when Windows.Forms will be released?
 
 
 Q: Do you have an estimate for when Windows.Forms will be released?
 
-A: The plan currently is aimed at Q3/2004.
+A: The plan currently is aimed at Q4/2004.
 
 
 Q: Do you have a comparission chart about the various toolkit
 
 
 Q: Do you have a comparission chart about the various toolkit
@@ -499,14 +513,32 @@ Q: What operating systems does Mono run on?
 
 A: Mono is known to run on Linux, Unix and Windows systems.   
 
 
 A: Mono is known to run on Linux, Unix and Windows systems.   
 
+Q: Can I run Mono applications without using `mono program.exe'?
+
+A: Yes, this is possible on Linux systems, to do this, use something like:
+
+<pre>
+if [ ! -e /proc/sys/fs/binfmt_misc/register ]; then
+       /sbin/modprobe binfmt_misc
+       mount -t binfmt_misc none /proc/sys/fs/binfmt_misc
+fi
+
+if [ -e /proc/sys/fs/binfmt_misc/register ]; then
+       echo ':CLR:M::MZ::/usr/bin/mono:' > /proc/sys/fs/binfmt_misc/register
+else
+       echo "No binfmt_misc support"
+       exit 1
+fi
+</pre>
+
 Q: What architectures does Mono support?
 
 Q: What architectures does Mono support?
 
-A: Mono today ships with a Just-in-Time compiler for x86-based
-   systems.  It is tested regularly on Linux, FreeBSD and Windows
-   (with the XP/NT core).
+A: Mono today ships with a Just-in-Time compiler for x86, PowerPC and
+   SPARC-based systems.  It is tested regularly on Linux, FreeBSD and
+   Windows (with the XP/NT core).
 
    There is also an interpreter, which is slower that runs on the
 
    There is also an interpreter, which is slower that runs on the
-   s390, SPARC and PowerPC architectures.
+   s390, SPARC, HPPA, StrongARM and PowerPC architectures.
 
 Q: Can Mono run on Windows 9x, or ME editions?
 
 
 Q: Can Mono run on Windows 9x, or ME editions?
 
@@ -690,13 +722,14 @@ A: Most of Mono is being written using C#, with only
          will be most familiar with.
 
      <li> A multi-platform runtime engine: both a JIT engine and an
          will be most familiar with.
 
      <li> A multi-platform runtime engine: both a JIT engine and an
-          interpreter exist.  The JIT engine runs currently on x86
-          systems, while the interpreter works on SPARC, StrongARM,
-         s390 and PowerPC systems.  
+          interpreter exist.  The JIT engine runs currently on x86,
+          PowerPC Sparc and S390 systems, while the interpreter works on
+          x86, SPARC, StrongARM, s390 and PowerPC systems.  
 
 
-         Our new compilation engine is being ported to the PowerPC.
+         The JIT engine is being ported to amd64 systems as of this
+         time. 
 
 
-     <li> Supports Linux, BSD, Windows and Solaris at this point.
+     <li> Supports Linux, BSD, MacOS, Windows and Solaris at this point.
 
      <li> The JIT engine is written using a portable instruction
           selector which not only generates good code but
 
      <li> The JIT engine is written using a portable instruction
           selector which not only generates good code but
@@ -714,6 +747,65 @@ A: Most of Mono is being written using C#, with only
          tools, we bug fix problems rapidly, and the system is
          overall more robust and tested than if we did not.
 
          tools, we bug fix problems rapidly, and the system is
          overall more robust and tested than if we did not.
 
+     <li> Our class libraries are licensed under the terms of the MIT
+          X11 license which is a very liberal license as opposed to
+          the GNU GPL with exceptions, this means that Mono can be
+          used in places where the GPL with exceptions is not
+          permissible.
+
+     <li> Mono has a complete Web Services stack: we implement ASP.NET
+          web servers and web clients as well as implementing the
+          Remoting-based SOAP infrastructure.
+
+     <li> Remoting implementation: Mono has a complete remoting
+          infrastructure that is used in our own codebase to provide
+          added functionality and performance to our ASP.NET engine
+          and more.
+
+     <li> Mono has a complete <a href="c-sharp.html">C# 1.0</a>
+          implementation and has been stress tested a lot more than
+          Portable.NET's compiler.
+
+     <li> Mono's C# compiler has strong error handling and has closer
+          adherence to the specification with support for definite
+         assignment (required to generate verifiable IL code) and 
+         CLS conformance checking.
+
+     <li> Mono's C# compiler is written in C# which is easier for new
+          developers to come in and improve, fix and tune.  The Mono
+          C# compiler in C# is faster than their C-based compiler.
+
+     <li> Preview of C# 2.0: a work in progress for a 2.0
+          implementation of our compiler is available (iterators,
+          generics and anonymous methods are available in our
+          "preview" compiler).
+
+     <li> Mono has a complete Reflection and Reflection.Emit: these
+          are important for advanced applications, compilers and
+          dynamic code generation.
+
+     <li> Mono has a <a href="xml-classes.html">complete managed XML
+          stack</a>: XML, XPath, XML Serializer, XML Schema handling
+          are fully functional, feature complete and tuned for
+          performance.
+
+     <li> Mono has a <a href="crypto.html">complete cryptography stack
+         </a>: we implement the 1.0 and 1.1 APIs as well as using our
+         fully managed stack to implement the SSL/TLS transports. 
+
+     <li> <a href="ado-net.html">Extensive database support</a>: Mono
+          ships with database provides for <a
+          href="firebird.html">Firebird</a>, <a href="ibmdb2.html">IBM
+          DB2</a>, <a href="oracle.html">Oracle</a>, <a
+          href="sybase.html">Sybase</a>, Microsoft <a
+          href="tdsclient.html">SQL Server</a>, <a
+          href="sqlite.html">SQL Lite</a>, <a
+          href="mysql.html">MySQL</a>, <a
+          href="postgresql.html">PostgresSQL</A>, <a href="oledb.html">Ole
+          DB</a> and <a href="odbc.html">ODBC</a>.
+
+     <li> Mono includes full LDAP support.
+
      <li> We have a great community of developers, without which Mono
           would not be possible.
    </ul>
      <li> We have a great community of developers, without which Mono
           would not be possible.
    </ul>
@@ -834,12 +926,11 @@ A: To upgrade your class libraries and compiler, see the
    3.- Then checkout or update your mcs CVS copy. Then follow 
    the steps described in mcs/INSTALL.txt.
 
    3.- Then checkout or update your mcs CVS copy. Then follow 
    the steps described in mcs/INSTALL.txt.
 
-Q: Will it be possible to use the CLI features without using byte codes
-   or the JIT?
+Q: Will it be possible to use the CLI features without using byte codes or the JIT?
 
 A: Yes. The CLI engine will be made available as a shared library.
    The garbage collection engine, the threading abstraction, the
 
 A: Yes. The CLI engine will be made available as a shared library.
    The garbage collection engine, the threading abstraction, the
-   object system, the dynamic type code system and the JIT will be
+   object system, the dynamic type code system and the JIT are
    available for C developers to integrate with their applications if
    they wish to do so. 
 
    available for C developers to integrate with their applications if
    they wish to do so. 
 
@@ -1206,9 +1297,7 @@ A: Eto Demerzal has started a Rhino port to C#.
 Q: Has anyone succeeded in building a Mac version of the C# environment. 
    If so can you explain how?  
 
 Q: Has anyone succeeded in building a Mac version of the C# environment. 
    If so can you explain how?  
 
-A: You could try to check with the Darwin people, or the Fink people.
-   Mono/C# is self hosting on Linux/PPC which is the hard part, so it
-   should be relatively simple to get it to work on MacOS
+A: Yes, Mono works on Linux/PPC and MacOS X (10.2 and 10.3)
 
 <a name="reuse"></a>
 ** Reusing Existing Code
 
 <a name="reuse"></a>
 ** Reusing Existing Code
@@ -1258,11 +1347,30 @@ A: This has been done.
 <a name="gcc"></a>
 ** Mono and GCC
 
 <a name="gcc"></a>
 ** Mono and GCC
 
-Q: Are you working on a GCC front-end to C#? A GCC back-end that will
-   generate CIL images? 
+Q: Are you working on a GCC front-end to C#? 
+
+A: We are not working on a GCC front-end for C#
 
 
-A: We would love to see a GCC modification that would generate CIL
-   images, but there is nothing at this point.
+Q: Will you support C/C++ on the Mono VM?
+
+A:The open64 compiler effort from SGI helps a lot in this direction.
+
+   The Open64 compiler is a modified version of GCC that
+   generates a new intermediate language instead of RTL.  This could be
+   the foundation to generate CIL code, and to implement the upcoming
+   Managed extensions to C++ from ECMA.
+
+   Open64 (and other derivative forks of GCC) split the gcc front-ends
+   from the backends by using the WHIRL intermediate representation.  
+   Kris has begun the implementation of a translator from WHIRL to CIL.
+
+   So it will be possible to use the GCC compilers to target the CIL.
+
+Q: What about Managed C++?
+
+A: Once a full translator for WHIRL exists, we are interested in
+   looking at expanding the GCC frontends to include extensions for
+   Managed C++.
 
 Q: What about making a front-end to GCC that takes CIL images and
    generates native code?
 
 Q: What about making a front-end to GCC that takes CIL images and
    generates native code?
@@ -1270,11 +1378,6 @@ Q: What about making a front-end to GCC that takes CIL images and
 A: There is no active work on this area, but Mono already provides
    pre-compilation services (Ahead-of-Time compilation).
 
 A: There is no active work on this area, but Mono already provides
    pre-compilation services (Ahead-of-Time compilation).
 
-Q: But would this work around the GPL in the GCC compiler and allow
-   people to work on non-free front-ends?
-
-A: People can already do this by targeting the JVM byte codes (there
-   are about 130 compilers for various languages that target the JVM).
 
 <a name="performance"></a>
 ** Performance
 
 <a name="performance"></a>
 ** Performance
@@ -1288,10 +1391,19 @@ A: We can not predict the future, but a conservative estimate is that
    many new features, and layers suitable for optimization.  It is
    relatively easy to add new optimizations to Mono. 
 
    many new features, and layers suitable for optimization.  It is
    relatively easy to add new optimizations to Mono. 
 
-   The CIL has some advantages over the Java byte code:  it is really
-   an intermediate representation and there are a number of
-   restrictions on how you can emit CIL code that simplify creating
-   better JIT engines.
+   The CIL has some advantages over the Java byte code: The existance
+   of structs in addition to classes helps a lot the performance and
+   minimizes the memory footprint of applications.
+
+   Generics in the CLI world are first-class citizens, they are not
+   just a strong-typing addition to the language.  The generic
+   specifications are embedded into the instruction stream, the JIT
+   uses this information to JIT a unique instances of a method that is
+   optimized for the type arguments.
+
+   The CIL is really an intermediate representation and there are a
+   number of restrictions on how you can emit CIL code that simplify
+   creating better JIT engines.
 
    For example, on the CIL, the stack is not really an abstraction
    available for the code generator to use at will.  Rather, it is a
 
    For example, on the CIL, the stack is not really an abstraction
    available for the code generator to use at will.  Rather, it is a
@@ -1367,7 +1479,7 @@ A: First some background information.
    Microsoft falls under the ECMA/ISO submission.  Jim Miller at
    Microsoft has made a statement on the patents covering ISO/ECMA,
    (he is one of the inventors listed in the patent): <a
    Microsoft falls under the ECMA/ISO submission.  Jim Miller at
    Microsoft has made a statement on the patents covering ISO/ECMA,
    (he is one of the inventors listed in the patent): <a
-   href="https://mailserver.di.unipi.it/pipermail/dotnet-sscli/msg00218.html">here</a>.
+   href="http://web.archive.org/web/20030609164123/http://mailserver.di.unipi.it/pipermail/dotnet-sscli/msg00218.html">here</a>.
 
    Basically a grant is given to anyone who want to implement those
    components for free and for any purpose.
 
    Basically a grant is given to anyone who want to implement those
    components for free and for any purpose.
@@ -1408,6 +1520,51 @@ A: Mono implements both the .NET Framework, as well as plenty of class
 
    <img src="http://primates.ximian.com/~miguel/tmp/map.png">
 
 
    <img src="http://primates.ximian.com/~miguel/tmp/map.png">
 
+<a name="obfuscation"></a>
+** Obfuscation
+
+Q: Are there any obfuscation programs for Mono/Linux?
+
+A: We are not aware of these, but some from Windows might work.
+
+Q: What could I do to avoid people decompiling my program?
+
+A: You can use the bundle functionality in Mono. 
+
+   This would bundle your binary inside a Mono runtime instance, so
+   you distribute a single executable that contains the code inside.
+   Notice that for this to work and be practical, you need to get a
+   commercial license to the Mono runtime.
+
+   The reason is that the bundle functionality is covered by the LGPL:
+   so you would have to distribute your assemblies separatedly to allow
+   developers to relink mono which would defeat the purpose of bundling
+   for obscuring your code.
+
+   It is not impossible to break, just like any other obfuscators.
+
+   That being said, value these days does not lie in particular
+   tiny routines, but lies in the large body of work, and if someone
+   steals your code, you are likely going to find out anyways.
+
+Q: Any other option?
+
+A: You could precompile with --aot your code, then disassemble the
+   original .exe, and remove all the code, then re-assemble and ship
+   both the vessel .exe and the precompiled code.  
+
+   This is not a supported configuration of Mono, and you would be 
+   on your own in terms of dealing with bugs and problems here.
+
+   Get the companies that build the obfuscation packages to read 
+   the ECMA spec and fix the bugs in their products that generate 
+   non-standard binaries (or, if they expose a bug in mono, please
+   file a report in our bugzilla).  
+
+   Pay Ximian/Novell to spend the development time needed to get mono
+   to support the broken binaries that some of the obfuscation
+   packages generate (or contribute that support).
+
 <a name="etc"></a> 
 ** Miscellaneous Questions
 
 <a name="etc"></a> 
 ** Miscellaneous Questions
 
@@ -1494,8 +1651,12 @@ A: It's possible to run VC++ generated apps under Mono, but we do not
 
 Q: Does Mono support generics?.
 
 
 Q: Does Mono support generics?.
 
-A: Mono doesn't support generics currently but a lot of work is being 
-   done towards it.
+A: Yes, the Mono runtime now supports the new Generics extensions, and
+   there is also support for generics in our new compiler: `gmcs'.
+
+   The Mono C# 1.0 compiler (mcs) will ship with various C# 2.0
+   features, but generics will remain on the separate compiler (gmcs)
+   as this code is not as tested as the main compiler.
 
 <a name="problems"></a>
 ** Mono Common Problems
 
 <a name="problems"></a>
 ** Mono Common Problems