View previous topic :: View next topic |
Author |
Message |
nOps34 Tux's lil' helper
Joined: 16 Dec 2006 Posts: 105 Location: France - Montpellier
|
Posted: Sun May 02, 2010 4:14 pm Post subject: [GMOTE] créer un lanceur (résolu) |
|
|
Salut,
je viens d'installer gmote, le server qui permet d'utiliser son mobile sous android comme une télécommande.
j'ai décompresser l'archive dans /opt/gmote.
le script de lancement fonctionne correctement uniquement si je le lance depuis le dossier dans lequel il se trouve à savoir: /opt/gmote/GmoteServerLinux2.0.0/
si je le lance depuis ~/ j'obtiens le message suivant:
Code: | Exception in thread "main" java.lang.NoClassDefFoundError: org/gmote/server/GmoteServerUiLinux
Caused by: java.lang.ClassNotFoundException: org.gmote.server.GmoteServerUiLinux
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
Could not find the main class: org.gmote.server.GmoteServerUiLinux. Program will exit. |
vous voyez le problème?
Last edited by nOps34 on Sun May 02, 2010 7:29 pm; edited 2 times in total |
|
Back to top |
|
|
nOps34 Tux's lil' helper
Joined: 16 Dec 2006 Posts: 105 Location: France - Montpellier
|
Posted: Sun May 02, 2010 7:25 pm Post subject: |
|
|
Si je saisi bien, le problème vient du fait que le chemin désigné dans la commande java est relatif.
Il faudrait donc mettre un chemin absolu mais la je cale...
voici le script:
Code: | echo "Starting GmoteServer 2.0 ... "
java -classpath bin:lib/jna.jar:lib/slf4j-api-1.5.3.jar:lib/swing-worker-1.2.jar org.gmote.server.GmoteServerUiLinux &
echo "GmoteServer started." |
j'ai essayé ça:
Code: | echo "Starting GmoteServer 2.0 ... "
java -classpath bin:lib/jna.jar:lib/slf4j-api-1.5.3.jar:lib/swing-worker-1.2.jar .opt.gmote.bin.org.gmote.server.GmoteServerUiLinux &
echo "GmoteServer started." |
sans succès |
|
Back to top |
|
|
nOps34 Tux's lil' helper
Joined: 16 Dec 2006 Posts: 105 Location: France - Montpellier
|
Posted: Sun May 02, 2010 7:28 pm Post subject: |
|
|
j'ai résolu le problème en modifiant le script comme ceci:
Code: | cd /opt/gmote
echo "Starting GmoteServer 2.0 ... "
java -classpath bin:lib/jna.jar:lib/slf4j-api-1.5.3.jar:lib/swing-worker-1.2.jar org.gmote.server.GmoteServerUiLinux &
echo "GmoteServer started." |
|
|
Back to top |
|
|
|