From: Emmanuel Bourg Date: Wed, 23 Apr 2025 23:57:46 +0000 (+0200) Subject: Makes the generated module-info.java files reproducible (removes a captured build... X-Git-Tag: archive/raspbian/21.0.7+6-1+rpi1^2~21 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=a2ee24a175b390e42278465d9d7af0d46e933dde;p=openjdk-21.git Makes the generated module-info.java files reproducible (removes a captured build path) Forwarded: no Gbp-Pq: Name reproducible-module-info.diff --- diff --git a/make/jdk/src/classes/build/tools/module/GenModuleInfoSource.java b/make/jdk/src/classes/build/tools/module/GenModuleInfoSource.java index ce9b94db7..fa34d9222 100644 --- a/make/jdk/src/classes/build/tools/module/GenModuleInfoSource.java +++ b/make/jdk/src/classes/build/tools/module/GenModuleInfoSource.java @@ -156,9 +156,10 @@ public class GenModuleInfoSource { if (l.trim().startsWith("module ")) { if (debug) { // print URI rather than file path to avoid escape - writer.format(" // source file: %s%n", sourceFile.toUri()); + String buildPath = System.getProperty("user.dir").replaceAll("make$", ""); + writer.format(" // source file: %s%n", sourceFile.toUri().toString().replace(buildPath, "")); for (Path file : extraFiles) { - writer.format(" // %s%n", file.toUri()); + writer.format(" // %s%n", file.toUri().toString().replace(buildPath, "")); } } break;