SOLVED

I have solved the problem.  There may be a minor bug to be addressed
depending on one's view about reducing the likelihood of users making
avoidable mistakes..

If one create a non-modular application the Netbeans Ant scripts skip
generating the jlink image.  This makes sense as jlink images need to
select the modules used by the application to avoid drawing in the whole
JRE.

I suggest the minor bug was that a non-modular application allowed the user
to check the Create jlink box on without a warning. I do not know if
detecting whether the application has a modular structure in a reliable
manner is particularly easy.  Could it be as simple as displaying a warning
recommending the user converts the application into a modular application
if the Create jlink box is enabled but no module-info.java file?

Regards

Emma




On Thu, 18 Jul 2019 at 11:38, Emma Atkinson <[email protected]>
wrote:

> Hello
> I do not know if this is a bug.  I have checked JIRA and nothing appeared
> to me.
>
> I am using Product Version: Apache NetBeans IDE 11.0 (Build
> incubator-netbeans-release-404-on-20190319) on JDK-11.
>
> Create New Project
> Select "Java with Ant
> Select "Java Application"
> Accept all defaults and tick box "Create Main Class"
> Go to Project Properties > Build > Packaging
> Enable the box "Create JLINK distribution"
> Enable "Create Launcher"
> Click OK to save properties.
> Using RMB select "Clean and Build"
> The Output window shows
> <snip>
> To run this application from the command line without Ant, try:
> /usr/java/jdk-11/bin/java -cp
> /home/emma/NetBeansProjects/JavaApplication28/dist/JavaApplication28.jar
> javaapplication28.JavaApplication28
> -init-macrodef-copylibs:
> creating macro  http://www.netbeans.org/ns/j2se-project/3:copylibs
> -do-jar-copylibs:
> Skipped because property 'do.mkdist' not set.
> -do-jar-delete-manifest:
> Deleting /home/emma/NetBeansProjects/JavaApplication28/build/null939241021
> -do-jar-without-libraries:
> -do-jar-with-libraries:
> -post-jar:
> -do-jar:
> -pre-deploy:
> -check-jlink:
>
>
> *-do-deploy:Skipped because property 'do.jlink.internal' not
> set.-post-deploy:*
> deploy:
> jar:
> BUILD SUCCESSFUL (total time: 0 seconds)
>
> The build script does not build a jlink image.
> I cannot find property* 'do.jlink.internal' *anywhere.
>
> I have built a jlink image successfully in one of the previous Netbeans
> versions but cannot recall how I did it.
>
> Any clues on investigating this matter would be appreciated.
>
> Thank you.
>
>
>
>
>
>

Reply via email to