You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bo...@apache.org on 2017/12/19 11:53:21 UTC

ant git commit: try to disable cache conditionally

Repository: ant
Updated Branches:
  refs/heads/master 3dad11d41 -> a8bbb8be5


try to disable cache conditionally


Project: http://git-wip-us.apache.org/repos/asf/ant/repo
Commit: http://git-wip-us.apache.org/repos/asf/ant/commit/a8bbb8be
Tree: http://git-wip-us.apache.org/repos/asf/ant/tree/a8bbb8be
Diff: http://git-wip-us.apache.org/repos/asf/ant/diff/a8bbb8be

Branch: refs/heads/master
Commit: a8bbb8be52c3c97451b97169b28c06a441327d9d
Parents: 3dad11d
Author: Stefan Bodewig <bo...@apache.org>
Authored: Tue Dec 19 12:53:01 2017 +0100
Committer: Stefan Bodewig <bo...@apache.org>
Committed: Tue Dec 19 12:53:01 2017 +0100

----------------------------------------------------------------------
 build.xml | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ant/blob/a8bbb8be/build.xml
----------------------------------------------------------------------
diff --git a/build.xml b/build.xml
index 0939eb5..c4e3526 100644
--- a/build.xml
+++ b/build.xml
@@ -1620,6 +1620,11 @@ ${antunit.reports}
 
   <target name="test-init" depends="probe-offline,check_for_optional_packages">
     <mkdir dir="${build.junit.tmpdir}"/>
+    <condition property="sun.io.useCanonCaches" value="false">
+      <not>
+        <javaversion atleast="9"/>
+      </not>
+    </condition>
     <macrodef name="test-junit">
       <element name="junit-nested" implicit="true" />
       <sequential>
@@ -1665,8 +1670,11 @@ ${antunit.reports}
           <sysproperty key="tests.and.ant.share.classloader"
                        value="${tests.and.ant.share.classloader}"/>
           <sysproperty key="java.io.tmpdir" file="${build.junit.tmpdir}"/>
-          <sysproperty key="sun.io.useCanonCaches" value="false"/>
-          <sysproperty key="sun.io.useCanonPrefixCache" value="false"/>
+          <!-- in Java8 the canonical cache seems to interfere with
+               our symlink tests -->
+          <syspropertyset>
+            <propertyref name="sun.io.useCanonCaches"/>
+          </syspropertyset>
           <classpath>
             <path refid="tests-runtime-classpath"/>
             <pathelement location="${junit.collector.dir}"/>