Lancement sans JNLP

This topic has been viewed 16528 times and has 2 replies
Thread status: Active
Questions about Sweet Home 3D installation [img]http://www.sweethome3d.com/images/flags/en_small.gif[/img]
Post Reply New Topic
jlliagre
Posts: 3
Joined: Wed Jul 23, 2008 2:28 am
Country: France

Lancement sans JNLP

Post by jlliagre »

Bonjour,

Le démarrage de SH3D via JNLP est lent et parfois aléatoire. Comme il n'est par proposé d'installeur pour Solaris, j'ai compilé à partir des sources et tenté "java -classpath lib/itext-2.0.4.jar:lib/Loader3DS1_2.jar:lib/SweetHome3D.jar com.eteks.sweethome3d.SweetHome3D" mais j'obtient cette erreur:

Exception in thread "main" java.lang.NoClassDefFoundError: javax/jnlp/UnavailableServiceException
Caused by: java.lang.ClassNotFoundException: javax.jnlp.UnavailableServiceException
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
Could not find the main class: com.eteks.sweethome3d.SweetHome3D. Program will exit.

Comment peut-on lancer SH3D en tant qu'application Java ?




[Note: this thread was started on sourceforge.net forums]
User avatar
Puybaret
Posts: 9440
Joined: Mon Nov 07, 2005 12:00 pm
Country: Paris, France
Contact:

Re: Lancement sans JNLP

Post by Puybaret »

Quand Sweet Home 3D est lancé en tant qu'application, le programme utilise des implémentations personnalisées des interfaces des services JNLP SingleInstanceService et BasicService dont le programme a besoin sous Java Web Start (voir lignes 586 et suivantes de http://sweethome3d.cvs.sourceforge.net/sweethome3d/SweetHome3D/src/com/eteks/sweethome3d/SweetHome3D.java?revision=1.61&view=markup ).
Il faut donc ajouter au classpath de votre commande le fichier javaws.jar du dossier lib du JRE ou le fichier jnlp.jar du dossier libtest du projet.


Emmanuel Puybaret, Sweet Home 3D creator
jlliagre
Posts: 3
Joined: Wed Jul 23, 2008 2:28 am
Country: France

Re: Lancement sans JNLP

Post by jlliagre »

Merci, c'était bien le problème.

Pour info, après installation de Java3D dans /opt/j3d, je peux maintenant lancer sh3d en standalone avec ce script:

LD_LIBRARY_PATH=/opt/j3d/lib/i386
java -classpath .:/opt/j3d/lib/ext/j3dcore.jar:/opt/j3d/lib/ext/j3dutils.jar:\
/opt/j3d/lib/ext/vecmath.jar:deploy/lib/itext-2.0.4.jar:deploy/lib/Loader3DS1_2.jar:\
deploy/lib/SweetHome3D.jar:/opt/jdk1.6.0_10/jre/lib/javaws.jar com.eteks.sweethome3d.SweetHome3D



Post Reply New Topic

Who is online

Users browsing this forum: No registered users and 2 guests