Im trying to run launch4j as a build task on macosx but im getting the following exception:
/Users/myname/Desktop/build/buildarms2jar.xml:67: net.sf.launch4j.BuilderException: net.sf.launch4j.ExecException: java.io.IOException: Cannot run program "/Users/myname/Desktop/launch4j/launch4j/bin/windres": error=2, No such file or directory
the file paths are correct. I read that this may be a problem with running windres but I wasn't able to find a solution for it. Does anyone know how to fix this?
Ant File:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project default="create_run_jar" name="Create Runnable Jar for Project ARMS2 with Jar-in-Jar Loader">
<!--this file was created by Eclipse Runnable JAR Export Wizard-->
<!--ANT 1.7 is required -->
<property name="releasedest" value="../release/"/>
<property name="data" value="../data/" />
<property name="config" value="../config/" />
<property name="launch4j.dir" location="../launch4j" />
<property name="version" value="1.0.0" />
<property name="textfileversion" value="1.0.0" />
<target name="create_run_jar">
<jar destfile="${releasedest}test.jar">
<manifest>
<attribute name="Main-Class" value="org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoader"/>
<attribute name="Rsrc-Main-Class" value="com.domain.RadialUIController"/>
<attribute name="Class-Path" value="."/>
<attribute name="Rsrc-Class-Path" value="./ worldwind.jar gluegen-rt.jar jogl.jar AnimatedTransitions-0.11.jar TimingFramework-1.0.jar commons-lang-2.5.jar commons-io-2.0.1.jar SiteMetaData.jar xbean.jar substance.jar trident.jar batik-awt-util.jar batik-dom.jar batik-svg-dom.jar batik-svggen.jar batik-util.jar batik-xml.jar icepdf-core.jar icepdf-viewer.jar ridl.jar unoloader.jar jurt.jar java_uno.jar juh.jar officebean.jar unoil.jar"/>
</manifest>
</jar>
</target>
<copy todir="${releasedest}">
<fileset dir="${data}" />
</copy>
<copy todir="${releasedest}/config">
<fileset dir="${config}" />
</copy>
<copy file="DataSetup.txt" todir="${releasedest}" />
<taskdef name="launch4j"
classname="net.sf.launch4j.ant.Launch4jTask"
classpath="${launch4j.dir}/launch4j/launch4j.jar
:${launch4j.dir}/launch4j/lib/xstream.jar" />
<launch4j configFile="${launch4j.dir}/TestConfig.xml" jar="${releasedest}/test.jar" />
<copy file="test.exe" todir="${releasedest}" />
</project>
Well this is embarrassing...I had the wrong launch4j distribution....I downloaded the macosx distribution and it worked.....