The pull request at https://github.com/openjdk/jdk/pull/16971/files has effectively addressed the issue I was facing. Thank you for your time and effort in addressing this matter!
Magnus Ihse Bursie <magnus.ihse.bur...@oracle.com> 于2023年12月5日周二 18:36写道: > On closer inspection, it would probably be more prudential to set the > value of LC_ALL to C.UTF-8 in the build. It will likely help you with your > problem. I have published a PR at > https://github.com/openjdk/jdk/pull/16971 (JDK-8321373). > > /Magnus > On 2023-11-24 13:08, Magnus Ihse Bursie wrote: > > Are you running on Ubuntu properly, or Ubuntu in WLS? If it is the former, > the it is not the same problem as the other poster, which were running on > Windows. > > The JDK build uses the "C" locale. This should be set automatically by the > build system, so it should just work. But in case there is some bug, try > exporting LC_ALL=C before building and see if it helps. > > Also, the point of LC_ALL is that you can specify it instead of all the > detailed LC_* variables... > > /Magnus > On 2023-11-24 08:41, last last wrote: > > I am currently facing the same error when build paths include Chinese > characters ,after setting the environment variable "export > LC_ALL=zh_CN.UTF-8" .The testing environment is also Ubuntu 2004. > The system locale settings are as follows: LANG=zh_CN.UTF-8 > LANGUAGE=zh_CN:zh LC_CTYPE="zh_CN.UTF-8" LC_NUMERIC="zh_CN.UTF-8" > LC_TIME="zh_CN.UTF-8" LC_COLLATE="zh_CN.UTF-8" LC_MONETARY="zh_CN.UTF-8" > LC_MESSAGES="zh_CN.UTF-8" LC_PAPER="zh_CN.UTF-8" LC_NAME="zh_CN.UTF-8" > LC_ADDRESS="zh_CN.UTF-8" LC_TELEPHONE="zh_CN.UTF-8" > LC_MEASUREMENT="zh_CN.UTF-8" LC_IDENTIFICATION="zh_CN.UTF-8" > LC_ALL=zh_CN.UTF-8 > I'm wondering if there are any other system configurations that could help > resolve this problem. Your insights would be greatly appreciated. > > Magnus Ihse Bursie <magnus.ihse.bur...@oracle.com> 于2023年11月23日周四 22:30写道: > >> Congratulations! You get to test drive the recently updated build >> instructions for Windows locale requirements! :-) >> >> Please see >> >> https://github.com/openjdk/jdk/blob/master/doc/building.md#locale-requirements >> >> In particular, I believe you need to set your system locale. >> >> Please report back if that solves the problem or not. >> >> /Magnus >> >> >> On 2023-11-23 03:51, last last wrote: >> > Hi all, >> > >> > I tried to build a OpenJDK11 fastdebug with paths that include Chinese >> > characters,my build path is "/home/kylin/图片/jdk11u-dev",but i saw some >> > error as followings: >> > >> > Exception in thread "main" java.nio.file.InvalidPathException: >> > Malformed input or input contains unmappable characters: >> > >> /home/kylin/??????/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/buildtools/langtools_tools_classes/_the.BUILD_TOOLS_LANGTOOLS_batch.tmp >> > at java.base/sun.nio.fs.UnixPath.encode(UnixPath.java:145) >> > at java.base/sun.nio.fs.UnixPath.<init>(UnixPath.java:69) >> > at java.base/sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:279) >> > at java.base/java.nio.file.Path.of(Path.java:147) >> > at java.base/java.nio.file.Paths.get(Paths.java:69) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.loadCmdFile(CommandLine.java:128) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.appendParsedCommandArgs(CommandLine.java:71) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:102) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:123) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:215) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:170) >> > at jdk.compiler/com.sun.tools.javac.Main.compile(Main.java:57) >> > at jdk.compiler/com.sun.tools.javac.Main.main(Main.java:43) >> > make[3]: *** [ToolsLangtools.gmk:40: >> > >> /home/kylin/图片/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/buildtools/langtools_tools_classes/_the.BUILD_TOOLS_LANGTOOLS_batch] >> >> > Error 1 >> > make[2]: *** [make/Main.gmk:73: buildtools-langtools] Error 2 >> > make[2]: *** Waiting for unfinished jobs.... >> > Exception in thread "main" java.nio.file.InvalidPathException: >> > Malformed input or input contains unmappable characters: >> > >> /home/kylin/??????/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/hotspot/variant-server/tools/jvmti/_the.BUILD_JVMTI_TOOLS_batch.tmp >> > at java.base/sun.nio.fs.UnixPath.encode(UnixPath.java:145) >> > at java.base/sun.nio.fs.UnixPath.<init>(UnixPath.java:69) >> > at java.base/sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:279) >> > at java.base/java.nio.file.Path.of(Path.java:147) >> > at java.base/java.nio.file.Paths.get(Paths.java:69) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.loadCmdFile(CommandLine.java:128) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.appendParsedCommandArgs(CommandLine.java:71) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:102) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:123) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:215) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:170) >> > at jdk.compiler/com.sun.tools.javac.Main.compile(Main.java:57) >> > at jdk.compiler/com.sun.tools.javac.Main.main(Main.java:43) >> > make[3]: *** [gensrc/GensrcJvmti.gmk:45: >> > >> /home/kylin/图片/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/hotspot/variant-server/tools/jvmti/_the.BUILD_JVMTI_TOOLS_batch] >> >> > Error 1 >> > make[3]: *** Waiting for unfinished jobs.... >> > Exception in thread "main" java.nio.file.InvalidPathException: >> > Malformed input or input contains unmappable characters: >> > >> /home/kylin/??????/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/hotspot/variant-server/buildtools/tools_classes/_the.BUILD_JFR_TOOLS_batch.tmp >> > at java.base/sun.nio.fs.UnixPath.encode(UnixPath.java:145) >> > at java.base/sun.nio.fs.UnixPath.<init>(UnixPath.java:69) >> > at java.base/sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:279) >> > at java.base/java.nio.file.Path.of(Path.java:147) >> > at java.base/java.nio.file.Paths.get(Paths.java:69) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.loadCmdFile(CommandLine.java:128) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.appendParsedCommandArgs(CommandLine.java:71) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:102) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:123) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:215) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:170) >> > at jdk.compiler/com.sun.tools.javac.Main.compile(Main.java:57) >> > at jdk.compiler/com.sun.tools.javac.Main.main(Main.java:43) >> > make[3]: *** [gensrc/GensrcJfr.gmk:43: >> > >> /home/kylin/图片/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/hotspot/variant-server/buildtools/tools_classes/_the.BUILD_JFR_TOOLS_batch] >> >> > Error 1 >> > make[2]: *** [make/Main.gmk:265: hotspot-server-gensrc] Error 2 >> > >> > ERROR: Build failed for target 'images' in configuration >> > 'linux-aarch64-normal-server-fastdebug' (exit code 2) >> > >> > === Output from failing command(s) repeated here === >> > * For target >> > buildtools_langtools_tools_classes__the.BUILD_TOOLS_LANGTOOLS_batch: >> > Exception in thread "main" java.nio.file.InvalidPathException: >> > Malformed input or input contains unmappable characters: >> > >> /home/kylin/??????/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/buildtools/langtools_tools_classes/_the.BUILD_TOOLS_LANGTOOLS_batch.tmp >> > at java.base/sun.nio.fs.UnixPath.encode(UnixPath.java:145) >> > at java.base/sun.nio.fs.UnixPath.<init>(UnixPath.java:69) >> > at java.base/sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:279) >> > at java.base/java.nio.file.Path.of(Path.java:147) >> > at java.base/java.nio.file.Paths.get(Paths.java:69) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.loadCmdFile(CommandLine.java:128) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.appendParsedCommandArgs(CommandLine.java:71) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:102) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:123) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:215) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:170) >> > at jdk.compiler/com.sun.tools.javac.Main.compile(Main.java:57) >> > at jdk.compiler/com.sun.tools.javac.Main.main(Main.java:43) >> > * For target >> > >> hotspot_variant-server_buildtools_tools_classes__the.BUILD_JFR_TOOLS_batch: >> > Exception in thread "main" java.nio.file.InvalidPathException: >> > Malformed input or input contains unmappable characters: >> > >> /home/kylin/??????/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/hotspot/variant-server/buildtools/tools_classes/_the.BUILD_JFR_TOOLS_batch.tmp >> > at java.base/sun.nio.fs.UnixPath.encode(UnixPath.java:145) >> > at java.base/sun.nio.fs.UnixPath.<init>(UnixPath.java:69) >> > at java.base/sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:279) >> > at java.base/java.nio.file.Path.of(Path.java:147) >> > at java.base/java.nio.file.Paths.get(Paths.java:69) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.loadCmdFile(CommandLine.java:128) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.appendParsedCommandArgs(CommandLine.java:71) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:102) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:123) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:215) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:170) >> > at jdk.compiler/com.sun.tools.javac.Main.compile(Main.java:57) >> > at jdk.compiler/com.sun.tools.javac.Main.main(Main.java:43) >> > * For target >> > hotspot_variant-server_tools_jvmti__the.BUILD_JVMTI_TOOLS_batch: >> > Exception in thread "main" java.nio.file.InvalidPathException: >> > Malformed input or input contains unmappable characters: >> > >> /home/kylin/??????/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/hotspot/variant-server/tools/jvmti/_the.BUILD_JVMTI_TOOLS_batch.tmp >> > at java.base/sun.nio.fs.UnixPath.encode(UnixPath.java:145) >> > at java.base/sun.nio.fs.UnixPath.<init>(UnixPath.java:69) >> > at java.base/sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:279) >> > at java.base/java.nio.file.Path.of(Path.java:147) >> > at java.base/java.nio.file.Paths.get(Paths.java:69) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.loadCmdFile(CommandLine.java:128) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.appendParsedCommandArgs(CommandLine.java:71) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:102) >> > at >> > >> jdk.compiler/com.sun.tools.javac.main.CommandLine.parse(CommandLine.java:123) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:215) >> > at jdk.compiler/com.sun.tools.javac.main.Main.compile(Main.java:170) >> > at jdk.compiler/com.sun.tools.javac.Main.compile(Main.java:57) >> > at jdk.compiler/com.sun.tools.javac.Main.main(Main.java:43) >> > >> > * All command lines available in >> > >> /home/kylin/图片/jdk11u-dev/build/linux-aarch64-normal-server-fastdebug/make-support/failure-logs. >> > >> > ---------- >> > This error only arises when the compilation path contains Chinese >> > characters. There is no such problem with the compilation path in >> > English. The testing environment is Ubuntu 20.04. >> > I also tested having the compilation path include German and French >> > characters, and encountered the same compilation issues. >> > >> > Is this considered an issue? If it is, can it be added to the Java Bug >> > System? >> >