Что такое расширение файла mono?

MPM worker

Apache 2.x comes with several processing modules (that is — servers, so-called MPMs for Multi Processing Module) implementing different server models. The one installed by default by most distributions is the MPM which implements the traditional, one OS process per server, model and is the same what in the earlier Apache versions. Another module usually available with your distribution is the MPM. That module implements a mixed process/thread model which spawns several processes as well, but each of them can create a configurable number of service threads. It is advisable to use the MPM with mod_mono. Unfortunately, PHP seems to not necessarily work with the MPM, so you may not be able to go this route.

Configuring Mod_Mono

When AutoHosting does not fit your needs, you will need to include several mod_mono Apache directives in your main Apache configuration file (often /etc/httpd/conf/httpd.conf, or the like in /etc/apache2) to get the site running.

Manual Mod_Mono Configuration

The following assumes you have included mod_mono.conf in your main configuration file as described above. Further, it is important (as of Mono 1.2.5) to place the remaining mod_mono directives after the User and Group directives. They can just go at the end, or inside VirtualHost sections.

A basic setup is as follows (with line numbers added for convenience):

The first line disables the AutoHosting feature. (If inside a VirtualHost section, it disables it just for that virtual host).

The second line instructs Apache that processing of files with .aspx, etc. extensions should be delegated to mod_mono (rather than Apache processing them itself as plain-text files).

