kaixo
(kaixo)
November 24, 2025, 7:49pm
1
Hi! I’m trying to compile gtk in Windows using MSVC. (Yeah, I know…)
I went through `meson setup ..` pretty much effortlessly. But now I’m compiling the project and getting this random error. I don’t have enough experience with the project to know why it happens.
PS C:\Users\PC-AITOR\Documents\inkscape\deps\src\gtk\build> meson compile -j8
Activating VS 17.14.21 (November 2025)
INFO: automatically activated MSVC compiler environment
INFO: autodetecting backend as ninja
INFO: calculating backend command to run: "C:\Program Files\Meson\ninja.EXE" -j 8
[14/13097] Generating GObject enum file subprojects/gstrea...d by meson to capture output, because command is too long)
FAILED: subprojects/gstreamer/subprojects/gstreamer/gst/gstenumtypes.h
"C:\Program Files\Meson\meson.exe" "--internal" "exe" "--capture" "subprojects\gstreamer\subprojects\gstreamer\gst\gstenumtypes.h" "--" "C:\Program Files\Meson\meson.exe" "runpython" "C:/Users/PC-AITOR/Documents/inkscape/deps/out/bin/../bin\glib-mkenums" "@C:\Users\PC-AITOR\Documents\inkscape\deps\src\gtk\build\meson-private\meson_rsp_e51a3edeba6bbd73c86f3456aa4e20db4cafbd62.rsp"
--- stderr ---
usage: glib-mkenums [-h] [--identifier-prefix IDPREFIX]
[--symbol-prefix SYMPREFIX] [--fhead FHEAD]
[--ftail FTAIL] [--fprod FPROD] [--eprod EPROD]
[--vhead VHEAD] [--vprod VPROD] [--vtail VTAIL]
[--comments COMMENT_TMPL] [--template TEMPLATE]
[--output OUTPUT] [--version]
[args ...]
glib-mkenums: error: unrecognized arguments: /* enumerations from \"@basename@\" */ " GST_API GType @enum_name@_get_type (void); #define @ENUMPREFIX@_TYPE_@ENUMSHORT@ (@enum_name@_get_type())" G_END_DECLS"
...
lb90
November 24, 2025, 8:29pm
2
Can you share the file C:\Users\PC-AITOR\Documents\inkscape\deps\src\gtk\build\meson-private\meson_rsp_e51a3edeba6bbd73c86f3456aa4e20db4cafbd62.rsp? What Meson version are you using?
BTW, if you’re compiling Inkscape you don’t need GStreamer. You can pass -Dmedia-gstreamer=disabled when compiling GTK4
kaixo
(kaixo)
November 24, 2025, 8:44pm
3
Not on my main computer right now, but I think disabling gstreamer will indeed fix the issue!
I’ll send my log anyway, in case someone else comes across this issue AND needs gstreamer.
kaixo
(kaixo)
November 25, 2025, 2:20pm
4
Disabled gstreamer-media option. Now getting the following error:
CreateProcess failed: The system cannot find the file specified.
Full log: PS C:\Users\PC-AITOR\Documents\inkscape\deps\src\gtk\build> ninja -j8[1/3480] - Pastebin.com
lb90
November 25, 2025, 3:19pm
5
Strange, looks like ninja cannot find cl.exe in PATH. What’s the output of where.exe cl.exe?
Also, did you invoke meson setup with the --vsenv option? If so, you might have to use meson compile -j 8 instead of ninja -j 8 directly. Meson compile is a wrapper that reactivates the VS environment before launching ninja.
kaixo
(kaixo)
November 26, 2025, 1:53pm
6
Now building from the “Developer Powershell for VS”, using “meson compile”. And it seems the cl.exe error is fixed. (Maybe this should be added to the documentation).
But the error is the same (as previously before disabling gstreamer). The error references a binary “glib-mkmenus”
lb90
November 26, 2025, 2:15pm
7
lb90
November 26, 2025, 2:18pm
8
Ah, indeed GTK still points to GLib 2.84: subprojects/glib.wrap · main · GNOME / gtk · GitLab . Then you can try that:
Delete the entire folder C:\Users\PC-AITOR\Documents\inkscape\deps\src\gtk\subprojects\glib
Change gtk\subprojects\glib.wrap as follows:diff --git a/subprojects/glib.wrap b/subprojects/glib.wrap
index b1de406953..8947ea9ac2 100644
--- a/subprojects/glib.wrap
+++ b/subprojects/glib.wrap
@@ -2,7 +2,7 @@
directory = glib
url = https://gitlab.gnome.org/GNOME/glib.git
push-url = ssh://git@ssh.gitlab.gnome.org:GNOME/glib.git
-revision = 2.84.0
+revision = 2.86.2
depth = 1
kaixo
(kaixo)
November 26, 2025, 2:30pm
9
The folder “gobject” doesn’t exist. Only these exist:
gtk/build/subprojects/glib/subprojects
gtk/build/subprojects/glib/tools
gtk/build/subprojects/glib/glib
ebassi
(Emmanuele Bassi)
November 26, 2025, 2:31pm
10
Your clone is invalid. The subprojects/glib directory should be a GLib repository .
kaixo
(kaixo)
November 26, 2025, 2:36pm
11
No, subprojects/glib IS a glib repository. What I’m talking about here is BUILD/subprojects (output artifacts)
PS: Excuse me, my bad
kaixo
(kaixo)
November 26, 2025, 2:39pm
12
Deleting subprojects/glib caused this error:
meson setup .. (more options)
..\meson.build:1:0: ERROR: wrap-redirect C:\Users\PC-AITOR\Documents\inkscape\deps\src\gtk\subprojects\glib\subprojects\gvdb.wrap filename does not exist
lb90
November 26, 2025, 4:15pm
13
Ah, didn’t know about wrap redirects…
Then the simple fix is to start over with a clean checkout of GTK (but still applying the patch above to glib.wrap)
1 Like
kaixo
(kaixo)
November 26, 2025, 4:47pm
14
This doesn’t seem like ideal behaviour though… I’ll do a PR to meson
kaixo
(kaixo)
November 26, 2025, 9:34pm
15
The error comes from this line of gdk/meson.build:167:
gdk_enums = gnome.mkenums_simple('gdkenumtypes',
sources: ...
...
)
It seems that this command, even though it’s being called, is not being formatted correctly. Maybe it’s because of Powershell which interprets commands differently. Specifically, double quotes.
enumerations from “@basenamebasename@”
lb90
November 27, 2025, 9:58am
16
Can you share the error message output by Ninja? It should mention a meson_rsp_*.rsp file, could you upload that file as well?
For example, with GStreamer the error message was:
FAILED: subprojects/gstreamer/subprojects/gstreamer/gst/gstenumtypes.h
"C:\Program Files\Meson\meson.exe" "--internal" [...] "@C:\Users\[...]\gtk\build\meson-private\meson_rsp_e51a3edeba6bbd73c86f3456aa4e20db4cafbd62.rsp"
kaixo
(kaixo)
November 27, 2025, 2:03pm
17
"C:\Program Files\Meson\meson.exe" "--internal" "exe" "--capture" "gdk\gdkenumtypes.h" "--" "C:\Program Files\Meson\meson.exe" "runpython" "C:/Users/PC-AITOR/Documents/inkscape/deps/out/bin/../bin\glib-mkenums" "@C:\Users\PC-AITOR\Documents\inkscape\deps\src\gtk\build\meson-private\meson_rsp_16780f7778fe47ea05daf98879d793681abd2cf9.rsp"
Full output:
lb90
November 27, 2025, 2:39pm
18
Thanks. Can you also upload the response file C:\Users\PC-AITOR\Documents\inkscape\deps\src\gtk\build\meson-private\meson_rsp_16780f7778fe47ea05daf98879d793681abd2cf9.rsp?
bugaevc
(Sergey Bugaev)
November 27, 2025, 4:06pm
19
I’m getting the same issue FWIW, could help with investigating.
2 Likes
kaixo
(kaixo)
November 27, 2025, 5:51pm
20
The RSP file: --fhead "#pragma once#include <glib-object.h>#include \"version/gdkversion - Pastebin.com
It seems like a strange string is getting through the source file list, due to the double quotes.
P.S: Thanks for your free, voluntary support, lb90