- Code: Select all
$ mono --version
Mono JIT compiler version 2.10.2 (tarball Mon Apr 18 09:14:01 MDT 2011)
$ dmcs
error CS2008: No files to compile were specified
$ cd CobraWorkspace
$ svn up
$ cd Source
$ sudo ./bin/install-from-workspace -native-compiler:`which dmcs`
Note that the install-from-workspace script has a "Clean up workspace" task at the end that rebuilds the compiler in your workspace with debugging symbols, but fails to pass the extra args on (-native-compiler).
If you don't want to install, or if you want to get your workspace on .NET 4.0 after an install:
- Code: Select all
$ ./bin/build -native-compiler:`which dmcs`
$ monodis --assemblyref cobra.exe
AssemblyRef Table
1: Version=4.0.0.0
Name=mscorlib
Flags=0x00000000
Public Key:
0x00000000: B7 7A 5C 56 19 34 E0 89
2: Version=4.0.0.0
Name=System
Flags=0x00000000
Public Key:
0x00000000: B7 7A 5C 56 19 34 E0 89
$ cobra -d -bsl
$ monodis --assemblyref Cobra.Lang.dll
# reports ... 4.0.0.0 ...
$ cobra hello
Hello, world.
$ monodis --assemblyref hello.exe
# reports ... 4.0.0.0 ...
# if you want to build Cobra.Lang.Compiler.dll:
$ ./bin/build-compiler-lib -v -native-compiler:`which dmcs`
This needs more testing. If you have questions or problems, speak up.
I'll work on Windows soon.
For your reference:
* http://stackoverflow.com/questions/2673234/net-4-0-new-methods-in-existing-classes
* What's New in the .NET Framework 4