RFR: JDK-8257547: Handle multiple prereqs on the same line in deps files [v2]

Tim Bell tbell at openjdk.java.net
Wed Dec 2 20:03:56 UTC 2020


On Wed, 2 Dec 2020 17:55:18 GMT, Erik Joelsson <erikj at openjdk.org> wrote:

>> After fixing JDK-8256810 and starting to look into backporting it, I discovered more potential failing cases. Certain versions of GCC may sometimes output multiple prerequisite files on the same line. I think the easiest way to handle this new issue is to split such lines.
>> 
>> When splitting lines, we need to make sure to not just split on any space. Some compilers output the : of the rule with a leading space, and already split lines will have a space before the backslash.
>
> Erik Joelsson has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Added test

test/make/TestFixDepsFile.gmk line 60:

> 58: 	$(ECHO) " $(WORKSPACE_ROOT)/bar/baz \\" >> $(DEPS_FILE).expected
> 59: 	$(ECHO) " /foo/baz" >> $(DEPS_FILE).expected
> 60: 	$(DIFF) $(DEPS_FILE).expected $(DEPS_FILE)

Does this need to be:
$(DIFF) $(DEPS_FILE).expected $(DEPS_FILE).tmp

-------------

PR: https://git.openjdk.java.net/jdk/pull/1548



More information about the build-dev mailing list