O
Olivier Laurent
Hi there,
I'm playing with Java for about a month now. My background is perl.
I'm using "Head First Java" and "Developping games in Java" to learn
this language. Both are fun to read and making 3D games helps me to be
very excited
)
My editor is Jedit+Ant plug-in with Apache ant installed on a Linux
distro (SUSE).
I can compile/run my app through Jedit (ant-farm project: run...)
without any problem. So the code in itself seems fine.
Yesterday a friend of mine asked me to send him my project to test it
on his computer.
Well...I tried for the first time to make a Jar file. I build my
project using Jedit and ant. I write a manifest with Main-Class:
EventTest called manifest.txt . I copied manifes.txt to the root
directory.
The project has several subdirectories. All of them are present in the
build subdirectory. These subdirectories contain crucial class to be
imported.
When I run jar
(jar -cvmf manifest.txt test.jar *)
It seems that it compresses all neccessary subdirectories
But when I try
java -jar test.jar EventTest
I receive the following Error:
Exception in thread "main" java.lang.NoClassDefFoundError:
java/awt/DisplayMode
at com.brackeen.javagamebook.test.GameCore.<clinit>(GameCore.java:17)
Subdirectories have been compressed into test.jar . At least I can see
traces in the process.
What is missing?
Thanks
Olivier
I'm playing with Java for about a month now. My background is perl.
I'm using "Head First Java" and "Developping games in Java" to learn
this language. Both are fun to read and making 3D games helps me to be
very excited
My editor is Jedit+Ant plug-in with Apache ant installed on a Linux
distro (SUSE).
I can compile/run my app through Jedit (ant-farm project: run...)
without any problem. So the code in itself seems fine.
Yesterday a friend of mine asked me to send him my project to test it
on his computer.
Well...I tried for the first time to make a Jar file. I build my
project using Jedit and ant. I write a manifest with Main-Class:
EventTest called manifest.txt . I copied manifes.txt to the root
directory.
The project has several subdirectories. All of them are present in the
build subdirectory. These subdirectories contain crucial class to be
imported.
When I run jar
(jar -cvmf manifest.txt test.jar *)
It seems that it compresses all neccessary subdirectories
But when I try
java -jar test.jar EventTest
I receive the following Error:
Exception in thread "main" java.lang.NoClassDefFoundError:
java/awt/DisplayMode
at com.brackeen.javagamebook.test.GameCore.<clinit>(GameCore.java:17)
Subdirectories have been compressed into test.jar . At least I can see
traces in the process.
What is missing?
Thanks
Olivier