That you are using Meson is an important bit of information.
I can reproduce the error when using Meson on Windows/MSYS2. And this is
because our Meson setup does *not* `WIN32`.
The following patch defines it and the build succeeds:
```diff
diff --git a/meson.build b/meson.build
index 6944a423b..bf725bd9b 100644
--- a/meson.build
+++ b/meson.build
@@ -202,6 +202,10 @@ if (gnu_source)
basic_cflags += '-D_GNU_SOURCE'
endif
+if host_machine.system() == 'windows'
+ basic_cflags += '-DWIN32=1'
+endif
+
# CFLAGS common between Geany and bundled plugins
def_cflags = basic_cflags + [
'-DGTK',
```
This raises two questions, mainly targeted to @kugel-:
- why did this not fail in the past when we tested Meson support on Windows?
- is there a better way or place in `meson.build` to add the define?
--
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/issues/3437#issuecomment-1510386418
You are receiving this because you are subscribed to this thread.
Message ID: <geany/geany/issues/3437/[email protected]>