[osmosis-dev] Postgis is in repo1.maven.org
Brett Henderson
brett at bretth.com
Fri Dec 11 02:02:05 GMT 2009
>
> [ivy:resolve]
> http://repo1.maven.org/maven2/org/postgis/postgis/1.3.2/postgis-1.3.2.pom
> [ivy:resolve] -- artifact org.postgis#postgis;1.3.2!postgis.jar:
> [ivy:resolve]
> http://repo1.maven.org/maven2/org/postgis/postgis/1.3.2/postgis-1.3.2.jar
> [ivy:resolve] ::::::::::::::::::::::::::::::::::::::::::::::
> [ivy:resolve] :: UNRESOLVED DEPENDENCIES ::
> [ivy:resolve] ::::::::::::::::::::::::::::::::::::::::::::::
> [ivy:resolve] :: org.postgis#postgis;1.3.2: not found
> [ivy:resolve] ::::::::::::::::::::::::::::::::::::::::::::::
> [ivy:resolve]
> [ivy:resolve] :: USE VERBOSE OR DEBUG MESSAGE LEVEL FOR MORE DETAILS
>
> BUILD FAILED
> /home/mapnik/osmosis/build-ivy.xml:56: impossible to resolve dependencies:
> resolve failed - see output for details
>
Okay, the postgis library has a different name on the public repo.
I've tried updating the ivy dependency descriptor as follows (note addition
of "-jdbc" in the name):
<dependency org="org.postgis" name="postgis-jdbc" rev="1.3.2"
conf="compile->default"/>
This doesn't work for a couple of reasons.
1. It also pulls in a postgis-stubs module. I don't know what the purpose
of this is but it breaks all PostgreSQL functionality. Presumably it stubs
out the PGConnection object for some reason, but I don't know why the
postgis-jdbc pom includes it as a transitive dependency.
2. The postgis jdbc extensions aren't registered. This breaks classes such
as PGGeometry such that any PostGIS functionality breaks (ie. --pgsql-*
tasks).
I can work around problem 1 by excluding postgis-stubs explicitly. It works
well enough. I suspect this stubs jar should only be part of test scope or
somesuch but I could be wrong.
<dependency org="org.postgis" name="postgis-jdbc" rev="1.3.2"
conf="compile->default">
<exclude module="postgis-stubs"/>
</dependency>
However it doesn't solve the postgis extensions not being registered. I've
compared the original postgis.jar with the new postgis-jdbc.jar and there is
one key difference. The file org/postgresql/driverconfig.properties is
missing in the postgis-jdbc.jar.
Hakan, I assume you produced this jar yourself using your own maven setup?
Are you able to fix it to include this missing file? Or is there another
dependency I need to include in order to get this file from somewhere else?
When I get a chance I'll revert the delete of postgis jar from the local
repo and use that until the public one works.
Brett
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/osmosis-dev/attachments/20091211/3d9ec52f/attachment.html>
More information about the osmosis-dev
mailing list