Mercurial > hg > release > icedtea8-forest-3.0 > langtools
changeset 3039:3e7e24ba545b
Merge
author | asaha |
---|---|
date | Thu, 23 Jul 2015 11:23:43 -0700 |
parents | bd3a79fc440c (current diff) f04dde94d22b (diff) |
children | c53340cb2c01 |
files | .hgtags |
diffstat | 2 files changed, 20 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/.hgtags Mon Jul 20 09:10:39 2015 -0700 +++ b/.hgtags Thu Jul 23 11:23:43 2015 -0700 @@ -449,6 +449,7 @@ d1febf79ce5ea41fb4b818ffd3589cf923e6de5f jdk8u60-b22 7f88b5dc78cebc2c5ebb716938fd9a7632b052b2 jdk8u60-b23 2af11e10da7dc24610551bbeed02c4ca3f4ae654 jdk8u60-b24 +8d152d1e45944616309886e730ffcbfb5c078d22 jdk8u60-b25 779397f90251ea813cb44621dc27f780e5c20449 jdk8u52-b06 e0ce6be9142ed1e2f0ce3ee13090ec01c6c44721 jdk8u52-b07 779397f90251ea813cb44621dc27f780e5c20449 jdk8u65-b00 @@ -457,6 +458,7 @@ 0e03089b5bb37450c7bcab8fc9cb0912e24fe681 jdk8u65-b03 b90367f392f5d7af47c26bae5493adc73a865c70 jdk8u65-b04 b2e8d2c5636f5f98a10b9e800ea10e0fe4c265c3 jdk8u65-b05 +ae5e31450299f6c265df24ed155acd650fb3bffd jdk8u65-b06 d1febf79ce5ea41fb4b818ffd3589cf923e6de5f jdk8u66-b00 4c13b9cd06222be73b9c44607ae929b4818aed17 jdk8u66-b01 aaad025819b721f7f291048a07cd1c144319b68d jdk8u71-b00
--- a/test/tools/javac/links/LinksTest.java Mon Jul 20 09:10:39 2015 -0700 +++ b/test/tools/javac/links/LinksTest.java Thu Jul 23 11:23:43 2015 -0700 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,6 +30,7 @@ * @run main LinksTest */ +import java.io.IOException; import java.nio.file.Files; import java.nio.file.Paths; @@ -48,19 +49,26 @@ throws Exception { // mkdir tmp // cp ${TESTSRC}/b/B.java tmp - ToolBox.writeFile(Paths.get("tmp", "B.java"), BSrc); + ToolBox.writeFile(Paths.get("tmp/B.java"), BSrc); + // Try to set up a symbolic link for the test. +// ln -s `pwd`/tmp "${TESTCLASSES}/a" try { -// ln -s `pwd`/tmp "${TESTCLASSES}/a" Files.createSymbolicLink(Paths.get("a"), Paths.get("tmp")); - ////"${TESTJAVA}/bin/javac" ${TESTTOOLVMOPTS} -sourcepath "${TESTCLASSES}" -d "${TESTCLASSES}/classes" "${TESTSRC}/T.java" 2>&1 - ToolBox.JavaToolArgs javacArgs = - new ToolBox.JavaToolArgs() - .setOptions("-sourcepath", ".", "-d", ".").setSources(TSrc); - ToolBox.javac(javacArgs); - } catch (UnsupportedOperationException e) { - System.err.println("Symbolic links not supported on this system. The test can't finish"); + System.err.println("Created symbolic link"); + } catch (UnsupportedOperationException | IOException e) { + System.err.println("Problem creating symbolic link: " + e); + System.err.println("Test cannot continue; test passed by default"); + return; } + + // If symbolic link was successfully created, + // try a compilation that will use it. + ////"${TESTJAVA}/bin/javac" ${TESTTOOLVMOPTS} -sourcepath "${TESTCLASSES}" -d "${TESTCLASSES}/classes" "${TESTSRC}/T.java" 2>&1 + ToolBox.JavaToolArgs javacArgs = + new ToolBox.JavaToolArgs() + .setOptions("-sourcepath", ".", "-d", ".").setSources(TSrc); + ToolBox.javac(javacArgs); } }