This discussion is archived
7 Replies Latest reply: Sep 21, 2010 7:04 AM by DarrylBurke RSS

Compile a jar file

843849 Newbie
Currently Being Moderated
I hope this is in the right forum.

I have make some changes to a jar file, but now when I want to compile it it gives me an error "Path not found.

The bat with my code and the jar file is in the same folder.

Here are my code, I think it is correct.

"C:\Program Files\Java\jdk1.6.0_23\bin\jar.exe" cfm C:\Bybel\Afrikaans.jar META-INF\MANIFEST.MF

  • 1. This Thread is now moved
    DarrylBurke Guru Moderator
    Currently Being Moderated
    Note: This thread was originally posted in the [Java Programming|http://forums.sun.com/forum.jspa?forumID=31] forum, but moved to this forum for closer topic alignment.
  • 2. Re: Compile a jar file
    EJP Guru
    Currently Being Moderated
    Is there a directory called META containing a file called MANIFEST.MF in the current working directory when you execute this command?
  • 3. Re: Compile a jar file
    843849 Newbie
    Currently Being Moderated
    No the Manifest,mf file is in the jar file that I need to compile, it I just make a jar file and load it into the phone it gives compile error.

    I did make a folder Manifest and put the file manifest.mf in the folder.

    The bat file is running now, but it makes the jar file only 1byte now.

    Edited by: Hendrikbez on Sep 21, 2010 12:49 AM
  • 4. Re: Compile a jar file
    EJP Guru
    Currently Being Moderated
    No the Manifest,mf file is in the jar file
    So why are you naming it on the command line?
    I did make a folder Manifest and put the file manifest.mf in the folder.
    Yet on the command line you didn't say Manifest/MANIFEST.MF. You said META-INF/MANIFEST.MF. Which won't work, because according to this it doesn't exist.
    that I need to compile
    You don't compile JAR files. You create them.
    it I just make a jar file and load it into the phone it gives compile error.
    The phone has a compiler in it?

    You seem to be using the word 'compile' pretty indiscrimately.
  • 5. Re: Compile a jar file
    DarrylBurke Guru Moderator
    Currently Being Moderated
    Hendrikbez wrote:
    I just make a jar file and load it into the phone it gives compile error.
    Is this question related to Java SE or Java ME?

    db
  • 6. Re: Compile a jar file
    843849 Newbie
    Currently Being Moderated
    Sorry it is Java ME
  • 7. This Thread is now moved
    DarrylBurke Guru Moderator
    Currently Being Moderated
    Note: This thread was originally posted in the [New To Java|http://forums.sun.com/forum.jspa?forumID=54] forum, but moved to this forum for closer topic alignment.