RFR: JDK-8191856 "make clean-test" does not work properly

Magnus Ihse Bursie magnus.ihse.bursie at oracle.com
Mon Nov 27 10:30:23 UTC 2017


On 2017-11-25 00:19, Martin Buchholz wrote:
> Should all phony targets be listed in a .PHONY line?
Yes, that's our policy. We do that using the ALL_TARGETS variable, which 
has a
.PHONY: $(ALL_TARGETS)
rule at the end.

Things can break subtly if you don't have phony targets declared as such.

/Magnus

>
> On Fri, Nov 24, 2017 at 2:45 AM, Magnus Ihse Bursie 
> <magnus.ihse.bursie at oracle.com <mailto:magnus.ihse.bursie at oracle.com>> 
> wrote:
>
>     With the new layout of make run-test, the test-results and
>     test-support directories are not removed by "make clean-test", and
>     not even "make clean".
>
>     Bug: https://bugs.openjdk.java.net/browse/JDK-8191856
>     <https://bugs.openjdk.java.net/browse/JDK-8191856>
>     Patch inline:
>     diff --git a/make/Main.gmk b/make/Main.gmk
>     --- a/make/Main.gmk
>     +++ b/make/Main.gmk
>     @@ -1049,7 +1049,7 @@
>      # file.
>
>      CLEAN_DIRS += hotspot jdk bootcycle-build test buildtools support \
>     -    images make-support test-make bundles buildjdk
>     +    images make-support test-make bundles buildjdk test-results
>     test-support
>      CLEAN_DIR_TARGETS := $(addprefix clean-, $(CLEAN_DIRS))
>      CLEAN_SUPPORT_DIRS += demos
>      CLEAN_SUPPORT_DIR_TARGETS := $(addprefix clean-,
>     $(CLEAN_SUPPORT_DIRS))
>     @@ -1094,6 +1094,8 @@
>      # while classes and touch files end up in jdk.
>      clean-support: clean-jdk
>
>     +clean-test: clean-test-results clean-test-support
>     +
>      # Remove everything, including configure configuration. If the output
>      # directory was created by configure and now becomes empty,
>     remove it as well.
>      dist-clean: clean
>
>     /Magnus
>
>




More information about the build-dev mailing list