AdvancedInstaller version 7.7 - Polish.
I have problems with embeding jar into project. I've written large gui application
in netbeans. I used package-for-store build to include all libraries in 1 jar file.
This jar has everything in it. I've created installer and selected've Embeded JAR to my
"large file"
After installation and execution a fallowing message appears (in polish):
Klasa główna (Main Class) nie została określona w pliku INI.
In english (my translation): Main Class has no representation in INI file.
I have in jar file MANIFEST.MF (uppercase letters) with Main Class in it.
I've selected MainClass in JRE Setting in JavaProject tab in AdvancedInstaller.
I've double checked INF file - "Main Class" is there.
I've tried to create several advanced installer projects with different
setting to resolve this problem. No results.
I've checked FAQ and Howtos no answare there.
Everything works when this "largefile.jar" file is added to "Files and Folders"
and selected in Classpath (without EmbededJAR selected).
But to "virtualy" secure my jar I want it to be embeded in exe file.
My package for store ant code:
Code: Select all
<target name="package-for-store" depends="jar">
<property name="store.jar.name" value="LargeFile"/>
<!-- don't edit below this line -->
<property name="store.dir" value="store"/>
<property name="store.jar" value="${store.dir}/${store.jar.name}.jar"/>
<echo message="Packaging ${application.title} into a single JAR at ${store.jar}"/>
<delete dir="${store.dir}"/>
<mkdir dir="${store.dir}"/>
<jar destfile="${store.dir}/temp_final.jar" filesetmanifest="skip">
<zipgroupfileset dir="dist" includes="*.jar"/>
<zipgroupfileset dir="dist/lib" includes="*.jar"/>
<manifest>
<attribute name="Main-Class" value="${main.class}"/>
</manifest>
</jar>
<zip destfile="${store.jar}">
<zipfileset src="${store.dir}/temp_final.jar"
excludes="META-INF/*.SF, META-INF/*.DSA, META-INF/*.RSA"/>
</zip>
<delete file="${store.dir}/temp_final.jar"/>
</target>
FOLLOW US
Get the latest news in Application Packaging