devel: None of the extensions and plugins load in Clang builds
Environment/Versions
- GIMP version: 2.99.14
- Operating System: Windows 11 22621 x64 under MSYS2
Description of the bug
When compiling Gimp with CLANG64 the compilation completes successfully, but running gimp fails to find all the plugins regardless of the type (Executables, Python, etc)
This does not happen in MINGW64 builds
Reproduction
Is the bug reproducible? Always
Reproduction steps:
- Build mingw-w64-gimp3 in the CLANG64 environment
- Run gimp
Expected result: Most plugins, or at least the executable ones should load
Actual result: Gimp fails to find all plugins:
This is a development version of GIMP. Debug messages may appear here.
set device 'System Aggregated Pointer' to mode: disabled
GIMP-Error: Unable to run plug-in "web-browser.exe"
(C:\msys64\clang64\lib\gimp\2.99\plug-ins\web-browser\web-browser.exe)
Failed to execute child process (No such file or directory)
GIMP-Error: Unable to run plug-in "wavelet-decompose.exe"
(C:\msys64\clang64\lib\gimp\2.99\plug-ins\wavelet-decompose\wavelet-decompose.exe)
Failed to execute child process (No such file or directory)
GIMP-Error: Unable to run plug-in "warp.exe"
(C:\msys64\clang64\lib\gimp\2.99\plug-ins\warp\warp.exe)
Failed to execute child process (No such file or directory)
GIMP-Error: Unable to run plug-in "van-gogh-lic.exe"
(C:\msys64\clang64\lib\gimp\2.99\plug-ins\van-gogh-lic\van-gogh-lic.exe)
...this continues much longer
Additional information
I'm not a GLib developer, so I couldn't get past the g_spawn_async()
call inside gimp_spawn_async()
in gimpplugin.c
But Glib filename resolution is not working. Here is the Process Monitor output when trying to load web-browser.exe:
Time of Day | Process Name | PID | Operation | Path | Result | Detail |
---|---|---|---|---|---|---|
11:42:41.4822460 PM | gimp.exe | 22420 | CreateFile | C:\msys64\clang64\lib\gimp\2.99\plug-ins\web-browser\web-browser.exe | SUCCESS | Desired Access: Execute/Traverse |
11:42:41.4828397 PM | gimp.exe | 22420 | CreateFileMapping | C:\msys64\clang64\lib\gimp\2.99\plug-ins\web-browser\web-browser.exe | SUCCESS | SyncType: SyncTypeOther |
11:42:41.4828614 PM | gimp.exe | 22420 | CreateFileMapping | C:\msys64\clang64\lib\gimp\2.99\plug-ins\web-browser\web-browser.exe | FILE LOCKED WITH ONLY READERS | SyncType: SyncTypeCreateSection |
11:42:41.4828717 PM | gimp.exe | 22420 | CreateFileMapping | C:\msys64\clang64\lib\gimp\2.99\plug-ins\web-browser\web-browser.exe | SUCCESS | SyncType: SyncTypeOther |
11:42:41.4828806 PM | gimp.exe | 22420 | CloseFile | C:\msys64\clang64\lib\gimp\2.99\plug-ins\web-browser\web-browser.exe | SUCCESS | |
11:42:41.4830394 PM | gimp.exe | 22420 | CreateFile | D:\Dev\Github\MINGW-packages\mingw-w64-gimp3 | SUCCESS | Desired Access: Execute/Traverse |
11:42:41.4830698 PM | gimp.exe | 22420 | CloseFile | D:\Dev\Github\MINGW-packages\mingw-w64-gimp3 | SUCCESS | |
11:42:41.4832486 PM | gimp.exe | 22420 | QueryOpen | D:\Dev\Github\MINGW-packages\mingw-w64-gimp3\C.com | NAME NOT FOUND | |
11:42:41.4832805 PM | gimp.exe | 22420 | QueryOpen | D:\Dev\Github\MINGW-packages\mingw-w64-gimp3\C.exe | NAME NOT FOUND | |
11:42:41.4833055 PM | gimp.exe | 22420 | QueryOpen | D:\Dev\Github\MINGW-packages\mingw-w64-gimp3\C.bat | NAME NOT FOUND | |
11:42:41.4833288 PM | gimp.exe | 22420 | QueryOpen | D:\Dev\Github\MINGW-packages\mingw-w64-gimp3\C.cmd | NAME NOT FOUND |
As you can see, It's looking for the wrong path "C.com", "C.exe", etc... (As if it's trying only the first letter of the whole path as the path)