0
votes

recently i was trying to make an installer for my java app using netbeans but when i click PROJECT > PACKAGES AS > ALL INSTALLERS

JavaFX native packager requires external WiX 3.0+ tools installed and included on PATH to create MSI installer. See http://wix.sourceforge.net/ BUILD FAILED (total time: 0 seconds)

Im pretty sure i have this WiX 3.0+ tools installed and i also added it on Environment Variable (i typed command candle.exe and got the expected result...please help me with this.

Thanks,

1
In case you haven't after installing WiX, restart NetBeans (or Windows). Very few running applications check for updated environment variables; They take what they are given from their creator—because it could have been customized. - Tom Blodget

1 Answers

0
votes

I've experienced the same issue having the latest version of WIX installed (3.9) and NetBeans 7.4.

In my case this was due to a string comparison problem in the file "jfx-impl.xml" in the nbproject folder. What you have to do is editing this file (clicking on the link provided by the error message in the NetBeans output console) and changing the target "-check-WiX-presence" into this:

<target name="-check-WiX-presence" depends="-check-native-bundling-type" if="need.WiX.presence">
    <local name="exec-output"/>
    <local name="exec-error"/>
    <local name="exec-result"/>
    <exec executable="candle" outputproperty="exec-output" failifexecutionfails="false" errorproperty="exec-error" resultproperty="exec-result">
        <arg value="-?"/>
    </exec>
    <echo message="exec-output:${exec-output}" level="verbose"/>
    <echo message="exec-error:${exec-error}" level="verbose"/>
    <echo message="exec-result:${exec-result}" level="verbose"/>
    <condition property="missing.WiX">
        <not><and>
            <contains string="${exec-output}" substring="Windows Installer XML" casesensitive="false"/>
            <not><contains string="${exec-output}" substring="Windows Installer Xml Compiler version 1"/></not>
            <not><contains string="${exec-output}" substring="Windows Installer Xml Compiler version 2"/></not>
        </and></not>
    </condition>
</target>