-
Notifications
You must be signed in to change notification settings - Fork 346
Building
Visual Studio |
Command line |
Mono |
Tips |
- Start Visual Studio 2010.
- Open
-
c:\path\to\Solutions\Ruby.sln
solution file if you want to build/work on IronRuby, -
c:\path\to\Solutions\IronPython.sln
solution file if you want to build/work on IronPython, or -
c:\path\to\Solutions\IronStudio.sln
if you want to build IronRuby and IronPython Tools for Visual Studio.
-
- Press “F6” to build the solution.
Note for VS Express users: you may see warnings about mscorlib
or System
not being found when using VS Express; just ignore those as it doesn’t seem to handle conditional references for Silverlight. However, this means that Silverlight builds won’t work from the IDE. If you absolutely need to build from the IDE, run this script to transform the csproj files to work in VS Express. Otherwise, see the section below about building from the command line.
If you want to launch a Visual Studio instance that loads IronRuby or IronPython Tools that you’ve just built follow these steps:
- Select IronRubyTools or IronPythonTools project as a “startup project” (doesn’t matter which one, either of them launches VS with both languages enabled).
- Open Properties page of the selected project (Alt+Enter or from context menu).
- In Debug tab select “Start external program” as the Start Action and enter the path to devenv.exe, something like
C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe
. - Type
/rootsuffix Exp
to the Command line arguments textbox. This makes the VS use a separate registry hive for all its settings. If something goes wrong with the integration code your main VS installation remains intact. - Hit Ctrl+F5 to launch the VS or F5 if you want to attach a debugger right away. Note that the debugger loads lots of symbols for VS when you attach it so it’s gonna take a while.
Change the working directory to c:\path\to\Solutions and run one of the following commands:
msbuild Ruby.sln /p:Configuration=Debug
produces a debug build for .NET Framework 4.0,
msbuild Ruby.sln /p:Configuration=Release
produces a release build for .NET Framework 4.0,
msbuild Solutions\Ruby.sln /p:Configuration=Silverlight4Debug
produces a debug build for Silverlight 4,
msbuild Ruby.sln /p:Configuration=Silverlight4Release
produces a release build for Silverlight 4,
msbuild Ruby.sln /p:Configuration=Silverlight3Debug
produces a debug build for Silverlight 3, which is what you need for Windows Phone 7,
msbuild Ruby.sln /p:Configuration=Silverlight3Release
produces a release build for Silverlight 3/WP7,
If the build is successful the binaries are stored in C:\path\to\bin\{ConfigurationName}
The same commands applied on IronPython.sln build flavors of IronPython.
You can find an alias defined in Alias.txt for most of these commands.
Change the working directory to c:\path\to\Msi and run the following command:
msbuild Installer.proj /p:Configuration=Release
You’ll find both .msi files in C:\path\to\bin\Release directory if the build is successful.
Instructions for building on Mono:
Your best choice is to install the latest Mono release, you can find instructions and downloads on the mono page .
If you prefer to build mono yourself you can find building instructions for different OS on the mono page .
git clone github.com/IronLanguages/main.git ironlangs cd ironlangs
The steps for the build are:
xbuild /p:Configuration=Release Solutions/Ruby.sln
Commands are deployed to the ~/bin/Release directory.
You can run it with Mono
mono ir.exe
- Make sure .NET 4.0 is installed on your machine.
- Make sure that csc.exe is in your PATH environment variable. Default location is:
c:\Windows\Microsoft.NET\Framework\v4.0.30319