Manifest in jars

ok Im trying to make an executable jar for my program, but I cant figure out how to make the manifest file.. also, once I do that, what do I do to make it run?

jar cvfm MyJar.jar MyManifest.txt -C . *.javawhere do you type that? I tried in a command console
but it didnt work...Make sure jar.exe is in your path.
and what do u mean by com.acme.MyMainClass? do I have to put the com.acme?No, you would replace it with the fully qualified name of your own class of course. You are allowed to use your own brains too.

Similar Messages

  • How to display Manifest in Jar file?

    I m not new to Java (6+ years). But today I have a simple question and dont know answer @_@:
    how to view the Manifest in Jar file? I know to use java.util.jar package in code but is it a simple way to do that in command line? Seems Jar doestnot support that, strange.
    Thanks.

    Command line... go with the times dude. Use a graphical zip utility :)

  • Manifest for jar file

    hi i create an jar file
    Manifest-Version: 1.0
    Main-Class: com.IR.IRoom
    Class-Path: classes12.jar aqapill.jar aqapi.jar aqapi60.jar art.jar arutil60.jar atli2.jar atli2_ip.jar atli2_ip_cio.jar bsh.jar codeset.jar commons.jar commons_httpclient.jar commons-lang-1.0.jar commons-logging.jar commons-net-1.1.0.jar
    i have two question now.
    when i jar this it give me error "line too long " bcz i have some more jars in it.
    second could i mention any folder which have jars file in classpath
    like Class-Path:include/*.jar
    regards

    Have you seen this recent thread: http://forum.java.sun.com/thread.jspa?threadID=689987&tstart=0
    There is a limit of 72 bytes (not chars!) per line in a manifest. YMMV, but you should be using Ant.

  • Adding manifests to Jar files using different  versions

    I have been using the following to add a manifest pointer to my main class called JTiming
    C:\jdk1.1.8\bin\jar cmfv MyMainClass.txt JTiming.jar *
    and it works a treat, when I unjar the jar and look at the manifest file it includes the pointer to JTiming and lists each file jarred. When I try it with JDK1.3.1 or JDK1.4.1 jar.exe's they both fail to create the correct manifest entries. I can't see any notice of a change to the command line ooptions for the jar.exe's for these newer versions what am I missing?

    You seem to misunderstand - if you look at the command line I wrote in my original posting, I do exactly what you suggest!! I am able to include a reference to my starting class, my problem is that I appear to be able to get my own manifest inclusion using 1.1.8 jar.exe, but not using the jar.exe from 1.3.1 or 1.4.0

  • Simple Query, Manifest file, Jar, Main-Class

    Hello :P thanks for reading my post.
    I compiled a java file which gave me:
    *.class
    *$1.class
    Then I created a jar file which i want to run when a user clicks on a link or button ect.
    I have the latest SDK and the -e mod did not exist :( so i used cfm with a manifest.txt file.
    I've tried using the following in my index.html file to run the hello world Swing application:
    <html>
    <head> <title>HelloWorldSwing</title>
    </head>
    <body>
    <h1>my heading</h1>
    <applet code=HelloWorldSwing codebase=classes archive=HelloWorldSwing.jar
    width=695 height=525>
    </applet>
    </body> </html>
    It gives me an error saying it cant access the class HelloWorldSwing.
    I belive it might be my Main-Class: classname in the Manifest.txt file.
    *I can't get my head around the format of classname.
    I was wonder if a kind soul would tell me what my classname is ment to look like. I've read a few examples and I just don't seem to grasp the concept.
    Mabey i'm going about the whole thing the wrong way.
    More info:
    HelloWorldSwing.java contains the following code:
    * HelloWorldSwing.java requires no other files.
    import javax.swing.*;
    public class HelloWorldSwing {
    * Create the GUI and show it. For thread safety,
    * this method should be invoked from the
    * event-dispatching thread.
    private static void createAndShowGUI() {
    //Create and set up the window.
    JFrame frame = new JFrame("HelloWorldSwing");
    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    //Add the ubiquitous "Hello World" label.
    JLabel label = new JLabel("Hello World");
    frame.getContentPane().add(label);
    //Display the window.
    frame.pack();
    frame.setVisible(true);
    public static void main(String[] args) {
    //Schedule a job for the event-dispatching thread:
    //creating and showing this application's GUI.
    javax.swing.SwingUtilities.invokeLater(new Runnable() {
    public void run() {
    createAndShowGUI();
    }

    The Main-class attribute in the manifest is for when you do java -jar myjar.jar. It has nothing to do with applets, where you specify the class in the HTML.
    The format of the class name is package.classname.
    Your problem is that HelloWorldSwing is a main program, not an applet. It has to extend java.applet.Applet.

  • Problems with Manifest building jar file

    Hello all,
    i try to deploy my application in a jar file. I also have some libs to deploy with my application. My app.jar and my lib.jar are in the same directory. My Manifest looks like:
    Manifest-Version: 1.0
    Main-Class: parser.Parser
    Class-Path: lib.jar
    Class-Path: ...Still get the error: NoClassDefFoundError.
    Main Class is found but not my lib. Can somebody help?
    regards ak

    Hi CeciNEstPasUnProgrammeur,
    many thanks. I was blind reading the Java tutorial...
    Best regards,
    ak

  • How to use the classpath defined in a manifest file when debugging

    Using Jdeveloper 10.1.3.3.0 (or any version)
    I'd like to be able to debug using an executable jar which specifies my classpath and main class, without having to manually add all the jars to my debug configuration. Is there a way the debugger can extract that information from the manifest?
    The set of jar files included in my classpath varies depending on which client configuration the client wants to run and we could potentially have a hundred different configurations so there isn't an easy way to manage static libraries. Currently I have to open the jar, extract the manifest and manually add the jars so I can debug. Which is really painful when the configuration can change each time I run. The manifest and jar file are created at runtime based on what client configuration the user is trying to run and there can be multiple versions of a jar file in the directory with mangled names - so I can't just include all the jars.
    Any ideas?

    Run the program from command line, this way you will see the errors, if any.
    example.: java -jar theJarfile.jar
    I was successful in creating a comm application. I placed the win32com.dll in the same directory of my application jar file and all worked.
    I also extracted the comm.jar , and jar'd my app with the extracted comm files to make one jar.
    I also had a fileWriter() to get the clients jre path and my app would write the javax.properties file to the correct place.
    It took me severel weeks and late nights to accomplish this, but it was all necessary to be able to install only my app, and not a bunch of api's that were needed.

  • Hyperion 11.1. 2.0 Install fails with "Some referenced jars do not exists"

    Hi All,
    I am trying to install Hyperion 11.1.2.0 on my laptop. Though the requirements document says the supported OS is windows 2003 or 2008, I have read that people are able to get it working on other OS' as well.
    I have downloaded the below files:
    V20779-01
    V20782-01
    V20783-01
    V20790-01
    V20792-01
    V20799-01
    V20800-01
    V20801-01
    V20802-01
    V20843-01
    V20850-01
    I have the loopback adapter installed and OBIEE 11g running on weblogic server.
    The EPM install has gone through successfully as I see from the log. But when I try to configure the "EPM System Configurator" it command exits with the below error message:
    Running preconfig checks...
    Running EPM_ORACLE_HOME check...
    EPM_ORACLE_HOME environment variable value: F:\OracleBI11G\EPMSystem11R1
    JAVA_HOME environment variable value: F:\OracleBI11G\EPMSystem11R1\..\jdk160
    _11
    EPM_ORACLE_HOME check succeeded
    Running .oracle.products check... .oracle.products check succeeded
    Running Jars manifest check...
    Time spent for manifests parsing: 220 ms
    Maximum jars depth achieved: 6, while restriction was: unrestricted
    Parsed 383 manifests
    Total jars and classpath entries encountered: 383
    Total not-existing referenced classpath entries count: 22
    Total classpath elements to check: 67
    ERROR: F:\OracleBI11G\modules\org.apache.ant_1.7.0\lib\xercesImpl.jar not
    exists; file depth: 3; referenced from F:\OracleBI11G\EPMSystem11R1\common\jlib\
    11.1.2.0\ctg.jar referenced from F:\OracleBI11G\EPMSystem11R1\common\jlib\11.1.2
    .0\epm_j2se.jar referenced from F:\OracleBI11G\EPMSystem11R1\common\config\11.1.
    2.0\configtool.jar
    FATAL ERROR: Jars manifest check failed with message "Some referenced jars do no
    t exist"
    Exiting in 30 seconds
    After reading a similar post in OTN which suggested this could be due to OHS not installed correctly, I reinstalled OHS successfully.
    I still get this error. Can anyone help me how to get around this issue.
    thanks,
    sandeep.

    I got the same problem with you. If you check in your physical directory, you wouldn't find F:\OracleBI11G\modules\org.apache.ant_1.7.0. Maybe when the installtools installed the EPM System, it detected that apache had been installed by OBIEE. Maybe you'll find F:\OracleBI11G\modules\org.apache.ant_1.7.1. The way I took to make configtools worked was by copying F:\OracleBI11G\modules\org.apache.ant_1.7.1 to F:\OracleBI11G\modules\org.apache.ant_1.7.0 and re run the configtools.
    Now I got the other problem when I tried to deploy foundation service to weblogic. It gave me EPMCFG-10067 : Failed to get admin user name for the domain.
    Try to copy F:\OracleBI11G\modules\org.apache.ant_1.7.1 to F:\OracleBI11G\modules\org.apache.ant_1.7.0. Maybe after that you can help me solving my problem.

  • Help with JAR Files

    OK, folks, I need some help here...
    And I have researched on this prior to this post, but I still don't get it.
    I have a simple application in Reminder.java file. When I compile it, I get Reminder.class and Reminder$ReminderThread.class, because I have an inner class.
    I place those files in Reminder directory. I want to make an executable JAR file, so I made a manifest file outside the Reminder directory that contains these lines
    Manifest-Version: 1.0
    Main-Class: Reminder.Remindersince the Reminder.class is within the Reminder directory, I understood I had to have a prefix "Reminder."
    In the command line, I type
    jar cmf manifest Reminder.jar Reminder/Reminder.class Reminder/Reminder$ReminderThread.classAnd I do get a Reminder.jar file, but when I double-click on it, I get a popup saying "Could not find the main class. Program will exit!"
    So, what am I doing wrong and how can I fix this? As I said, I have researched, but I can't understand what went wrong nor how to fix the problem.
    Any help will be greatly appreciated.

    Never mind, I solved it, I was missing a carriage return in my manifest file. I feel so stupid now...

  • Jar not running is sarge and apache-ant  shows error of package not found

    Hello,
    First of all I am not a java programmer. I work in C/C++/C#.
    Currently I am dealing a game written in java (1.5) using netbeans 5.5.0 under windows xp. My target is to compile in my development machine and run in the clients machine. everything works fine in windows xp. I open the netbeans ide, load the necessary class libraries, build the project and run it. it runs without any problem.
    The problem begins when I run the same project from linux (fedora). it doest not run. It shows some error.
    <error platform="fedora 7">
    Exception in thread "AWT-EventQueue-0" java.awt.HeadlessException:
    No X11 DISPLAY variable was set, but this program performed an operation which requires it.
    at java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:159)
    at java.awt.Window.<init>(Window.java:406)
    at java.awt.Frame.<init>(Frame.java:402)
    at java.awt.Frame.<init>(Frame.java:367)
    at javax.swing.JFrame.<init>(JFrame.java:163)
    at netbeansapplication.nbApplication.<init>(nbApplication.java:52)
    at netbeansapplication.nbApplication$14.run(nbApplication.java:453)
    at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:173)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:121)
    </error>
    Some of these error were resolved when I set the DISPLAY variable (export DISPLAY="127.0.0.1:0") but the other errors were still there.
    But when I open this same project in netbeans and resolve the dependencies with class libraries it works ok after compiling.
    I can run it from console (java -jar ...)
    And again the same source tree shows the following error when I am in windows !!! (by java -jar ... command)
    <error platform="WinXPSP2">
    Exception in thread "AWT-EventQueue-0" java.lang.NumberFormatException: For input string: ""
    at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
    at java.lang.Integer.parseInt(Integer.java:468)
    at java.lang.Integer.parseInt(Integer.java:497)
    at cherrygame.global.readConfigForStickProtection(global.java:2060)
    at cherrygame.nbCherryGame.<init>(nbCherryGame.java:243)
    at netbeansapplication.nbApplication.<init>(nbApplication.java:46)
    at netbeansapplication.nbApplication$14.run(nbApplication.java:453)
    at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:173)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:121)
    </error>
    I see that netbeans uses ant to compile project in the background.
    then I tried using ant to compile.
    doing only `#ant compile` where build.xml resides does the compilation.
    after that I try to run it (by java -jar ...). again the above error shows up.
    What would I do?
    If I compile it with netbeans in machine A then it runs well in A but not in machine B.
    If I compile it with ANT in machine A then it doesn't run in A, no chance for machine B.
    the contents of my build xml is here
    <code file="build.xml">
    <![CDATA[
    <?xml version="1.0" encoding="UTF-8"?>
    <!-- You may freely edit this file. See commented blocks below for -->
    <!-- some examples of how to customize the build. -->
    <!-- (If you delete it and reopen the project it will be recreated.) -->
    <project name="NetBeansApplication" default="default" basedir=".">
    <description>Builds, tests, and runs the project NetBeansApplication.</description>
    <import file="nbproject/build-impl.xml"/>
    <!--
    There exist several targets which are by default empty and which can be
    used for execution of your tasks. These targets are usually executed
    before and after some main targets. They are:
    -pre-init: called before initialization of project properties
    -post-init: called after initialization of project properties
    -pre-compile: called before javac compilation
    -post-compile: called after javac compilation
    -pre-compile-single: called before javac compilation of single file
    -post-compile-single: called after javac compilation of single file
    -pre-compile-test: called before javac compilation of JUnit tests
    -post-compile-test: called after javac compilation of JUnit tests
    -pre-compile-test-single: called before javac compilation of single JUnit test
    -post-compile-test-single: called after javac compilation of single JUunit test
    -pre-jar: called before JAR building
    -post-jar: called after JAR building
    -post-clean: called after cleaning build products
    (Targets beginning with '-' are not intended to be called on their own.)
    Example of inserting an obfuscator after compilation could look like this:
    <target name="-post-compile">
    <obfuscate>
    <fileset dir="${build.classes.dir}"/>
    </obfuscate>
    </target>
    For list of available properties check the imported
    nbproject/build-impl.xml file.
    Another way to customize the build is by overriding existing main targets.
    The targets of interest are:
    -init-macrodef-javac: defines macro for javac compilation
    -init-macrodef-junit: defines macro for junit execution
    -init-macrodef-debug: defines macro for class debugging
    -init-macrodef-java: defines macro for class execution
    -do-jar-with-manifest: JAR building (if you are using a manifest)
    -do-jar-without-manifest: JAR building (if you are not using a manifest)
    run: execution of project
    -javadoc-build: Javadoc generation
    test-report: JUnit report generation
    An example of overriding the target for project execution could look like this:
    <target name="run" depends="NetBeansApplication-impl.jar">
    <exec dir="bin" executable="launcher.exe">
    <arg file="${dist.jar}"/>
    </exec>
    </target>
    Notice that the overridden target depends on the jar target and not only on
    the compile target as the regular run target does. Again, for a list of available
    properties which you can use, check the target you are overriding in the
    nbproject/build-impl.xml file.
    -->
    <target name="-post-jar">
    <jar update="true" destfile="${dist.jar}">
    <zipfileset src="${libs.swing-layout.classpath}"/>
    <zipfileset src="${libs.addMoney.classpath}"/>
    <zipfileset src="${libs.NormalWindow.classpath}"/>
    </jar>
    </target>
    </project>
    ]]>
    </code>
    my directory contents is here. note. I have 2 packages "cgwindow2" and "NormalWindow" for class libraries and my main application is "CherryGame". The game is "game.jar" in the CherryGame folder.
    <listing foldername="CherryGame">
    D:\src\java\CherryGame\build.xml
    D:\src\java\CherryGame\BW.txt
    D:\src\java\CherryGame\config.txt
    D:\src\java\CherryGame\config.txt.lin
    D:\src\java\CherryGame\flopsfile.txt
    D:\src\java\CherryGame\game.jar
    D:\src\java\CherryGame\LWMoneyfile.txt
    D:\src\java\CherryGame\mfile.txt
    D:\src\java\CherryGame\mfile2.txt
    D:\src\java\CherryGame\mfile3.txt
    D:\src\java\CherryGame\TotalRollsTillBigWin.txt
    D:\src\java\CherryGame\UserFile.txt
    D:\src\java\CherryGame\build\classes\cherrygame\addMoneyFrame.class
    D:\src\java\CherryGame\build\classes\cherrygame\addMoneyPanel.class
    D:\src\java\CherryGame\build\classes\cherrygame\cardsPanel.class
    D:\src\java\CherryGame\build\classes\cherrygame\cardsWindow$1.class
    D:\src\java\CherryGame\build\classes\cherrygame\cardsWindow.class
    D:\src\java\CherryGame\build\classes\cherrygame\cherryGameBackPanel.class
    D:\src\java\CherryGame\build\classes\cherrygame\cherryWindow.class
    D:\src\java\CherryGame\build\classes\cherrygame\customBorderCherryGame.class
    D:\src\java\CherryGame\build\classes\cherrygame\FixedGlassPane.class
    D:\src\java\CherryGame\build\classes\cherrygame\global.class
    D:\src\java\CherryGame\build\classes\cherrygame\helpPanelOne.class
    D:\src\java\CherryGame\build\classes\cherrygame\imagesPanel.class
    D:\src\java\CherryGame\build\classes\cherrygame\messageWindow.class
    D:\src\java\CherryGame\build\classes\cherrygame\messageWindow2.class
    D:\src\java\CherryGame\build\classes\cherrygame\messageWindow3.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$1.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$10.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$11.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$12.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$13.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$14.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$15.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$16.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$17.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$18.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$19.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$2.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$20.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$21.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$22.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$23.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$24.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$25.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$26.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$27.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$28$1.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$28$2.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$28.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$29.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$3.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$30.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$31.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$32.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$33.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$34.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$35.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$36.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$37.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$38.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$39.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$4.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$40.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$41.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$42.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$43.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$44.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$45.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$46.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$5.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$6.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$7.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$8.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$9.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame$MyTask.class
    D:\src\java\CherryGame\build\classes\cherrygame\nbCherryGame.class
    D:\src\java\CherryGame\build\classes\cherrygame\panelMessage.class
    D:\src\java\CherryGame\build\classes\cherrygame\panelMessage2.class
    D:\src\java\CherryGame\build\classes\cherrygame\panelMessage3.class
    D:\src\java\CherryGame\build\classes\lpt\LPT.class
    D:\src\java\CherryGame\build\classes\lpt\events\Events.class
    D:\src\java\CherryGame\build\classes\lpt\events\LPTEvent.class
    D:\src\java\CherryGame\build\classes\lpt\events\LPTEventListener.class
    D:\src\java\CherryGame\build\classes\lpt\ieee1284\PPParallelPort.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\customBorder.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$1.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$10.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$11.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$12.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$13.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$14.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$2.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$3.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$4.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$5.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$6.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$7.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$8.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication$9.class
    D:\src\java\CherryGame\build\classes\netbeansapplication\nbApplication.class
    D:\src\java\CherryGame\dist\NetBeansApplication.jar
    D:\src\java\CherryGame\dist\javadoc\package-list
    D:\src\java\CherryGame\dist\javadoc\stylesheet.css
    D:\src\java\CherryGame\dist\javadoc\resources\inherit.gif
    D:\src\java\CherryGame\nbproject\build-impl.xml
    D:\src\java\CherryGame\nbproject\genfiles.properties
    D:\src\java\CherryGame\nbproject\project.properties
    D:\src\java\CherryGame\nbproject\project.xml
    D:\src\java\CherryGame\nbproject\private\private.properties
    D:\src\java\CherryGame\nbproject\private\private.xml
    D:\src\java\CherryGame\src\customBorder.java
    D:\src\java\CherryGame\src\nbApplication.form
    D:\src\java\CherryGame\src\nbApplication.java
    D:\src\java\CherryGame\src\cherrygame\addMoneyFrame.form
    D:\src\java\CherryGame\src\cherrygame\addMoneyFrame.java
    D:\src\java\CherryGame\src\cherrygame\addMoneyPanel.form
    D:\src\java\CherryGame\src\cherrygame\addMoneyPanel.java
    D:\src\java\CherryGame\src\cherrygame\cardsPanel.java
    D:\src\java\CherryGame\src\cherrygame\cardsWindow.form
    D:\src\java\CherryGame\src\cherrygame\cardsWindow.java
    D:\src\java\CherryGame\src\cherrygame\cherryGameBackPanel.form
    D:\src\java\CherryGame\src\cherrygame\cherryGameBackPanel.java
    D:\src\java\CherryGame\src\cherrygame\cherryWindow.java
    D:\src\java\CherryGame\src\cherrygame\customBorderCherryGame.java
    D:\src\java\CherryGame\src\cherrygame\global.java
    D:\src\java\CherryGame\src\cherrygame\helpPanelOne.form
    D:\src\java\CherryGame\src\cherrygame\helpPanelOne.java
    D:\src\java\CherryGame\src\cherrygame\imagesPanel.java
    D:\src\java\CherryGame\src\cherrygame\messageWindow.form
    D:\src\java\CherryGame\src\cherrygame\messageWindow.java
    D:\src\java\CherryGame\src\cherrygame\messageWindow2.form
    D:\src\java\CherryGame\src\cherrygame\messageWindow2.java
    D:\src\java\CherryGame\src\cherrygame\messageWindow3.form
    D:\src\java\CherryGame\src\cherrygame\messageWindow3.java
    D:\src\java\CherryGame\src\cherrygame\nbCherryGame.form
    D:\src\java\CherryGame\src\cherrygame\nbCherryGame.java
    D:\src\java\CherryGame\src\cherrygame\panelMessage.form
    D:\src\java\CherryGame\src\cherrygame\panelMessage.java
    D:\src\java\CherryGame\src\cherrygame\panelMessage2.form
    D:\src\java\CherryGame\src\cherrygame\panelMessage2.java
    D:\src\java\CherryGame\src\cherrygame\panelMessage3.form
    D:\src\java\CherryGame\src\cherrygame\panelMessage3.java
    D:\src\java\CherryGame\src\lpt\LPT.java
    D:\src\java\CherryGame\src\lpt\events\Events.java
    D:\src\java\CherryGame\src\lpt\events\LPTEvent.java
    D:\src\java\CherryGame\src\lpt\events\LPTEventListener.java
    D:\src\java\CherryGame\src\lpt\ieee1284\PPParallelPort.java
    </listing>
    <listing foldername="NormalWindow">
    D:\src\java\NormalWindow\build.xml
    D:\src\java\NormalWindow\manifest.mf
    D:\src\java\NormalWindow\build\classes\normalwindow\global.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$1.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$10.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$11.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$12.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$13.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$14.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$15.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$16.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$17.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$2.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$3.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$4.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$5.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$6.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$7.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$8.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow$9.class
    D:\src\java\NormalWindow\build\classes\normalwindow\NormalWindow.class
    D:\src\java\NormalWindow\build\classes\normalwindow\PasswordDialog$1.class
    D:\src\java\NormalWindow\build\classes\normalwindow\PasswordDialog$2.class
    D:\src\java\NormalWindow\build\classes\normalwindow\PasswordDialog$3.class
    D:\src\java\NormalWindow\build\classes\normalwindow\PasswordDialog$4.class
    D:\src\java\NormalWindow\build\classes\normalwindow\PasswordDialog$5.class
    D:\src\java\NormalWindow\build\classes\normalwindow\PasswordDialog.class
    D:\src\java\NormalWindow\dist\NormalWindow.jar
    D:\src\java\NormalWindow\dist\README.TXT
    D:\src\java\NormalWindow\dist\_normalwindow.jar
    D:\src\java\NormalWindow\dist\lib\swing-layout-1.0.jar
    D:\src\java\NormalWindow\nbproject\build-impl.xml
    D:\src\java\NormalWindow\nbproject\genfiles.properties
    D:\src\java\NormalWindow\nbproject\project.properties
    D:\src\java\NormalWindow\nbproject\project.xml
    D:\src\java\NormalWindow\nbproject\private\private.properties
    D:\src\java\NormalWindow\nbproject\private\private.xml
    D:\src\java\NormalWindow\src\normalwindow\global.java
    D:\src\java\NormalWindow\src\normalwindow\NormalWindow.form
    D:\src\java\NormalWindow\src\normalwindow\NormalWindow.java
    D:\src\java\NormalWindow\src\normalwindow\PasswordDialog.form
    D:\src\java\NormalWindow\src\normalwindow\PasswordDialog.java
    </listing>
    <listing foldername="cgwindow2">
    D:\src\java\cgwindow2\build.xml
    D:\src\java\cgwindow2\manifest.mf
    D:\src\java\cgwindow2\mfile.txt
    D:\src\java\cgwindow2\UserFile.txt
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyPanel.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$1.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$10.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$11.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$12.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$13.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$14.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$2.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$3.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$4.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$5.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$6.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$7.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$8.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow$9.class
    D:\src\java\cgwindow2\build\classes\addmoney\addMoneyWindow.class
    D:\src\java\cgwindow2\build\classes\addmoney\customBorderForAddMoneyWindow.class
    D:\src\java\cgwindow2\build\classes\addmoney\global.class
    D:\src\java\cgwindow2\dist\cgwindow2.jar
    D:\src\java\cgwindow2\dist\README.TXT
    D:\src\java\cgwindow2\dist\lib\swing-layout-1.0.jar
    D:\src\java\cgwindow2\nbproject\build-impl.xml
    D:\src\java\cgwindow2\nbproject\genfiles.properties
    D:\src\java\cgwindow2\nbproject\jax-ws.xml
    D:\src\java\cgwindow2\nbproject\project.properties
    D:\src\java\cgwindow2\nbproject\project.xml
    D:\src\java\cgwindow2\nbproject\private\private.properties
    D:\src\java\cgwindow2\nbproject\private\private.xml
    D:\src\java\cgwindow2\src\addmoney\addMoneyPanel.form
    D:\src\java\cgwindow2\src\addmoney\addMoneyPanel.java
    D:\src\java\cgwindow2\src\addmoney\addMoneyWindow.form
    D:\src\java\cgwindow2\src\addmoney\addMoneyWindow.java
    D:\src\java\cgwindow2\src\addmoney\customBorderForAddMoneyWindow.java
    D:\src\java\cgwindow2\src\addmoney\global.java
    </listing>
    About my thread subject, my clients machine is a debian sarge 3.0 and when I compiled it there with ANT It says, "normalwindow" package not found. other 2 errors were due to "normalwindow".
    Edited by: mokaddim on Sep 12, 2007 2:08 PM

    Julio.Faerman wrote:
    Hello,
    I am trying to run my annotation processor using ant.
    I already built the processor, the javax.annotation.processor.Processor file is in the correct place with the correct content.
    The jar with the processor is in the classpath (i can see it in ant -v), but it does not process my classes. in fact, i get the warning:
    warning: Annotation processing without compilation requested but no processors were found.Do i have to specify -processor or -processorpath or can i just leave it to the default classpath scanning?When -processor is not given, a service loader is used to find the annotation processors (if any). In addition to the class files of the process, to allow your processor to be found as a service, make sure you've also provided the needed META-INF data in the jar file. The general service file format is described in
    http://java.sun.com/javase/6/docs/api/java/util/ServiceLoader.html
    That said, I'd recommend setting an explicit processor path separate from your general classpath.

  • Missing something on JAR creation.

    This must be a simple error I'm commiting but it has me stuck on the distribution of my application.
    Even though my app works perfectly on prompt I don't seem to be getting the right works for making the jar file for it.
    My class files are distributed like this :
    Salfoot
    Salfoot/Interface
    Salfoot/Classes
    in the root dir there is only the entry point program that then calls a start frame , etc...
    the following code is contained in this file
    prmSalfoot.java
    import javax.swing.*;
    import Salfoot.Interface.frmLogin;
    public class prmSalfoot
         frmLogin login;
         public static void main(String[] args)
              JFrame login = new frmLogin();
              login.show();
    The manifest file is as follows :
    Manifest-Version: 1.0
    Main-Class: prmSalfoot
    The jar file is generated with the following command :
    jar cmfv manifest salfoot.jar prmSalfoot.class Interface/*.class Classes/*.class
    The following command is how I'm executing the jar file :
    java -jar salfoot.jar
    And the following error is what is outputted :
    Exception in thread "main" java.lang.NoClassDefFoundError: Salfoot/Interface/frmLogin
    What I think is... that the entry-point program is found... but the classes in the packages used are not.
    What special treatment do I need to do with the packages? Is it in the manifest file that I need to make changes? Or should I make separate JAR files for each of the packages and then make a main JAR including the package JARs?
    Thanks for any enlightment.
    Y.S.

    From my understanding you don't need to have all the
    packages in the one jar file.
    The VM builds the class path from the Class-Path attribute
    specified in the manifest file. to specify files outside
    the main jar file set the Class-Path as follows.
    Class-Path: g:\server\Server.jar ..\server\Server2.jar
    this will access classes in the these jar files.
    One thing that I've found with this is that if the
    classes in these external jar files are in packages
    then a class not found error is thrown but if they are
    just classes not in packages this works find. I'm still
    doing some experimenting with this as I've only started
    using jar files.
    Any thoughts?????

  • How to put path variables into a jar?

    Hey,
    I'm writing a Java prg, that needs some path variables for the JVM. I used to
    pass them over to the JVM each time at start up. Since this solution seems
    to me slightly complex I wonder if there's no other solution like e.g. placing
    them into a .jar's manifest so that the jar has them already - might this be
    possible?
    /usr/local/java/current/bin/java
    -Djava.library.path=/mnt/.../jdk1.5.0_05/jre/lib/i386/client:/usr/.../jdk1.5.0_05/jre/lib/i386:/usr/local/java/jdk1.5.0_05/jre/../lib/i386:/usr/... -cp /mnt/.../JRI.jar:/mnt/.../apache.poi/poi-2.5.1-final-20040804.jar:/mnt/.../CSV/ostermillerutils_1_06_00.jar mainGUI.FrameMain /mnt/.../workspace/project/In case it might also be possible using just a jar, I would appreciate
    some links on how to do that, TIA!!!

    Well I thought about that, since I'm working under linux a start.sh script serves
    qutie well. I'd like to use the prg also under windows but thought a start.bat
    might rather be discouraged?!
    I thought about writing an installer or just using one of the already existing installer projects, to set up those paths in the manifest of the jar directly each time it get installed - the problem is I need these absolute paths, since the prg depends on some another prg, which could be situated on a different position depending on the system and installation...
    Thus I'd like to know, is it possible to set path variables in a manifest's jar at all?
    Is this still a bad idea? why?
    Since this is the first time I try to do things like that, what might be an elegant solution for that issue?

  • .JAR woes. It just refuses to work for me :-(

    I spent a week building a simple java app from a C program I wrote a couple of years ago. The process has not been without tears, but I've enjoyed it. That is, up until the point of trying to make it into an 'executable' jar file. No matter what I do, it would refuse to launch and give 'can't find blah..' errors. After a couple of days of this and getting nowhere, it's starting to hack me off seriously.
    To wipe out any oddness with my immature Java code, I dropped back to a 'hello world' basic program and tried again - but I still cannot get a working .jar out of it...
    PLATFORM: Debian Linux
    java version "1.6.0_14"
    Java(TM) SE Runtime Environment (build 1.6.0_14-b08)
    Java HotSpot(TM) Server VM (build 14.0-b16, mixed mode)
    This is what I've done - can anyone spot the error?
    Directory /develop/java/package1
    contains:
    HelloWorld.java
    HelloWorld.java
    public class HelloWorld {
        public static void main(String[] args) {
            System.out.println("Hello, World!");
    }This compiles to HelloWorld.class and it runs without any issue with:
    java HelloWorld
    from inside the /develop/java/package1
    {funny enough from anywhere else in the filesystem it *wont* run - eg: java /develop/java/package1/HelloWorld - I'm not sure if that is relevant or standard Java security}
    I have a manifest creation file in the parent directory (/develop/java/) that looks like this:
    Main-Class: HelloWorld.classTo give it an Entry Point.
    I try to create a simple executable .jar by running the command:
    jar vcmf manifest HelloWorld.jar package1From the: /develop/java/ directory. This runs without error and creates HelloWorld.jar
    jar vcmf manifest HelloWorld.jar package1
    added manifest
    adding: package1/(in = 0) (out= 0)(stored 0%)
    adding: package1/HelloWorld.java(in = 124) (out= 101)(deflated 18%)
    adding: package1/HelloWorld.class(in = 427) (out= 289)(deflated 32%)
    Checking the /META-INF/MANIFEST.MF shows:
    Manifest-Version: 1.0
    Created-By: 1.6.0_14 (Sun Microsystems Inc.)
    Main-Class: HelloWorld.classBut trying to execute it with: java -jar HelloWorld.jar throws:
    Exception in thread "main" java.lang.NoClassDefFoundError: HelloWorld/class
    Caused by: java.lang.ClassNotFoundException: HelloWorld.class
         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: HelloWorld.class. Program will exit.
    I've tried altering paths, where I create the jar from etc, but it persists and after days of looking at this, I'm starting to wish I never bothered. What the hell am I missing here? It has to be staring me in the face?

    mike120 wrote:
    package1 is the directory - not a package name (that is, part of the path) - sorry for any confusion.It does not matter. The directory in the Jar, and the package name, must be identical. So do it one way or the other.
    1) package1 package.
    Source:
    package package1;
    public class HelloWorld {
        public static void main(String[] args) {
            System.out.println("Hello, World!");
    Jar content:
    jar tvf HelloWorld.jar
    0 Tue Dec 01 09:16:58 GMT 2009 META-INF/
    95 Tue Dec 01 09:16:58 GMT 2009 META-INF/MANIFEST.MF
    0 Tue Dec 01 08:24:14 GMT 2009 package1/
    124 Tue Dec 01 08:24:12 GMT 2009 package1/HelloWorld.java
    427 Tue Dec 01 08:24:14 GMT 2009 package1/HelloWorld.class
    Manifest:
    Main-Class: package1.HelloWorld2) No package.
    Source:
    public class HelloWorld {
        public static void main(String[] args) {
            System.out.println("Hello, World!");
    Jar content:
    jar tvf HelloWorld.jar
    0 Tue Dec 01 09:16:58 GMT 2009 META-INF/
    95 Tue Dec 01 09:16:58 GMT 2009 META-INF/MANIFEST.MF
    124 Tue Dec 01 08:24:12 GMT 2009 HelloWorld.java
    427 Tue Dec 01 08:24:14 GMT 2009 HelloWorld.class
    Manifest:
    Main-Class: HelloWorld

  • Modifying existing jar file, how?

    Hi there,
    I have a problem trying to modify an existing jar file. When I want to create a jar file, I use something like:
    REM build the application on windows, assuming the java/bin
    REM directory is in the path environment variable
    REM application is just the directory I am using
    SET cp = c:\application\TestApp
    javac -classpath %cp% TestApp.java
    REM ****************************************
    REM do packaging and adding manifest
    REM ****************************************
    jar cvfm App.jar manifest.mf TestApp*.class
    REM ****************************************
    REM run the jar file
    REM ****************************************
    javaw -jar App.jar
    But now, I have an existing jar file (swingall.jar) and I want to modify a class within that file. So, I modified the .java file, and compiled it to get my new class file.
    And the question is, how do I modify the existing file, so that I keep everything the same, except the modified class?
    Thanks
    Fernando

    I have just found out that I can't use "u". It seemsthat's only
    possible with older versions of jar.Huh? I'm using the 1.4.2-b28 jdk, it's still there,
    and I don't see how it could ever possibly be
    removed.
    Type:
    jar
    with no arguments to see all the options to jar.I already did, to double check it, and this is what I got:
    C:\Documents and Settings\Fernando Sanz>jar
    Usage: jar {ctx}[vfm0M] [jar-file] [manifest-file] files ...
    Options:
    -c create new archive
    -t list table of contents for archive
    -x extract named (or all) files from archive
    -v generate verbose output on standard error
    -f specify archive file name
    -m include manifest information from specified manifest file
    -0 store only; use no ZIP compression
    -M Do not create a manifest file for the entries
    If any file is a directory then it is processed recursively.
    The manifest file name and the archive file name needs to be specified
    in the same order the 'm' and 'f' flags are specified.
    Example: to archive two class files into an archive called classes.jar:
    jar cvf classes.jar Foo.class Bar.class
    Note: use the '0' option to create a jar file that can be put in your CLASSPATH
    Thanks for trying with jdk 1.4, I don't have it installed in my computer right now, so I'll try tomorrow with another computer at Uni.
    Thanks!

  • Creation of jar files

    i am using the command jar cvf HelloApplet.jar hello/HelloApplet*.class in my ms-dos prompt in windows xp, it displays message invalid command. Kindly help me how to create jar files in javafx in javafx sdk using dos prompt

    i did as you mentioned in the reply but another problem which is coming is as:
    C:\Program Files\JavaFX\javafx-sdk1.0\bin\hello>jar cvf HelloApplet.jar hello/He
    lloApplet*.class
    hello\HelloApplet*.class : no such file or directory
    added manifest
    the jar file is being created but the index.html file which uses it can't display it. can anyone also see this html file whether it is right or not also please someone tell me hoe to uase javafx in an html page.
    <html>
    <head>
    <title>Wiki</title>
    </head>
    <body>
    <h1>Wiki</h1>
    <script src="dtfx.js"></script>
    <script>
    javafx(
    archive: "HelloApplet.jar",
    draggable: true,
    width: 150,
    height: 100,
    code: "hello.HelloApplet",
    name: "Wiki"
    </script>
    </body>
    </html>

Maybe you are looking for

  • No audio on screen capture

    has it been resolved yet why there is no sound when you use screen capture? i wanted to take some youtube videos and put them together, but i also want the sound.

  • How to access my iwork through icloud drive

    Could you please tel me how I can access my iwork from icloud drive using an ipad? please!

  • How to get the distinct values in Attribute View?

    Hi, While doing the data preview of attribute view its showing duplicate records. Can i restrict all these duplicate in attribute view and get only distinct values? Thanks in advance.

  • Official Remito Numbers Missing

    Dear Sapiants, While posting delivery document official Remito number (stores in LIKP-XBLNR) is skipped by one number i.e., instead of running number of 12066 it is given 12067 number (Production client). But 12066 is not posted with any document. Si

  • Bought Droid 3 BOGO - Is it possible to sell the extra one?

    Greetings, early august i decided to upgrade to a droid 3(Buy on get one free)  and  had intentions of possibly activating the extra one for my son. Now that the bionic is out, I'd like to sell my EXTRA droid 3 via ebay or craigslist. IS there anythi