Hey everyone,
I”m trying for the first time to build a native installer of my application
and am running into some errors I wonder if you guys can help with.  First
my environment: macOS 11.3 and NB 12.3 running on JRE 14 with a non-modular
JDK16-based project (which depends on another JDK16-based SE NP project).
Everything’s been building/running fine.

Then, when I go to Project->Properties->Packaging, I checked:
- Build JAR after compiling
- Copy Dependent Libraries
- Create JLINK distribution
and in Properties->Deployment, I checked “Enable Native Packaging in
Project Menu”.

But when I go to the Project->Package As->DMG Image or Project->Package
As->All Installers, I see this error at the end (see full output below):
...
Created dir: /Users/twolf/NetBeansProjects/swing_app/dist
/Users/twolf/NetBeansProjects/swing_app/nbproject/build-native.xml:428: The
following error occurred while executing this line:
/Users/twolf/NetBeansProjects/swing_app/nbproject/build-native.xml:436:
Unable to create javax script engine for javascript
BUILD FAILED (total time: 3 seconds)

The first error message comes from a target that seems to do with javafx
copying:
    <target name="-jfx-copylibs"
depends="init,compile,-pre-pre-jar,-pre-jar,-jfx-copylibs-warning"
unless="fallback.no.javascript">
        <jfx-copylibs-js-impl/>
    </target>
The second line is in a macrodef also to do with jfx:
<pathconvert property="run.classpath.without.build.classes.and.dist.dir">

Can anyone provide a pointer as to what I’m doing wrong?  Any help much
appreciated.
Thanks,
Tom W.

ant -f /Users/twolf/NetBeansProjects/swing_app -Djar.archive.disabled=true
-Dnative.bundling.type=dmg build-native
Detected JavaFX Ant API version 1.0
init:
deps-clean:
Updating property file:
/Users/twolf/NetBeansProjects/swing_app/build/built-clean.properties
Importer.init:
Importer.deps-clean:
Updating property file:
/Users/twolf/NetBeansProjects/swing_app/build/built-clean.properties
Deleting directory /Users/twolf/NetBeansProjects/Importer/build
Importer.clean:
Deleting directory /Users/twolf/NetBeansProjects/swing_app/build
clean:
deps-jar:
Created dir: /Users/twolf/NetBeansProjects/swing_app/build
Updating property file:
/Users/twolf/NetBeansProjects/swing_app/build/built-jar.properties
Importer.init:
Importer.deps-jar:
Created dir: /Users/twolf/NetBeansProjects/Importer/build
Updating property file:
/Users/twolf/NetBeansProjects/swing_app/build/built-jar.properties
Created dir: /Users/twolf/NetBeansProjects/Importer/build/classes
Created dir: /Users/twolf/NetBeansProjects/Importer/build/empty
Created dir:
/Users/twolf/NetBeansProjects/Importer/build/generated-sources/ap-source-output
Compiling 31 source files to
/Users/twolf/NetBeansProjects/Importer/build/classes
warning: [options] system modules path not set in conjunction with -source
14
1 warning
Copying 24 files to /Users/twolf/NetBeansProjects/Importer/build/classes
Importer.compile:
Created dir: /Users/twolf/NetBeansProjects/Importer/dist
Copying 1 file to /Users/twolf/NetBeansProjects/Importer/build
Copy libraries to /Users/twolf/NetBeansProjects/Importer/dist/lib.
Building jar: /Users/twolf/NetBeansProjects/Importer/dist/Importer.jar
To run this application from the command line without Ant, try:
java -jar "/Users/twolf/NetBeansProjects/Importer/dist/Importer.jar"
Importer.deploy:
Importer.jar:
Created dir: /Users/twolf/NetBeansProjects/swing_app/build/classes
Created dir: /Users/twolf/NetBeansProjects/swing_app/build/empty
Created dir:
/Users/twolf/NetBeansProjects/swing_app/build/generated-sources/ap-source-output
Compiling 70 source files to
/Users/twolf/NetBeansProjects/swing_app/build/classes
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Copying 70 files to /Users/twolf/NetBeansProjects/swing_app/build/classes
Copied 10 empty directories to 2 empty directories under
/Users/twolf/NetBeansProjects/swing_app/build/classes
compile:
Created dir: /Users/twolf/NetBeansProjects/swing_app/dist
/Users/twolf/NetBeansProjects/swing_app/nbproject/build-native.xml:428: The
following error occurred while executing this line:
/Users/twolf/NetBeansProjects/swing_app/nbproject/build-native.xml:436:
Unable to create javax script engine for javascript
BUILD FAILED (total time: 3 seconds)

Reply via email to