[Qt-jambi-interest] jambi 4.4 and empty spaces

Waldemar Wittmann w_wittmann at gmx.de
Thu Jul 10 14:29:16 CEST 2008


Am Donnerstag, den 10.07.2008, 13:03 +0200 schrieb Eskil Abrahamsen
Blomfeldt:
> Waldemar Wittmann wrote:
> > The launcher starts out of an path with empty spaces. But try to start a
> > QtJambi example or an arbitrary qt jambi application directly in the
> > same way you wrote above but without the Launcher.
> >   
> 
> Hi, Waldemar.
> 
> I've just successfully run the Styles and AnalogClock examples from a 
> path with spaces. Do you have an example of an application which will 
> not run in that type of environment?
> 
> -- Eskil
> 

Hi Eskil and all :)

Ok, i try to give a special example in detail. It's in Linux but it goes
analog in Windows and with all the other Qt Jambi Examples and self-made
Qt Jambi Applications and perhaps you don't need to do exactly the
settings i do.

I create a new directory: /home/waldi/Desktop/foo
I put in it: 
- qtjambi-4.4.0_01.jar 
- qtjambi-linux32-gcc-4.4.0_01.jar

Now I go in my "Test" Project in Eclipse and export the HelloWorld1
Application. It's the HelloWorld example from Trolltech i copied into
the "Test" Project into a created "Tutorial" package
and refactored/renamed the class to HelloWorld1.

In the export options i check 
- "Export all output folders for checked project"
- "Export java source files and resources"
- "Compress the contents of the JAR file"
- "Add directory entries"

and choose:
- "Generate the manifest file"
- "Seal the JAR"
Main class: Tutorial.HelloWorld1
and export it to /home/waldi/Desktop/foo/foo.jar

Now i go into /home/waldi/Desktop/foo and do:

~/Desktop/foo$ java -cp
qtjambi-4.4.0_01.jar:qtjambi-linux32-gcc-4.4.0_01.jar:foo.jar
Tutorial.HelloWorld1

It works and the HelloWorld Qt Jambi Application (without icon) starts.
Now i rename the directory "foo" to "foo foo" and go
into: /home/waldi/Desktop/foo foo/ and do and get the exception:

~/Desktop/foo foo$ java -cp
qtjambi-4.4.0_01.jar:qtjambi-linux32-gcc-4.4.0_01.jar:foo.jar
Tutorial.HelloWorld1
Exception in thread "main" java.lang.ExceptionInInitializerError
	at com.trolltech.qt.QtJambiObject.<clinit>(QtJambiObject.java:40)
	at Tutorial.HelloWorld1.main(HelloWorld1.java:8)
Caused by: java.lang.RuntimeException: Loading library failed, progress
so far:
Unpacking .jar file: 'file:/home/waldi/Desktop/foo%
20foo/qtjambi-linux32-gcc-4.4.0_01.jar'

	at
com.trolltech.qt.internal.NativeLibraryManager.loadNativeLibrary(NativeLibraryManager.java:420)
	at
com.trolltech.qt.internal.NativeLibraryManager.loadQtLibrary(NativeLibraryManager.java:352)
	at com.trolltech.qt.Utilities.loadQtLibrary(Utilities.java:120)
	at com.trolltech.qt.Utilities.loadQtLibrary(Utilities.java:116)
	at
com.trolltech.qt.QtJambi_LibraryInitializer.<clinit>(QtJambi_LibraryInitializer.java:36)
	... 2 more
Caused by: java.lang.RuntimeException: Failed to unpack native
libraries, progress so far:
Unpacking .jar file: 'file:/home/waldi/Desktop/foo%
20foo/qtjambi-linux32-gcc-4.4.0_01.jar'

	at
com.trolltech.qt.internal.NativeLibraryManager.unpack(NativeLibraryManager.java:365)
	at
com.trolltech.qt.internal.NativeLibraryManager.loadLibrary_helper(NativeLibraryManager.java:426)
	at
com.trolltech.qt.internal.NativeLibraryManager.loadNativeLibrary(NativeLibraryManager.java:415)
	... 6 more
Caused by: java.lang.NullPointerException
	at
com.trolltech.qt.internal.NativeLibraryManager.readDeploySpec(NativeLibraryManager.java:483)
	at
com.trolltech.qt.internal.NativeLibraryManager.unpackJarFile_helper(NativeLibraryManager.java:570)
	at
com.trolltech.qt.internal.NativeLibraryManager.unpackJarFile(NativeLibraryManager.java:249)
	at
com.trolltech.qt.internal.NativeLibraryManager.unpack_helper(NativeLibraryManager.java:382)
	at
com.trolltech.qt.internal.NativeLibraryManager.unpack(NativeLibraryManager.java:360)
	... 8 more

can you now reproduce it?

regards,
waldemar




More information about the Qt-jambi-interest mailing list