This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 268489 - Cannot perform clean build
Summary: Cannot perform clean build
Status: NEW
Alias: None
Product: javafx
Classification: Unclassified
Component: Deployment (show other bugs)
Version: 8.2
Hardware: PC Windows 7 x64
: P2 normal with 2 votes (vote)
Assignee: Roman Svitanic
Depends on:
Reported: 2016-10-12 15:14 UTC by venkatasreekanth
Modified: 2018-04-18 15:07 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Note You need to log in before you can comment on or make changes to this bug.
Description venkatasreekanth 2016-10-12 15:14:01 UTC
After upgrading to JDK 8 update 101. The build scripts successfully build only the first time. From the second build it always fails with IO Exception. On the bamboo build server it fails every time.

Below is the log. if you need any further info please let me know

ant -f C:\\Users\\venkata_bhagavatula\\Documents\\NetBeansProjects\\xref_maintenance2\\CrossReference jfx-rebuild
Updating property file: C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build\
Deleting directory C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build
Created dir: C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build
Updating property file: C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build\
Created dir: C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build\classes
Created dir: C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build\empty
Created dir: C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build\generated-sources\ap-source-output
Compiling 146 source files to C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build\classes
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Copying 35 files to C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build\classes
Copying 16 files to C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\dist\lib
Detected JavaFX Ant API version 1.3
Launching <fx:jar> task from C:\Program Files\Java\jdk1.8.0_101\jre\..\lib\ant-javafx.jar
Warning: From JDK7u25 the Codebase manifest attribute should be used to restrict JAR repurposing.
         Please set manifest.custom.codebase property to override the current default non-secure value '*'.
