adding classpath to Manfiest of yacycore.jar

- this allows to start w/o giving explicite java -cp (just java -jar lib/yacycore.jar works)
- especially helpful while running YaCy as Win service, 
  making it obsolete to adjust classpath cfg of the service wrapper on upgrades of lib/*.jar's
This commit is contained in:
reger 2013-01-29 03:01:57 +01:00
parent be27567b53
commit be5d3a1066

View File

@ -243,10 +243,22 @@
<compilerarg value="-Xlint"/>
</javac>
<!-- prepare classpath for MANIFEST (manifest cp is relative to jar) -->
<path id="project.classpath.runtime">
<fileset dir="./lib">
<include name="**/*.jar" />
<exclude name="yacycore.jar"/>
</fileset>
</path>
<pathconvert property="manifest.classpath" pathsep=" " refid="project.classpath.runtime">
<flattenmapper/>
</pathconvert>
<!-- make the jacycore jar -->
<jar destfile="${lib}/yacycore.jar" basedir="${build}/">
<manifest>
<attribute name="Main-Class" value="yacy"/>
<attribute name="Main-Class" value="net.yacy.yacy"/>
<attribute name="Class-Path" value="../htroot ${manifest.classpath}"/>
</manifest>
</jar>