The third line instructs mod_mono that an ASP.NET application exists at the root directory of the web site (i.e. at http://www.example.com/), and that this virtual path corresponds to the physical path on disk of /home/username/www. Normally, the physical path will match whatever Apache would map the given virtual path to. So if the virtual path is /, as in this example, the physical path matches what is in the DocumentRoot directive for Apache. This is important because in that virtual path, Apache itself will continue to serve images, static HTML, and other files, based on the physical path it knows in DocumentRoot, while mod_mono will handle files with .aspx, etc. extensions (or whatever was specified in AddHandler) based on the physical path provided in the MonoApplications directive.

Here is another configuration that sets up the ASP.NET test suite that comes with mod_mono.

Let’s say you want those file to be available under the virtual path /test. Edit your httpd.conf file (hint: /etc/httpd, /etc/apache2) and append the following lines (remove the numbers ;-):

Unlike the first example, this example assumes that the virtual path “/test” does not already correspond to the physical path /usr/share/doc/xsp/test. The Alias directive is a standard Apache directive to map a virtual path to a physical path. The second line creates an ASP.NET application in something other than the root virtual path. Lines 3-5 instruct Apache that absolutely all files in the /test virtual path are to be handled by mod_mono. (mod_mono can handle non-ASP.NET pages as well. It will just send other files to the client directly without special processing.)

Now start/restart Apache and browse http://hostname/test/index.aspx (where hostname is the name of the server, or if you’re running Apache locally). If you cannot see the test page, go to the troubleshooting section. Otherwise, welcome to ASP.NET!

Okay, it worked. But, what happened? When you started apache, mod_mono launched mod-mono-server. Later, when you requested any page under /test, mod_mono connected to mod-mono-server, forwarded the request data and retrieved the response that is sent to your browser. Finally, if you stop apache, mod_mono will tell mod-mono-server to die.

It is possible to put these directives inside a VirtualHost section as well.

If your site uses .NET 2.0 classes, you will need to instruct mod_mono to spawn the .NET 2.0 version of mod-mono-server, instead of the default .NET 1.1 version. To do that, use the following, changing the path to mod-mono-server2 as needed:

If you use AddHandler you might want to let mod-mono-server know about your DirectoryIndex directive by doing something like this in your web.config file:

The Components

There are several components that make up Mono:

C# Compiler — Mono’s C# compiler is feature complete for C# 1.0, 2.0, 3.0, 4.0, 5.0 and 6.0 (ECMA). A good description of the feature of the various versions is available on .

Mono Runtime — The runtime implements the ECMA Common Language Infrastructure (CLI). The runtime provides a Just-in-Time (JIT) compiler, an Ahead-of-Time compiler (AOT), a library loader, the garbage collector, a threading system and interoperability functionality.

.NET Framework Class Library — The Mono platform provides a comprehensive set of classes that provide a solid foundation to build applications on. These classes are compatible with Microsoft’s .Net Framework classes.

Mono Class Library — Mono also provides many classes that go above and beyond the Base Class Library provided by Microsoft. These provide additional functionality that are useful, especially in building Linux applications. Some examples are classes for Gtk+, Zip files, LDAP, OpenGL, Cairo, POSIX, etc.

Устранение неполадок при открытии файлов MONO

Общие проблемы с открытием файлов MONO

Monolith не установлен

Дважды щелкнув по файлу MONO вы можете увидеть системное диалоговое окно, в котором сообщается «Не удается открыть этот тип файла». В этом случае обычно это связано с тем, что на вашем компьютере не установлено Monolith для %%os%%. Так как ваша операционная система не знает, что делать с этим файлом, вы не сможете открыть его дважды щелкнув на него.

Совет: Если вам извстна другая программа, которая может открыть файл MONO, вы можете попробовать открыть данный файл, выбрав это приложение из списка возможных программ.

Установлена неправильная версия Monolith

В некоторых случаях у вас может быть более новая (или более старая) версия файла Monolith Munged Encoded Data, не поддерживаемая установленной версией приложения. При отсутствии правильной версии ПО Monolith (или любой из других программ, перечисленных выше), может потребоваться загрузить другую версию ПО или одного из других прикладных программных средств, перечисленных выше. Такая проблема чаще всего возникает при работе в более старой версии прикладного программного средства с файлом, созданным в более новой версии, который старая версия не может распознать.

Совет: Иногда вы можете получить общее представление о версии файла MONO, щелкнув правой кнопкой мыши на файл, а затем выбрав «Свойства» (Windows) или «Получить информацию» (Mac OSX).

Резюме: В любом случае, большинство проблем, возникающих во время открытия файлов MONO, связаны с отсутствием на вашем компьютере установленного правильного прикладного программного средства.

Даже если на вашем компьютере уже установлено Monolith или другое программное обеспечение, связанное с MONO, вы все равно можете столкнуться с проблемами во время открытия файлов Monolith Munged Encoded Data. Если проблемы открытия файлов MONO до сих пор не устранены, возможно, причина кроется в других проблемах, не позволяющих открыть эти файлы. Такие проблемы включают (представлены в порядке от наиболее до наименее распространенных):

Ограничения инструмента MoMA

Инструмент MoMA не сможет обнаружить все проблемы, возникающие при переносе приложения на другую платформу, например, проблемы, связанные с написанием имен файлов и путей к ним.

Для нормальной работы приложения на разных ОС необходимо учитывать регистр при наименовании файлов, так как в Windows регистр не имеет значения при написании имен файлов, в отличие от Linux-систем. Также есть и различия в символе, разделяющем каталоги в пути к файлу. В Windows разделителем является обратная косая черта (\), а в Linux – прямая (/). Чтобы избежать создания разных сборок для разных систем необходимо использовать метод Path.DirectorySeparatorChar.

Есть путь к файлу – ./Res/Img/Img.jpg, в исходном коде его можно представить следующей строкой:

string strFilePath = Application.ExecutablePath + 
  string.Format(“{0}Res{0}Img{0}Img.jpg”, Path.DirectorySeparatorChar);


Can Mono run binaries produced by Visual Studio?

Yes, Mono can run binaries produced by Visual Studio, there is no need to recompile.

Use our Mono Migration Analysis tool to check if everything that your application uses has been implemented in Mono or if there are special considerations to keep in mind.

See our Roadmap for details about what is implemented.

What is Mono exactly?

The Mono Project is an open development initiative sponsored by the .NET Foundation and Microsoft to develop an open source, UNIX version of the Microsoft .NET development platform. Its objective is to enable UNIX developers to build and deploy cross-platform .NET Applications. The project implements various technologies developed by Microsoft that have now been submitted to the ECMA for standardization.

The Mono Project has also sparked a lot of interest in developing C#-based components, libraries and frameworks. The most important ones, some of which were developed by the Mono team, are:

  • Gtk#: Bindings for the popular Gtk+ GUI toolkit for UNIX and Windows systems. Other bindings are available: Diacanvas-Sharp and MrProject.

  • Mono.Cecil: A library to generate and inspect CIL assemblies.

  • #ZipLib: A library to manipulate various kinds of compressed files and archives (Zip and tar).

  • Tao Framework: bindings for OpenGL

  • Mono.Directory.LDAP / Novell.Directory.LDAP: LDAP access for .NET apps.

  • Mono.Data: We ship support for PostgreSQL, MySQL, Firebird, Sybase ASE, IBM DB2, SQLite, Microsoft SQL Server, Oracle, and ODBC data sources.

  • Mono.Cairo: Bindings for the Cairo rendering engine (Our System.Drawing is implemented on top of this).

  • Mono.Posix / Mono.UNIX: Bindings for building POSIX applications using C#.

  • Mono.Remoting.Channels.Unix: Unix socket based remoting

  • Mono.Security: Enhanced security and crypto framework

  • Mono.Math: BigInteger and Prime number generation

  • Mono.Http: Support for creating custom, embedded HTTP servers and common HTTP handlers for your applications.

  • Mono.XML: Extended support for XML

  • Managed.Windows.Forms (aka System.Windows.Forms): A complete and cross platform, System.Drawing based Winforms implementation.

  • Remoting.CORBA: A CORBA implementation for Mono.

  • Ginzu: An implementation on top of Remoting for the ICE stack

For a more complete list, see the Libraries and Software pages.

What technologies are included in Mono?

Mono contains a number of components useful for building new software:

  • A Common Language Infrastructure (CLI) virtual machine that contains a class loader, Just-in-time compiler, and a garbage collecting runtime.

  • A class library that can work with any language which works on the CLR. Both .NET compatible class libraries as well as Mono-provided class libraries are included.

  • A compiler for the C# language. In the future we might work on other compilers that target the Common Language Runtime.

Windows has compilers that target the virtual machine from Managed C++, Java Script, Eiffel, Component Pascal, APL, Cobol, Perl, Python, Scheme, Smalltalk, Standard ML, Haskell, Mercury and Oberon.

The CLR and the Common Type System (CTS) enables applications and libraries to be written in a collection of different languages that target the byte code This means for example that if you define a class to do algebraic manipulation in C#, that class can be reused from any other language that supports the CLI. You could create a class in C#, subclass it in C++ and instantiate it in an Eiffel program. A single object system, threading system, class libraries, and garbage collection system can be shared across all these languages.

Where can I find the specification for these technologies?

You can find the information here:

C# http://www.ecma-international.org/publications/standards/Ecma-334.htm

CLI http://www.ecma-international.org/publications/standards/Ecma-335.htm

Does Mono work today?

Yes, Mono is used in many commercial and open source applications and is used by many companies.

The execution engine works on many platforms (See the detailed list) and the scope of Mono is quite comprehensive. Detailed plans are available in our Plans page.

You can see a list of some Companies Using Mono page.

A number of commercial software products are listed here.

Aren’t you just copying someone else’s work?

We are interested in providing the best tools for programmers to develop applications for Free Operating Systems. We also want to help provide the interoperability that will allow those systems to fit in with other standards.


What architectures and operating systems does Mono support?

See our Supported Platforms page for the complete list.

Although we support plenty of platforms, we do not package Mono in binary form for all of the supported platforms.

My platform is not supported, can Mono support it?

Porting Mono to a new platform has two dimensions:

  • Architecture port: this means porting the code generator used by the JIT to produce native code for a new CPU.
  • Operating system port: this includes porting Mono’s IO-Layer which copes with threading, file I/O and networking as well as porting the garbage collector and exception handling code, which tends to be operating system specific.

Most Unix variants behave very similarly, so porting to a new Unix is relatively simple. Porting to embedded operating systems or new research operating systems are the only places where a new operating system port might be required.

Porting Mono to a new architecture takes about three months of work.

Developing on Windows, running on Unix

You can continue to use Visual Studio to develop your applications on Windows, the binaries produced by Visual Studio are binary compatible with Mono, so you only need to get these files to your Linux/Unix server.

You can do this by either manually copying the files (a directory, using XCopy deployment is probably the easiest), but ideally you would want to have a network share between Unix and Windows:

  • You could mount from Linux, a Windows share.
  • You could mount from Windows, a Linux share.

Important Visual Studio can produce “incremental” executables, these are executables that do not have some of their tables compressed, and they are used by Visual Studio during development.

These assemblies do not work with Mono, as Mono does not support them, you must turn off “incremental” builds.

The incremental option can be set from the Project’s Configuration/Advanced properties.

Интеграция MonoDevelop с Subversion

Для интеграции MonoDevelop с Subversion необходимо расширение monodevelop-versioncontrol. Если это расширение не установлено, то можно загрузить его при помощи команды:

apt-get install monodevelop-versioncontrol

Теперь в контекстном меню, вызываемым при щелчке правой кнопкой мыши по решению в окне Solution, должен появиться пункт Version Control (Система контроля версий) -> Publish (опубликовать).

Рисунок 24. Контекстное меню системы контроля версий

При выборе этого пункта откроется окно с вкладкой Registered Repositories (зарегистрированные репозитории). Для подключения к локальному репозиторию, расположенному в каталоге /home/heaven/subversion, необходимо нажать кнопку Add (Добавить) и настроить параметры репозитория, как показано на рисунке 25.

Рисунок 25. Окно настроек репозитория

Для добавления репозитория необходимо указать имя (Name), протокол (Protocol) и путь (Path) к репозиторию с учетом используемого протокола. После этого необходимо нажать кнопку OK и проверить, что репозиторий добавился без ошибок.

Рисунок 26. Репозиторий успешно добавлен в MonoDevelop IDE

Еще одно нажатие на кнопку OK загрузит решение в репозиторий и после этого в контекстном меню появятся новые команды для операций над исходным кодом.

Рисунок 27. Полный список команд для работы с SVN

Для проверки интеграции с системой контроля версий можно исправить ошибку в коде из листинга 2. Для этого строку:

for(int i=0;i<=5;i++)

необходимо заменить на строку

for(int i=0;i<=4;i++)

Теперь при выборе в контекстном меню пункта Version Control -> Review Changes (Просмотр Изменений) на экран будут выведены различия в коде.

Рисунок 28. Различия в локальном коде и в репозитории

При помощи кнопок вверху открывшегося окна или команд контекстного меню Version Control можно загрузить изменения в репозиторий, откатить их назад или сделать патч (Create Patch) для предыдущей версии кода.

Multiple Applications, Multiple mod-mono-servers

You might want to run different applications in different instances of mod-mono-server. There are a number of reasons for doing this:

  • If you want to run a production and testing environments.
  • You need completely separate Mono instances running.
  • If you don’t want Session or Application level objects to be shared among applications or that you want to set certain memory or CPU usage restrictions for an application.

Let’s see the configuration needed to achieve this separation for the two applications in the previous example. (Alias directives are omitted for brevity, and this example assumes the AddHandler directive has been used to associate ASP.NET file extensions with mod_mono.)

When (Add)MonoApplications is given two arguments, the first argument is understood as a name or alias for a particular instance of the mod-mono-server backend. With this configuration mod_mono will start two instances of mod-mono-server whose aliases are ‘testing’ and ‘personal’. The ‘testing’ instance will handle /test and the ‘personal’ instance will handle /personal.

MonoSetServerAlias tells mod_mono which instance of mod-mono-server will be used to process the requests for this <Location>. It can be used with apache <Directory> too.

The alias used when no alias is provided, as in the earlier examples, is “default”. All of the mod_mono directives below that show an alias as the first argument also can be specified by leaving the alias out, in which case the “default” alias is used.

Серверы, поддерживающие технологию ASP.NET

Основным сервером для запуска ASP.NET-приложений является Microsoft Internet Information Server (IIS), предназначенный исключительно для использования на ОС семейства MS Windows. Однако на платформе Linux существуют не менее мощные Web-серверы, например, возможно, самый известный Web-сервер — Apache. Web-сервер Apache поддерживает расширение функциональности с помощью плагинов. Для совместного использования Apache и Mono был разработан плагин mod_mono, который позволяет использовать ASP.NET на Linux-системах.

Другим вариантом является сервер XSP. XSP — это облегченный Web-сервер, предназначенный для разработки и тестирования Web-приложений. Сервер XSP не рекомендуется использовать для развертывания коммерческих проектов в силу ограниченной функциональности, однако он незаменим в ходе разработки. Web-сервер XSP, написанный на C#, входит в комплект инструментов Mono. С его помощью можно просматривать ASP.NET-страницы непосредственно из среды разработки MonoDevelop в режиме отладки. Если этот Web-cервер не установлен, то его можно установить следующей командой:

sudo apt-get install mono-xsp

Web-сервер Apache можно использовать для развертывания ASP.NET-приложений и без подключения плагина mod_mono, заменив этот плагин на комбинацию плагинов mod_proxy и mod_proxy_http и Web-сервер XSP. Однако такой способ не рекомендуется разработчиками Mono по ряду причин, среди которых снижение быстродействия и тот факт, что Web-сервер XSP не поддерживает все возможности стандарта HTTP 1.1.

Garbage Collection

Mono today uses Boehm’s GC as its Garbage Collection engine. We are also working on a precise and compacting GC engine specific to Mono.

The GC interface is being isolated to allow for more than one GC engine to be used or for the GC to be tuned for specific tasks.

Mono’s use of Boehm GC

We are using the Boehm conservative GC in precise mode.

There are a few areas that the GC scans for pointers to managed objects:

  1. The heap (where other managed objects are allocated)
  2. thread stacks and registers
  3. static data area
  4. data structures allocated by the runtime

(1) is currently handled in mostly precise mode: almost always the GC will only consider memory words that contain only references to the heap, so there is very little chance of pointer misidentification and hence memory retention as a result. The new GC requires a fully precise mode here, so it will improve things marginally. The details about mostly precise have to do with large objects with sparse bitmaps of references and the handling of multiple appdomains safely.

(2) is always scanned conservatively. This will be true for the new GC, too, at least for the first versions, where I’ll have my own share of fun at tracking the bugs that a moving generational GC will expose. Later we’ll conservatively scan only the unmanaged part of the stacks.

(3) We already optimized this both with Boehm and the current GC to work in precise mode.

(4) I already optimized this to work in mostly precise mode (ie some data structures are dealt with precisely, others not yet). I’ll need to do more work in this area, especially for the new GC, where having pinned objects can be a significant source of pain.


  • Garbage collection list and FAQ: http://www.iecc.com/gclist/

  • “A Generational Mostly-concurrent Garbage Collector”:

  • Details on The Microsoft .NET Garbage Collection Implementation:

Tasks remaining

  • Bugfixes
  • New features
    • Diagnostics support, and service trace viewer if possible.
    • Implement 4.0 stuff: see this MSDN article and our status entry in Sep. 2010 for details
      • discovery and announcements i.e. System.ServiceModel.Discovery.dll : ongoing.
      • simplified configurations : only a few remains (activation, file-less configuration etc.)
      • REST enhancements.
  • Improvements
    • Metadata support (WSDL and MEX)
      • improved svcutil work (WsdlImporter). Binding export should in general work now. Endpoint export does not yet.
      • WsdlExporter likely needs better support.
      • mex and policy support. Will be used in security stack.

Components with no plan to support

Items listed here are with no plan to support. Though anyone should feel free to hack and contribute in these areas.

  • ComIntegration.

  • WorkflowServices. we have no plan to work on WF3. There are WF4-based WCF stuff in System.ServiceModel, which is in different story (though no plan for this either).

  • RIA Services. Basically there are Silverlight SDK assemblies that are to be embedded in the app, so we don’t have to bother much.

  • WSHttpBinding and its dependencies
    • TransactionFlow
    • ReliableSession
  • Federation (I’m not sure what it is supposed to do.)
  • Silverlight PollingDuplex binding element.
  • WSDualHttpBinding (post-WSHttpBinding work)
  • MSMQ stack: Msmq bindings and MsmqIntegration.
  • Data Services.
  • Net peer channel improvements.

Known issues

In general, we keep fixing bugs and bugfixes are (very) often not in the latest release yet. Especially, for Mono 2.8, the branching was done much earlier than the actual release, and even if you reported bugs earlier than the release, it is often not fixed in it. The actual fixes would be available in the future release.

Based on the premise above, here I list some known issues and workarounds that we don’t give priority beyond ongoing work.

  • When you host a service that uses NetTcpBinding or CustomBinding with TcpTransportBinding on a ServiceHost and configure the binding (element) as TransferMode = Buffered, it could result in blocking when it receives more than ServiceThrottle.MaxConcurrentSessions or ServiceThrottle.MaxConcurrentCalls at a time. To avoid this issue, give large number for those ServiceThrottle properties.
  • Data Contract Names for Generic Types is not implemented. The reason is, it does not fully explain *exactly* how to compute the hash (hash algorithm, how to concatenate namespace strings, conversion from namespace strings to bytes, and to result string back which must not be base64 as it contains ‘+’ etc.). Since interoperable applications should use explicit xml element names (or do you expose “FooBarxxXxXxxX” in your app?), it is left as is so far.

Static Compiler (AOT)

Made changes to some AOT data structures to reduce their size, especially when using generics. This reduces the size of an mscorlib AOT image by about 1-2%.

Many changes to the class libraries allow more core Generics code to run on systems that do not support JIT compilation.

Installing Mono 3.0

Binary Packages and Source Code Downloads:

Quick source code installation:

Compile libgdiplus to support System.Drawing:

Then compile Mono itself:

Bug Fixes

mdoc update has been fixed so that -fno-assembly-versions and –delete interact properly, and delete XML types and members which do not exist in the target assembly. This allows copying e.g. corlib/Documentation/en, processing en against the Silverlight-profile mscorlib.dll, and removing all types and members which don’t exist in the Silverlight profile.

Xamarin.iOS and Xamarin.Android

Xamarin.iOS и Xamarin.Android, разработанные Xamarin, являются реализациями Mono для iPhone и смартфонов на базе Android. Ранее доступный только для коммерческого лицензирования, после приобретения Microsoft Xamarin в 2016 году, сама среда исполнения Mono была переведена в соответствии с лицензией MIT, и Xamarin.iOS и Xamarin.Android стали бесплатными и открытыми.


Xamarin.iOS (ранее называемая MonoTouch) — это собственная библиотека, которая позволяет разработчикам создавать приложения на базе C # и .NET, которые работают на устройствах iPhone, iPod и iPad. Он основан на структуре Mono и разработан совместно с Novell. В отличие от приложений Mono, Xamarin.iOS «Приложения» скомпилированы до машинного кода, специально предназначенного для Apple iPhone и iPad. Это необходимо, потому что ядро iOS предотвращает выполнение компилятором «точно в срок» на устройстве.

Стек Xamarin.iOS состоит из:

  • Составители:
  • C # из проекта Mono;
  • Сторонние компиляторы, такие как Oxygene от RemObject, могут ориентироваться на Xamarin.iOS также

основные библиотеки .NET;

  • Разработка SDK:
  • Linker — используется для связывания кода, используемого в окончательном приложении;
  • mtouch — собственный компилятор и инструмент, используемый для развертывания на целевом устройстве;
  • Инструменты интеграции интерфейса Builder;
  • Библиотеки, которые связывают родные API CocoaTouch;
  • Xamarin Studio IDE.

Xamarin Studio используется в качестве основной IDE, однако были добавлены дополнительные ссылки на Xcode и iOS-симулятор.

С апреля по начало сентября 2010 года будущее MonoTouch было поставлено под сомнение, поскольку Apple представила новые условия для разработчиков iPhone, которые, по-видимому, запрещают им развиваться на языках, отличных от C, C ++ и Objective-C, и использование среднего уровня между iOS и приложениями для iPhone. Из-за этого будущее MonoTouch и других технологий, таких как Unity, было неопределенным. Затем, в сентябре 2010 года, Apple отменила это ограничение, заявив, что они ослабляют языковые ограничения, которые они установили в начале этого года.


Xamarin.Android (ранее известный как Mono для Android), первоначально разработанный Novell и продолжаемый Xamarin, является частной версией Mono для смартфонов на базе Android. Он был впервые выпущен 6 апреля 2011 года. Mono для Android был разработан, чтобы позволить разработчикам легко писать кросс-платформенные приложения, которые будут работать на всех мобильных платформах. В интервью H-Online Мигель де Иказа заявил: «Наше видение заключается в том, чтобы позволить разработчикам повторно использовать свой код движка и бизнес-логики на всех мобильных платформах и заменять код пользовательского интерфейса для API-интерфейса, специфичного для платформы».

В августе 2010 года представитель Microsoft, Том Ханрахан из Центра технологий с открытым исходным кодом Microsoft, заявил, ссылаясь на иск, поданный Oracle против по поводу использования Android в Java, «Тип действия, которое Oracle использует против Google через Java, не пройдет, если бы .NET-порт для Android проходил через Mono, он попал бы под соглашение об обещании сообщества Microsoft ».

Стек Xamarin.Android состоит из следующих компонентов:

  • Время выполнения Mono;
  • Разработчик пользовательского интерфейса Android;
  • Библиотеки:
  • Основные библиотеки классов .NET;
  • Библиотеки, которые привязывают собственные API для Android / Java;
  • Инструменты SDK для упаковки, развертывания и отладки;
  • Xamarin Studio и Visual Studio 2010 для разработки пользовательского интерфейса, удаленной отладки и развертывания.


NUnit, a Winforms app

SharpChess, a Winforms app

Homepage: Winforms

Windows.Forms is a binding developed by Microsoft to the Win32 toolkit. As a popular toolkit used by millions of Windows developers (especially for internal enterprise applications), the Mono project decided to produce a compatible implementation (Winforms) to allow these developers to easily port their applications to run on Linux and other Mono platforms.

Whereas the .Net implementation is a binding to the Win32 toolkit, the Mono implementation is written in C# to allow it to work on multiple platforms. Most of the Windows.Forms API will work on Mono, however some applications (and especially third party controls) occasionally bypass the API and P/Invoke straight to the Win32 API. These calls will likely have to be changed to work on Mono.

In general, Winforms applications are written using Microsoft’s Visual Studio or SharpDevelop, which both provide a visual designer for creating Winforms GUIs.

Platforms: Windows, Unix, macOS


  • Extensive documentation exists for it (books, tutorials, online documents).
  • Large community of active developers.
  • Easiest route to port an existing Windows.Forms application.


  • Internationalization can be tricky with fixed layouts.
  • Looks alien on non-Windows platforms.
  • Code that calls the Win32 API is not portable.

More on Applications

How do you go about making mod_mono handle several applications? Let’s try the easiest option. You will need this in your httpd.conf:

The significant change is in line 4:

This way you can keep all the configuration related to an application in a separate file (Alias, AddMonoApplications, Location,…).

If you serve mod_mono applications in multiple virtual hosts, you can use this syntax:

The above example instructs mod-mono-server to create two applications, one mapping http://www.example.com/ to /home/exampledotcom/www and the other mapping http://www.sample.com/ to /home/sampledotcom/www.


To make your code run in as many platforms as possible, you might want to keep your code Endian-independent. This means that you should not assume the order of bytes.

See the endianess entry in the Wikipedia for more details.

ASP.NET Guidelines

You might want to familiarize yourself with some of the Frequently Asked Questions about ASP.NET on Mono, they are on this page: FAQ: ASP.NET

Windows.Forms Guidelines

You might want to familiarize yourself with some of the Frequently Asked Questions about running Windows.Forms applications on Mono. The list is on this page: FAQ: Winforms.

Database Migration

You can continue using your SQL Server database with Mono, you do not have to migrate this. But if you want to replace SQL server with another database, Mono provides an extensive set of database connetors for MySQL, PostgreSQL, Sybase, Oracle, IBM DB2, Firebird, ODBC, and also the embedded SQLite database.

Your existing code and connection strings will continue to work. The only change necessary might be to change the hostname for the database.


Banshee, a GTK# app

F-Spot, a GTK# app

Homepage: GtkSharp

GTK# is a .NET binding for the Gtk+ toolkit. The toolkit is written in C for speed and compatibility, while the GTK# binding provides an easy to use, object oriented API for managed use. It is in active development by the Mono project, and there are various real-world applications available that use it (Banshee, F-Spot, Beagle, MonoDevelop).

In general, GTK# applications are written using MonoDevelop, which provides a visual designer for creating GTK# GUIs.

Platforms: Unix, Windows, macOS


  • Good support for accessibility through its Gtk+ heritage.
  • Layout engine ideal for handling internationalized environments, and adapts to font-size without breaking applications.
  • Applications integrate with the Gnome Desktop.
  • API is familiar to Gtk+ developers.
  • Large Gtk+ community.
  • A Win32 port is available, with native look on Windows XP.
  • The API is fairly stable at this point, and syntactic sugar is being added to improve it.
  • Unicode support is exceptional.


  • Gtk+ apps run like foreign applications on macOS.
  • Incomplete documentation.
Оцените статью
Рейтинг автора
Материал подготовил
Андрей Измаилов
Наш эксперт
Написано статей
Добавить комментарий