• 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

making jar files available to javac?

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sorry, this is probably just a dumb newbie question. I'm having a problem setting up a library jar file in a windows environment. I know that this is just an issue of setting up the PATH or CLASSPATH or something else correctly but I can't seem to get it right. Any hints, suggestions, nudges or outright handholding cheerfully welcomed.
Thanks,
Frank Vandenberg
 
Ranch Hand
Posts: 529
C++ Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You can do one of 3 things:
1. Put the jar file in your system classpath, then it is available to everything all of time.
2. Type set classpath=%classpath%;C:\path\yourJar.jar from command line before running javac
3. Run javac like this:
javac -classpath C:\path\yourJar.jar yourJavaSource.java
Any of these will work. If you still have problems, give us some specifics. Hope this helps!
Barry
 
Frank Vandenberg
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for the response, I'll try these suggestions.
Frank Vandenberg
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic