Commit 08b4294
committed
fix(graalvm): embed UTF-8 active code page in Windows manifest
Native-image apps (BellSoft Liberica NIK 25) crash with
UnsatisfiedLinkError: Can't load library: awt when installed under a
Windows path containing non-ASCII characters (Hebrew/Arabic/Cyrillic/CJK
usernames or app paths). The root cause is a SubstrateVM bug
(oracle/graal#8095, #10237) where path strings are passed to LoadLibraryA
with UTF-8 bytes that the system ANSI codepage then reinterprets,
producing a mojibake'd path.
Augment the existing Windows side-by-side fusion manifest already embedded
via rc.exe with <activeCodePage>UTF-8</activeCodePage> (Windows 10 1903+),
the workaround explicitly recommended by the GraalVM maintainers. With
GetACP() returning 65001, LoadLibraryA bytes are interpreted as UTF-8 and
the bug is bypassed. Also opt into <longPathAware>true</longPathAware>
for paths beyond MAX_PATH.
Verified by reproducing the crash from C:\Users\Public\אבג-test\... and
confirming the rebuilt binary boots cleanly from the same path.1 parent 60469a3 commit 08b4294
1 file changed
Lines changed: 10 additions & 1 deletion
File tree
- plugin-build/plugin/src/main/kotlin/io/github/kdroidfilter/nucleus/desktop/application/internal
Lines changed: 10 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
293 | 293 | | |
294 | 294 | | |
295 | 295 | | |
296 | | - | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
297 | 304 | | |
298 | 305 | | |
299 | 306 | | |
| |||
304 | 311 | | |
305 | 312 | | |
306 | 313 | | |
| 314 | + | |
| 315 | + | |
307 | 316 | | |
308 | 317 | | |
309 | 318 | | |
| |||
0 commit comments