PJUG – the first contact [part 2] Ubuntu env. setup for Matlab JavaEE
I’m back again as I have promised in my last post. Today i’m gonna show how to setup your Ubuntu 9.04 operating system and Tomcat 6.x for your Matlab JavaEE application development. I hope you are ready. Let’s start with … !
During my googling time I didn’t search any blogpost focused on that topic even from Windows. That was little bit surprise to me. I found only several nice examples which were only on image. No describtion how deploy them. So my enviroin ment setup became to be more chanlenging to me.
I expected you have installed you IDE correctly so I’m skipping this and I start:
- Install JDK 1.6 or higher as it’s recommended
- Install Matlab 2009b to your $MATLABROOT folder
- Setup properly you environment properties. They have to be linked with your Matlab because you will need them for your application compilation. You may set up them to your .bashrc using for example gedit. It’s up to you. You have to setup these variables $LD_LIBRARY_PATH and $XAPPLRESDIR. Here is a help what to specify:
# XAPPLRESDIR access to Matlab graphical functions as plot, figure
- Next task is to install Tomcat 6.x. I have used it from Ubuntu repository. Then you should link it with your IDE but I guess it’s simple task for you as you are familiar with.
- Very important point connected with Tomcat 6.x usage for Matlab JavaEE applications deployment is to do change in <TOMCAT FOLDER>/conf/context.xml. Just after tag <Context> place following tag with properties <Loader delegate=”true”/>
This is problem caused by org.apache.AnnotationProcessor due to efforts from MYFACES-1246. The statement makes classloading in Tomcat sticking to JavaEE specification. This bug was really stupid.