-
Notifications
You must be signed in to change notification settings - Fork 590
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MSYS2/MinGW-w64: Missing Header 'alloca.h' #3437
Comments
My local MSYS2 setup on a native Windows system does not have How do you start your build? Just in case you didn't know, there is a howto on https://wiki.geany.org/howtos/win32/msys2 to assist in building Geany with MSYS2. |
@eht16 Thanks for the response. I switched to GNU Autotools & the build succeeded. I didn't realize that building with Meson is still experimental.
I'll have to do some digging to make sure. |
According to the Meson log, it's calling
It also defines |
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 The following patch defines it and the build succeeds: 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-:
|
My apologies for not being clear. When I opened this, I thought meson was the recommended build tool. |
My compiler complains that the
alloca.h
header is missing.According to this answer on SO,
alloca.h
does not exist in Windows & should be replaced withmalloc.h
.I haven't tested it yet. Wanted to get the report posted.
Edit: This is an issue with my system, not Geany. The code defines the following:
It appears my MSYS2/MinGW-w64 compiler is not defining
WIN32
. Which seems strange as I thought it did.Edit: I will close this soon.
Edit: It is defined. I wonder why the compiler isn't complying with it.
The text was updated successfully, but these errors were encountered: