Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-11 Thread Brett Henderson
On Wed, Nov 11, 2009 at 10:52 PM,  wrote:

> On Wed, 11 Nov 2009 22:37:27 +1100, Brett Henderson 
> wrote:
> >> http://ant.apache.org/manual/CoreTasks/jar.html
> >> That would be the  sub-element.
> >>
> >
> > Unless I'm misunderstanding the attribute element that's not quite what I
> > meant.
> >
> > I already have the following snippet in build.xml.
> > 
> >  > value="org.openstreetmap.osmosis.core.Osmosis"/>
> > 
> > 
> >  > value="${project.version} (${TODAY})"/>
> > 
> > 
> >
> > I could add a classpath element, but I don't know how to add it
> dynamically
> > so that I don't have to hard code the list of jars.
>
>
> I haven't tried it but this could do the trick:
>
>
> http://stackoverflow.com/questions/1456852/ant-commands-to-print-fileset-into-a-file-one-match-per-line
>
> 
>
> 
> 
> 
>  value="org.openstreetmap.osmosis.core.Osmosis"/>
> 
> 
>  value="${project.version} (${TODAY})"/>
> 
>  
> 
>
> Now how to change ";" into ":" in ${jars}
> But maybe it works anyway.
>

Okay, cool.  I'll try it out when I get a chance.
___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-11 Thread marcus.wolschon
On Wed, 11 Nov 2009 22:37:27 +1100, Brett Henderson 
wrote:
>> http://ant.apache.org/manual/CoreTasks/jar.html
>> That would be the  sub-element.
>>
> 
> Unless I'm misunderstanding the attribute element that's not quite what I
> meant.
> 
> I already have the following snippet in build.xml.
> 
>  value="org.openstreetmap.osmosis.core.Osmosis"/>
> 
> 
>  value="${project.version} (${TODAY})"/>
> 
> 
> 
> I could add a classpath element, but I don't know how to add it
dynamically
> so that I don't have to hard code the list of jars.


I haven't tried it but this could do the trick:

http://stackoverflow.com/questions/1456852/ant-commands-to-print-fileset-into-a-file-one-match-per-line






 
 
 
 
 
 
 

Now how to change ";" into ":" in ${jars}
But maybe it works anyway.

Marcus

___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-11 Thread Brett Henderson
On Wed, Nov 11, 2009 at 4:03 PM, Marcus Wolschon <
marcus.wolsc...@googlemail.com> wrote:

> On Tue, Nov 10, 2009 at 11:03 PM, Brett Henderson 
> wrote:
>
> >>> Changing osmosis.bat is not the problem but how can I do an entry
> > Does
> > anybody know how to build a classpath list based on the jars contained in
> a
> > directory within ant?
>
> http://ant.apache.org/manual/CoreTasks/jar.html
> That would be the  sub-element.
>

Unless I'm misunderstanding the attribute element that's not quite what I
meant.

I already have the following snippet in build.xml.








I could add a classpath element, but I don't know how to add it dynamically
so that I don't have to hard code the list of jars.
___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-10 Thread Marcus Wolschon
On Tue, Nov 10, 2009 at 11:03 PM, Brett Henderson  wrote:

>>> Changing osmosis.bat is not the problem but how can I do an entry
> Does
> anybody know how to build a classpath list based on the jars contained in a
> directory within ant?

http://ant.apache.org/manual/CoreTasks/jar.html
That would be the  sub-element.

Marcus

___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-10 Thread Kai Behncke
Thank you very much!!!

It works by implementing the jpf-1.5.jar and the bzip2-20090327.jar


like that:

SET EXEC=%JAVACMD% %JAVACMD_OPTIONS% -cp 
%MYAPP_HOME%\osmosis.jar;%MYAPP_HOME%\lib\default\bzip2-20090327.jar;%MYAPP_HOME%\lib\default\jpf-1.5.jar;%MYAPP_HOME%\lib\commons-logging.jar;%MYAPP_HOME%\lib\mysql-connector-java-5.0.7-bin.jar;%MYAPP_HOME%\lib\postgresql-8.3-603.jdbc4.jar;%MYAPP_HOME%\lib\postgis_1.3.2.jar
 %MAINCLASS% %OSMOSIS_OPTIONS% %*



Best regards, Kai
 Original-Nachricht 
> Datum: Tue, 10 Nov 2009 12:38:17 +0100
> Von: marcus.wolsc...@googlemail.com
> An: Kai Behncke 
> CC: osmosis-dev@openstreetmap.org
> Betreff: Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

> On Tue, 10 Nov 2009 12:36:32 +0100, "Kai Behncke" 
> wrote:
> > Hi Marcus,
> > 
> >> Changing the .bat will be enough to make it work.
> >> 
> > I hoped it would be but in my case it does not work.
> > 
> > I did:
> > 
> > 
> > ---
> >
> %MYAPP_HOME%\osmosis.jar;%MYAPP_HOME\lib\test\jpf-1.5.jar;%MYAPP_HOME%\lib\commons-logging.jar;%MYAPP_HOME%\lib\mysql-connector-java-5.0.7-bin.jar;%MYAPP_HOME%\lib\postgresql-8.3-603.jdbc4.jar;%MYAPP_HOME%\lib\postgis_1.3.2.jar
> > %MAINCLASS% %OSMOSIS_OPTIONS% %*
> 
> 
> "%MYAPP_HOME%\lib\test\jpf-1.5.jar", not
> "%MYAPP_HOME\lib\test\jpf-1.5.jar"
> 
> Marcus

-- 
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01

___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-10 Thread marcus.wolschon
On Tue, 10 Nov 2009 12:36:32 +0100, "Kai Behncke" 
wrote:
> Hi Marcus,
> 
>> Changing the .bat will be enough to make it work.
>> 
> I hoped it would be but in my case it does not work.
> 
> I did:
> 
> 
> ---
>
%MYAPP_HOME%\osmosis.jar;%MYAPP_HOME\lib\test\jpf-1.5.jar;%MYAPP_HOME%\lib\commons-logging.jar;%MYAPP_HOME%\lib\mysql-connector-java-5.0.7-bin.jar;%MYAPP_HOME%\lib\postgresql-8.3-603.jdbc4.jar;%MYAPP_HOME%\lib\postgis_1.3.2.jar
> %MAINCLASS% %OSMOSIS_OPTIONS% %*


"%MYAPP_HOME%\lib\test\jpf-1.5.jar", not "%MYAPP_HOME\lib\test\jpf-1.5.jar"

Marcus

___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-10 Thread Kai Behncke
Hi Marcus,

> Changing the .bat will be enough to make it work.
> 
I hoped it would be but in my case it does not work.

I did:


---
REM MAINCLASS=org.openstreetmap.osmosis.core.Osmosis
REM EXEC="$JAVACMD -cp 
$MYAPP_HOME/osmosis.jar:$MYAPP_HOME/lib/test/jpf-1.5.jar:osmosis.jar:$MYAPP_HOME/lib/mysql-connector-java-5.0.7-bin.jar:$MYAPP_HOME/lib/postgresql-8.3-603.jdbc4.jar:$MYAPP_HOME/lib/postgis_1.3.2.jar
 $MAINCLASS $@"
REM
REM #echo $EXEC
REM exec $EXEC
set MAINCLASS=org.openstreetmap.osmosis.core.Osmosis

SET EXEC=%JAVACMD% %JAVACMD_OPTIONS% -cp 
%MYAPP_HOME%\osmosis.jar;%MYAPP_HOME\lib\test\jpf-1.5.jar;%MYAPP_HOME%\lib\commons-logging.jar;%MYAPP_HOME%\lib\mysql-connector-java-5.0.7-bin.jar;%MYAPP_HOME%\lib\postgresql-8.3-603.jdbc4.jar;%MYAPP_HOME%\lib\postgis_1.3.2.jar
 %MAINCLASS% %OSMOSIS_OPTIONS% %*

%EXEC%
-
...in the osmosis.bat

Then I tried:


E:\osmosis\bin>osmosis --read-xml 
E:/gis_customizing_09/niedersachsen_osm/niedersachsen.osm --bb left=7.917 
right=8.1694
 top=52.3537 bottom=52.217 --write-xml 
E:/gis_customizing_09/niedersachsen_osm/osnabrueck3.osm

and I get:

