开发者

c# problem in linux

I want to know how I can use c# in Ubuntu 10.04?

I just want to run some program written in c# and compile them on Ubuntu. Can any body tell me how to do this ?

On my Windows system it's quite easy: I just install visual studio, I write the program i开发者_如何学运维n notepad and run it at the command prompt.

Can anybody tell me what should I do to get c# working on my Ubuntu system?

How to install c# in ubuntu?

How to run c# program in ubuntu?


$ sudo apt-get install mono monodevelop monodoc

You need not use monodevelop (although it is actually very good). After installing the above you can edit .cs source files in whatever editor you like ( gedit, vim, emacs ) and then compile sources by hand using the mono compiler ( gmcs is the mono equivalent of csc ).

I'd suggest you take a good look at monodevelop though as you have to manage things like your library dependencies. Hand writing Makefiles or autoconf isn't fun and isn't portable. Monodevelop lets you define normal .sln and .csproj files and optionally generate Makefiles.


you have to use mono for that

http://www.mono-project.com/DistroPackages/Ubuntu


You dont install C#... you install .NET CLR and C# compilers ... anyway

MONO is a .NET implementation that can run on many OSs including Ubuntu

To run .NET apps just install MONO http://www.mono-project.com/

Or MonoDevelop if you need a .Net Development environment on linux http://monodevelop.com/


With mono installed (see other answers)

(substitute favorite $EDITOR)

$EDITOR mytest.cs

# edit, save
gmcs mytest.cs

mono ./mytest.exe

Most distributions will allow you to jyst say ./mytest.exe instead of mono ./mytest.exe

This assumes .NET 3.5 targeting


You have to install Mono for ubuntu to be compatible with .Net framework.
You could start here : click


First you need to download & install MonoDev. http://monodevelop.com/

It sounds like your making console app, so just run the program in the terminal.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