Angel \”Java\” Lopez on Blog

October 9, 2010

Running AjGenesis using Mono and Ubuntu

Filed under: .NET, AjGenesis, Code Generation, Mono, Ubuntu — ajlopez @ 8:52 am

In these days, I am involved in the developing of a new version (complete rewriting) of a Java application, with a web interface. It is a team effort, and the majority of the members are Ubuntu fans: there are more proficient working in Linux boxes. The project has code generation using (make an educated guess.. ;-) AjGenesis, my open source code generation project. Then, the team want to run AjGenesis out of Windows.

AjGenesis is written in VB.NET, and compiled for .NET 2.0. I was afraid that I should make some change to run it under Ubuntu using Mono project. But I was wrong. Ubuntu has  Mono pre-installed. But AjGenesis use VB.NET runtime. Well, Mono has a VB.NET compiler. I launched the terminal in my Ubuntu ( in Virtual Box over Windows 2008), and executed:

sudo apt-get install mono-vbnc

(I guess this step is needed, but I didn’t try to run AjGenesis with only Mono installed).

Then, I downloaded the AjGenesis compiled binaries (from source trunk). And some examples, like AppExampleStep06.zip (described in Building an Application using AjGenesis (Part 6)).

You can run AjGenesis.Console.exe using

mono AjGenesis.Console.exe

But I marked it as executable:

chmod +xr- AjGenesis.Console.exe

so you can run it directly:

The Build folder was created! Nice!

After this first experiment, I got the source code of the project using subversion, and run the code generation script. The only gotchats were some tasks, written in AjBasic, that were creating directories in lower case and using them with one upper case letter. I fixed the bug, and now, the code generation is running. Team members are able to develop in Windows and Ubuntu, using Java, Tomcat, Maven, and AjGenesis.

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

The Shocking Blue Green Theme. Blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.

Join 57 other followers