Home Games Technology Movies Retro

Tuesday, August 5, 2008

Porting linux work on the mac

Since I make my living as a programmer, being able to do some of the devlopment in Mac OS X was always a pleasure for me. Unfortunately the main project I work on requires Linux. Not that I do not love my linux box but I would like to be able to take work on the road on my Macbook Pro.

Yesterday I tried to port everything to Mac OS X to be able to develop for work while on the road. The project requires the jboss application server, liferay portal engine, postgres database and sun's wireless toolkit for j2me development. I do my Java coding on Eclipse so I had to install that as well.

I begun with postgres. I fiddled with macports to get it to work but I 've found a very nice project for postgres on Mac OS X and I used that instead. Very easy installation. It provides tools as well for client and server. I deployed the jboss with the liferay on it and it run almost out of he box with some very minor issues. It is all Java anyway so why wouldn't it work. Jboss started in 57 seconds on the macbook pro with everything deployed on it. Very-very fast.

The last bit proved to be a disaster though. Sun does not provide a wireless toolkit for the mac platform. That is really a shame. I tried to hack my way to a working, or almost working, solution using the wireless toolkit for Linux on the mac. I installed Eclipse on the MBP and then the EclipseMe plugin to work with the j2me libraries. I installed the wireless toolkit for linux on the mac and then I tried to make the EclipseMe plugin to see the emulated devices from the wireless toolkit. No luck there.

I tried to open the wtk ktoolbar application but it threw some exceptions. I fiddled around with it some more to get it to half-work. When I managed to get it to open (without being able to get the emulator to work though), I tried getting EclipseMe see the devices again. Success! Well almost because I am able to use the libraries from Eclipse, but I am not able to run the emulator. Oh well at least I got some dependencies problems out of the way and I can work on half the project.

Any how, Why the hell hasn't Sun all these years released a Mac WTK. It is beyond me. Even to get half of it working it took me many hours trying BSD JVM alternatives and other crazy stuff and still I do not have a working solution. Having looked on the internet as well, I have not found a a solution to this problem. There are alternatives but that would break the compatibility with me and other guys working from WTK from Linux. I think I will leave it be for the time being.

No comments: