• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Creating Jars from NetBeans

 
Bartender
Posts: 2205
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Does anyone have any experience creating Jar files from NetBeans?
I'm getting an error when I compile my Jar recipie :


duplicate entry: META-INF/MANIFEST.MF
This prevents the contents of the archive from being updated.


I'm trying to bundle all my compiled .class files, as well as all the .jar files my classes are using, into one jar, with a main class selected so that I can execute by just double-clicking the finished jar file.
I have to admit, I haven't really created jar files a lot, and have never had to make a manifest file, so I don't know if I'm doing something wrong. I do know that all the jars I am including along with my class files each have their own manifest, but that should not be a problem because I can successfully build the same jar from ANT or from JBuilder, and our team also can build it from MetroWorks, so that tells me it's an issue with NetBeans.
Any ideas?
Thanks!
 
Rob Ross
Bartender
Posts: 2205
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Still having problems here with Jar files. Anyone know how to make jar files in NetBeans?
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Rob Ross:
Still having problems here with Jar files. Anyone know how to make jar files in NetBeans?


I have the same problem.Anyone helps me?Thanks.
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by yangyu:

I have the same problem.Anyone helps me?Thanks.


This is because you try to include multiple jar files which all have the MANIFEST.MF entry.. and since netbeans unjars them it tries to put it all into same directory (that is what I think happens) and therefore this message..
well, thats at least what my problem where when I got exactly the above message..
 
Ranch Hand
Posts: 2676
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
yangyu,
We don't have many rules at Javaranch, but our display name policy is one of them. Please read this policy and change your display name to comply with it if you wish to continue posting. Thanks.
You can change your display name here.
 
reply
    Bookmark Topic Watch Topic
  • New Topic