Usage: java [-options] class [args...
   (to execute a class)
   or  java [-options] -jar jarfile [
   (to execute a jar file)

If I try:
E:\osmosis>java -jar osmosis.jar --read-xml 
E:/gis_customizing_09/niedersachsen_osm/niedersachsen.osm --bb lef
ght=8.1694 top=52.3537 bottom=52.217 --write-xml 
E:/gis_customizing_09/niedersachsen_osm/osnabrueck3.osm


.then I still get:

10.11.2009 12:08:26 org.openstreetmap.osmosis.core.Osmosis run
INFO: Osmosis Version 0.31
10.11.2009 12:08:26 org.openstreetmap.osmosis.core.Osmosis main
SCHWERWIEGEND: Execution aborted.
java.lang.NoClassDefFoundError: org/java/plugin/PluginLifecycleException
at org.openstreetmap.osmosis.core.Osmosis.run(Osmosis.java:73)
at org.openstreetmap.osmosis.core.Osmosis.main(Osmosis.java:30)
Caused by: java.lang.ClassNotFoundException: 
org.java.plugin.PluginLifecycleException
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)


Did it work in your case?
Do I need a special Java-Version maybe?

Thank you very much, Kai
-- 
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3.5 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser

___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-10 Thread marcus.wolschon
On Tue, 10 Nov 2009 12:24:12 +0100, "Kai Behncke" 
wrote:
> Dear Marcus,
> 
> 
> thank you very much (and sorry for crossposting :-) ).
> 
>> osmosis.bat /bin/osmosis both seem to be missing lib/test/jpf-1.5.jar in
>> -cp
>> and osmosis.jar is missing a "class-path: " -entry in it's manifest to
>> require these jar-files if run as "java -jar osmosis.jar".
>> 
> Changing osmosis.bat is not the problem but how can I do an entry 
> "class-path: " in it`s manifest (I never worked with Java before)?

Changing the .bat will be enough to make it work.

The manifest is something for Brett to do to make this
easier for people.

Marcus

___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-10 Thread Kai Behncke
Dear Marcus,


thank you very much (and sorry for crossposting :-) ).

> osmosis.bat /bin/osmosis both seem to be missing lib/test/jpf-1.5.jar in
> -cp
> and osmosis.jar is missing a "class-path: " -entry in it's manifest to
> require these jar-files if run as "java -jar osmosis.jar".
> 
Changing osmosis.bat is not the problem but how can I do an entry 
"class-path: " in it`s manifest (I never worked with Java before)?

Thank you very much, Kai
-- 
DSL-Preisknaller: DSL Komplettpakete von GMX schon für 
16,99 Euro mtl.!* Hier klicken: http://portal.gmx.net/de/go/dsl02

___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


Re: [osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-10 Thread marcus.wolschon
On Tue, 10 Nov 2009 11:12:45 +0100, "Kai Behncke" 
wrote:
> If I try E:/osmosis/java -jar osmosis.jar ...
> or E:/osmosis/bin/osmosis ..

> java.lang.NoClassDefFoundError: org/java/plugin/PluginLifecycleException
> at org.openstreetmap.osmosis.core.Osmosis.run(Osmosis.java:73)
> at org.openstreetmap.osmosis.core.Osmosis.main(Osmosis.java:30)


osmosis.bat /bin/osmosis both seem to be missing lib/test/jpf-1.5.jar in
-cp
and osmosis.jar is missing a "class-path: " -entry in it's manifest to
require these jar-files if run as "java -jar osmosis.jar".


Marcus


___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev


[osmosis-dev] Problem using Osmosis (PluginLifecycleException)

2009-11-10 Thread Kai Behncke
Dear Developers,

I`m planning to use "osmosis" in a lecture of our university.
I have lust download the actual osmosis-version on my Windowx-XP from

http://dev.openstreetmap.org/~bretth/osmosis-build/osmosis-latest.zip

But now I get problems to do some commands.

If I try E:/osmosis/java -jar osmosis.jar ...
or E:/osmosis/bin/osmosis ..

I always get:

INFO: Osmosis Version 0.31
10.11.2009 10:28:01 org.openstreetmap.osmosis.core.Osmosis main
SCHWERWIEGEND: Execution aborted.
java.lang.NoClassDefFoundError: org/java/plugin/PluginLifecycleException
at org.openstreetmap.osmosis.core.Osmosis.run(Osmosis.java:73)
at org.openstreetmap.osmosis.core.Osmosis.main(Osmosis.java:30)
..
..

As far as I know PluginLifecycleException exists in jpf-1.5.jar (that is in
lib/default/ , /lib/test, /lib/compile

but smoehow it`s not accepted?

Can anyone help me please?

The problem is: I can`t use it on linux, because in the course the students 
have only Windows-Computers :-(

Best regards and thank you, Kai









-- 
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01

___
osmosis-dev mailing list
osmosis-dev@openstreetmap.org
http://lists.openstreetmap.org/listinfo/osmosis-dev