[Geoserver-devel] errors on 'mvn compile', regardless wheather tag 1.5.0 or 1.5.x head

Hello, I'm following instructions from
http://docs.codehaus.org/display/GEOSDOC/Developers+Guide
to build Geoserver from source.
First I tried
https://svn.codehaus.org/geoserver/branches/1.5.x
Compilation failed - Geoserver references version "2.3.2-SNAPSHOT" of
geotools, but this version doesn't occur at
http://maven.geotools.fr/repository. (There is 2.3.1-SNAPSHOT and
2.4.0-SNAPSHOT.)

Then I tried
https://svn.codehaus.org/geoserver/tags/1.5.0
as well. Again compilation failed, because of

[WARNING] POM for 'org.geotools:gt2-api:pom:2.4-SNAPSHOT:compile' is
invalid. It will be ignored for artifact
resolution. Reason: Failed to validate POM

A little research showed that org.geotools:gt2-api:pom:2.4-SNAPSHOT expects
its parent pom to set the required version of its dependencies
javax.media:jai_core,jai_codec,jai_imageio. Making a qualified guess and
adding the missing declarations to org.geotools:gt2:pom:2.4-SNAPSHOT only
revealed other compilation problems, so I gave up.

Eventually I tried
http://downloads.sourceforge.net/geoserver/geoserver-1.5.0-src.zip
There were still problems (modul "maven" is missing, I just removed the
reference; missing dependencies), that I could solve. But still it bothers
me that clearly this source package is not what has been used to build the
corresponding binary package (The "maven" subdirectory may have been removed
for some reason. But that doesn't explain the missing dependencies in
various .pom files).

Please, can someone explain to me how to build the current stable Geoserver
from the source code repository ?
--
View this message in context: http://www.nabble.com/errors-on-'mvn-compile'%2C-regardless-wheather-tag-1.5.0-or-1.5.x-head-tf3763621.html#a10638761
Sent from the GeoServer - Dev mailing list archive at Nabble.com.

Kay_Schubert ha scritto:

Hello, I'm following instructions from
http://docs.codehaus.org/display/GEOSDOC/Developers+Guide
to build Geoserver from source.
First I tried
https://svn.codehaus.org/geoserver/branches/1.5.x
Compilation failed - Geoserver references version "2.3.2-SNAPSHOT" of
geotools, but this version doesn't occur at
http://maven.geotools.fr/repository. (There is 2.3.1-SNAPSHOT and
2.4.0-SNAPSHOT.)

Then I tried
https://svn.codehaus.org/geoserver/tags/1.5.0
as well. Again compilation failed, because of

[WARNING] POM for 'org.geotools:gt2-api:pom:2.4-SNAPSHOT:compile' is
invalid. It will be ignored for artifact
resolution. Reason: Failed to validate POM

A little research showed that org.geotools:gt2-api:pom:2.4-SNAPSHOT expects
its parent pom to set the required version of its dependencies
javax.media:jai_core,jai_codec,jai_imageio. Making a qualified guess and
adding the missing declarations to org.geotools:gt2:pom:2.4-SNAPSHOT only
revealed other compilation problems, so I gave up.

Eventually I tried
http://downloads.sourceforge.net/geoserver/geoserver-1.5.0-src.zip
There were still problems (modul "maven" is missing, I just removed the
reference; missing dependencies), that I could solve. But still it bothers
me that clearly this source package is not what has been used to build the
corresponding binary package (The "maven" subdirectory may have been removed
for some reason. But that doesn't explain the missing dependencies in
various .pom files).

Well, it's the other way around... it's the build that makes up the source packages, not the opposite. That is, there's a special maven
target to create the source for distribution.
I guess we have to update the build to include some more stuff, and
add a step to the release process in order to check it's possible
to build from the source packages as well.

Please, can someone explain to me how to build the current stable Geoserver
from the source code repository ?

Each Geoserver branch tracks a Geotools branch.
Jars from the geotools branches we do use should be published on lists.refractions.net, but apparently they are not.... have to
check what's going on.

In the meantime, if you want to go on, check out the 2.3.x branch
of geotools and build it, you should be gold then.

Let me know how it goes
Cheers
Andrea

It went smooth - thank you.
In geotools was a small glitch. In 2.3.x/module/referencing/pom.xml there
are missing dependencies, I inserted

<dependency>
        <groupId>javax.media</groupId>
        <artifactId>jai_core</artifactId>
    <version>1.1.3</version>
    </dependency>
    <dependency>
       <groupId>javax.media</groupId>
        <artifactId>jai_codec</artifactId>
    <version>1.1.3</version>
    </dependency>
    <dependency>
        <groupId>javax.media</groupId>
        <artifactId>jai_imageio</artifactId>
    <version>1.1</version>
    </dependency>

It compiled and installed without errors, I skipped the tests however.

aaime wrote:

...
In the meantime, if you want to go on, check out the 2.3.x branch
of geotools and build it, you should be gold then.

Let me know how it goes
Cheers
Andrea

--
View this message in context: http://www.nabble.com/errors-on-'mvn-compile'%2C-regardless-wheather-tag-1.5.0-or-1.5.x-head-tf3763621.html#a10717956
Sent from the GeoServer - Dev mailing list archive at Nabble.com.

Kay_Schubert ha scritto:

It went smooth - thank you.
In geotools was a small glitch. In 2.3.x/module/referencing/pom.xml there
are missing dependencies, I inserted

<dependency>
        <groupId>javax.media</groupId>
        <artifactId>jai_core</artifactId>
    <version>1.1.3</version>
    </dependency>
    <dependency>
       <groupId>javax.media</groupId>
        <artifactId>jai_codec</artifactId>
    <version>1.1.3</version>
    </dependency>
    <dependency>
        <groupId>javax.media</groupId>
        <artifactId>jai_imageio</artifactId>
    <version>1.1</version>
    </dependency>

It compiled and installed without errors, I skipped the tests however.

Hem, not really missing dependencies.
Up to a few weeks ago, you were supposed to have JAI and JAI
image i/o properly installed on your system in order to compile
gt2. That's still the rule for 2.3.x, only trunk has changed.

Cheers
Andrea