Launching <fx:deploy> task from C:\Program Files\Java\jdk1.8.0_101\jre\..\lib\ant-javafx.jar
No base JDK. Package will use system JRE.
No base JDK. Package will use system JRE.
Could not load definitions from resource com/sun/javafx/tools/ant/antlib.xml. It could not be found.
Using base JDK at: C:\Program Files\Java\jdk1.8.0_101\jre
Using base JDK at: C:\Program Files\Java\jdk1.8.0_101\jre
Creating app bundle: CrossReference in C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\dist\bundles
Exception: Access is denied
C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\nbproject\jfx-impl.xml:3479: The following error occurred while executing this line:
C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\nbproject\jfx-impl.xml:1487: The following error occurred while executing this line:
C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\nbproject\jfx-impl.xml:3134: The following error occurred while executing this line:
C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\nbproject\jfx-impl.xml:2503: The following error occurred while executing this line:
C:\Users\venkata_bhagavatula\Documents\NetBeansProjects\xref_maintenance2\CrossReference\build.xml:70: Error: Bundler "Windows Application Image" ( failed to produce a bundle.
BUILD FAILED (total time: 6 seconds)
Comment 1 venkatasreekanth 2016-10-12 15:19:09 UTC
Here is the modified build.xml

<?xml version="1.0" encoding="UTF-8"?>
<!-- You may freely edit this file. See commented blocks below for -->
<!-- some examples of how to customize the build. -->
<!-- (If you delete it and reopen the project it will be recreated.) -->
<!-- By default, only the Clean and Build commands use this build script. -->
<!-- Commands such as Run, Debug, and Test only use this build script if -->
<!-- the Compile on Save feature is turned off for the project. -->
<!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
<!-- in the project's Project Properties dialog box.-->
<project name="CrossReference" default="default" basedir="." xmlns:fx="">
    <description>Builds, tests, and runs the project CrossReference.</description>
    <import file="nbproject/build-impl.xml"/>

    There exist several targets which are by default empty and which can be 
    used for execution of your tasks. These targets are usually executed 
    before and after some main targets. They are: 

      -pre-init:                 called before initialization of project properties
      -post-init:                called after initialization of project properties
      -pre-compile:              called before javac compilation
      -post-compile:             called after javac compilation
      -pre-compile-single:       called before javac compilation of single file
      -post-compile-single:      called after javac compilation of single file
      -pre-compile-test:         called before javac compilation of JUnit tests
      -post-compile-test:        called after javac compilation of JUnit tests
      -pre-compile-test-single:  called before javac compilation of single JUnit test
      -post-compile-test-single: called after javac compilation of single JUunit test
      -pre-jar:                  called before JAR building
      -post-jar:                 called after JAR building
      -post-clean:               called after cleaning build products

    (Targets beginning with '-' are not intended to be called on their own.)

    Example of inserting an obfuscator after compilation could look like this:

        <target name="-post-compile">
                <fileset dir="${build.classes.dir}"/>

    For list of available properties check the imported 
    nbproject/build-impl.xml file. 

    Another way to customize the build is by overriding existing main targets.
    The targets of interest are: 

      -init-macrodef-javac:     defines macro for javac compilation
      -init-macrodef-junit:     defines macro for junit execution
      -init-macrodef-debug:     defines macro for class debugging
      -init-macrodef-java:      defines macro for class execution
      -do-jar:                  JAR building
      run:                      execution of project 
      -javadoc-build:           Javadoc generation
      test-report:              JUnit report generation

    An example of overriding the target for project execution could look like this:

<target name="-post-jfx-deploy">
     <taskdef resource="com/sun/javafx/tools/ant/antlib.xml"      
            <fx:deploy width="${}" height="${}" 
                       outdir="${basedir}/${dist.dir}" outfile="${application.title}">
               <fx:application name="${application.title}" 
                <fx:platform  >
                    <fx:jvmarg  value="-Djava.util.logging.config.file=${APPDIR}\app\" />
                    <fx:jvmarg  value="Djava.library.path=src\dll" />
                    <fx:jvmarg  value="-XX:InitiatingHeapOccupancyPercent=0" />
                    <fx:jvmarg  value="-XX:MaxHeapFreeRatio=40" />
                    <fx:jvmarg value="-XX:+HeapDumpOnOutOfMemoryError" />
                    <fx:jvmarg value="-XX:-UseParallelGC" />
                    <fx:jvmarg value="-XX:+UseG1GC" />
                    <fx:jvmarg value="-Xmx8G" />
                <!-- install='true' for installation at Program Files (System level) , install='false' will install per user %appdata%' -->
                <fx:preferences  shortcut="true"  install="false" menu="true"/>
                    <fx:fileset dir="${basedir}/${dist.dir}" includes="*.jar"/>
                    <fx:fileset dir="dist" includes="lib/*.*"/>
                    <fx:fileset dir="${basedir}/properties" includes="" />
    Notice that the overridden target depends on the jar target and not only on 
    the compile target as the regular run target does. Again, for a list of available 
    properties which you can use, check the target you are overriding in the
    nbproject/build-impl.xml file. 

Comment 2 venkatasreekanth 2016-12-07 16:27:54 UTC
is there any update on this issue ?
Comment 3 Joey25 2017-02-28 16:18:27 UTC
Have the same issue. Any news on this?
Comment 4 Martin Balin 2017-05-15 13:31:55 UTC
Cannot be reproduced in 8.2 on Windows & Linux. JDK 8 Upd 131.
Comment 5 venkatasreekanth 2017-09-28 20:34:52 UTC
I am able to do it every time.What more can I do to help? it would be nice if you redesigned the build script to have no javascript in it. and made fx:deploy editable. Is there a way for me to add on to fx:deploy from within build.xml, because If I meddle with jfx-impl or build-impl netbeans overwrites it.
Comment 6 venkatasreekanth 2017-09-28 20:36:27 UTC
Also this issues is reproducible on windows 10. 

When we switched the build agent from Bamboo to TFS 2016 the builds started failing even on update 45.
Comment 7 csmart 2017-11-13 19:18:30 UTC
Have the same issue - any updates?
Comment 8 chefe 2018-04-18 15:07:31 UTC
J have the same issue. Is there some simple solution?
Comment 9 chefe 2018-04-18 15:07:55 UTC
I have the same issue. Is there some simple solution?