Page 1 of 1

Compiling source using Eclipse 3.2 + Maven 2

PostPosted: Fri Nov 09, 2007 7:32 pm
by mars96
Hi!

I have a problem compiling subsonic 3.2 with Eclipse 3.2 and Maven2.
I've downloaded the sources, let Maven download the needed files and added some files manually when Maven wasn't able to download them (jdic and jgoodies looks/forms).

Now I want to build/compile/package the project but this doesn't work.
I think it's because the subsonic author is using IDEA as IDE and not Eclipse.
There is a special "maven-idea-plugin" section in the main pom.xml file.

Who has a solution?

EDIT: I think I got it. It works when I run it from the commandline... mvn compiler:compile


Background why I want to compile the source again:

I want to backport Subsonic to an older Java Version (1.4). I have a target platform where no Java 1.5 or greater is available.

Thanks!

PostPosted: Sat Nov 10, 2007 6:50 am
by sindre_mehus
Hi,

To generate the Eclipse project configuration run:
Code: Select all
mvn eclipse:eclipse


BTW, you don't need to download any 3rd party libraries. The ones that are not in the central Maven repository are located in the "repo" dir.

Good luck,
Sindre

Mac Compile

PostPosted: Mon Nov 12, 2007 4:30 pm
by crisbtreets
I tried compiling the 3.2 tag over the weekend on my Mac (mvn compile) and I am getting a failure in the subsonic-installer because the nsis.home is set to c:/Program Files/NSIS. Is there a way to ignore the installer when building?

PostPosted: Tue Nov 13, 2007 2:30 pm
by sindre_mehus
I think the easiest way is to comment out this line in the top-level pom.xml:

Code: Select all
<module>subsonic-installer</module>


Sindre

PostPosted: Tue Nov 13, 2007 6:58 pm
by crisbtreets
That worked. Maven install works.

The eclipse project files don't work. All of the jars are not in the same directory as the ".classpath" file suggests. I had to manually change each one to the correct absolute path. Eclipse complies now.