D:\Developer\scjd\starting>jar cmf lib\server.mf build\server.jar build\server\* D:\Developer\scjd\starting>java -jar server.jar Failed to load Main-Class manifest attribute from server.jar Iam getting this error. my server.mf contains Main-Class: suncertify.server.RemoteServerManager The default manifest file copies this content. still i have problem in running server. pls respond asap. Thanks
I did the same still iam getting error. D:\Developer\scjd\starting>java -jar server.jar Failed to load Main-Class manifest attribute from server.jar Is there any other way to do it. My manifest.mf contains: Manifest-Version: 1.0 Main-Class: suncertify.server.Server Created-By: 1.3.1_01 (Sun Microsystems Inc.)
Well the manifest file looks correct. But what directory do you have it stored in? and when you add it to the jar, does it put pathing in it? You cn use a tool like Winzip to see that information. The manifest file needs to not have any path in that jar file, meaning it is the root. Therefore the other classes have the path. In the manifest file the main class is "suncertify.server.Server" Therefore it will look at/for a path of suncertify/server for a class called Server in the jar file.