title: problem with setting the class path in manifest.mf within jar file
body: <p>I have created the jar file,and I run it using command:-</p>
  
  <blockquote>
    <blockquote>
      <p>java -jar /usr/local/bin/niidle.jar arguments...</p>
    </blockquote>
  </blockquote>
  
  <p>then I got this error----
  Exception in thread "main" java.lang.NoClassDefFoundError: me/prettyprint/hector/api/Serializer
      at com.ensarm.niidle.web.scraper.NiidleScrapeManager.main(NiidleScrapeManager.java:21)
  Caused by: java.lang.ClassNotFoundException: me.prettyprint.hector.api.Serializer
      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)</p>
  
  <h1>    ... 1 more</h1>
  
  <p>I removed this error by mentioning the full class path name,
  Class-Path=/Projects/EnwelibDatedOct13/Niidle/lib/hector-0.6.0-17.jar  in MANIFEST.MF.
  And now when I run it by using command:-</p>
  
  <blockquote>
    <blockquote>
      <p>java -cp /Projects/EnwelibDatedOct13/Niidle/lib/hector-0.6.0-17.jar -jar /usr/local/bin/niidle.jar arguments...</p>
      
      <h1>its working properly.</h1>
    </blockquote>
  </blockquote>
  
  <p>But I want to mention only jar file name "hector-0.6.0-17.jar" in Class-Path in MANIFEST.MF.If I give full class path,then it will not work on others machine.And 
  I have to run this jar on others machine.
  And when I mention only jar file name "hector-0.6.0-17.jar",and I run it using command:-</p>
  
  <blockquote>
    <blockquote>
      <p>java -cp /Projects/EnwelibDatedOct13/Niidle/lib/hector-0.6.0-17.jar -jar /usr/local/bin/niidle.jar arguments...
      it is showing me same error message:-</p>
    </blockquote>
  </blockquote>
  
  <p>--Exception in thread "main" java.lang.NoClassDefFoundError: me/prettyprint/hector/api/Serializer
      at com.ensarm.niidle.web.scraper.NiidleScrapeManager.main(NiidleScrapeManager.java:21)
  Caused by: java.lang.ClassNotFoundException: me.prettyprint.hector.api.Serializer
      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)</p>
  
  <h1>    ... 1 more</h1>
  
  <p>I dont want to mention full class path name in MANIFEST.MF,so please tell me solution for this, or how to set only jar file name "hector-0.6.0-17.jar" to
  Class-Path in MANIFEST.MF in the jar.</p>