From: Alexander Kanavin <alex.kanavin@gmail.com>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH 2/8] meson: add a couple of patches to help with mingw builds
Date: Mon, 18 Feb 2019 13:41:02 +0100 [thread overview]
Message-ID: <20190218124108.7846-2-alex.kanavin@gmail.com> (raw)
In-Reply-To: <20190218124108.7846-1-alex.kanavin@gmail.com>
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
meta/recipes-devtools/meson/meson.inc | 2 ++
...s-windows-split-WINDRES-env-variable.patch | 26 +++++++++++++++++++
...etect-windows-also-if-the-system-str.patch | 25 ++++++++++++++++++
3 files changed, 53 insertions(+)
create mode 100644 meta/recipes-devtools/meson/meson/0001-modules-windows-split-WINDRES-env-variable.patch
create mode 100644 meta/recipes-devtools/meson/meson/0002-environment.py-detect-windows-also-if-the-system-str.patch
diff --git a/meta/recipes-devtools/meson/meson.inc b/meta/recipes-devtools/meson/meson.inc
index d37afc3b0dc..c39b1a3d5e2 100644
--- a/meta/recipes-devtools/meson/meson.inc
+++ b/meta/recipes-devtools/meson/meson.inc
@@ -12,6 +12,8 @@ SRC_URI = "https://github.com/mesonbuild/meson/releases/download/${PV}/meson-${P
file://0001-python-module-do-not-manipulate-the-environment-when.patch \
file://disable-rpath-handling.patch \
file://cross-libdir.patch \
+ file://0001-modules-windows-split-WINDRES-env-variable.patch \
+ file://0002-environment.py-detect-windows-also-if-the-system-str.patch \
"
SRC_URI[sha256sum] = "fb0395c4ac208eab381cd1a20571584bdbba176eb562a7efa9cb17cace0e1551"
SRC_URI[md5sum] = "3c35b91e8040901034809576d54007c6"
diff --git a/meta/recipes-devtools/meson/meson/0001-modules-windows-split-WINDRES-env-variable.patch b/meta/recipes-devtools/meson/meson/0001-modules-windows-split-WINDRES-env-variable.patch
new file mode 100644
index 00000000000..c334e6dd66b
--- /dev/null
+++ b/meta/recipes-devtools/meson/meson/0001-modules-windows-split-WINDRES-env-variable.patch
@@ -0,0 +1,26 @@
+From 5293d0f5067b2aeefe9ce3c175c972de367589bc Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 13 Feb 2019 17:43:54 +0100
+Subject: [PATCH] modules/windows: split WINDRES env variable
+
+As it may contain not just the binary, but also the arguments to it.
+
+Upstream-Status: Pending
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ mesonbuild/modules/windows.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/mesonbuild/modules/windows.py b/mesonbuild/modules/windows.py
+index d185d89..dbaeb9b 100644
+--- a/mesonbuild/modules/windows.py
++++ b/mesonbuild/modules/windows.py
+@@ -56,7 +56,7 @@ class WindowsModule(ExtensionModule):
+ if 'WINDRES' in os.environ:
+ # Pick-up env var WINDRES if set. This is often used for
+ # specifying an arch-specific windres.
+- rescomp = ExternalProgram('windres', command=os.environ.get('WINDRES'), silent=True)
++ rescomp = ExternalProgram('windres', command=os.environ.get('WINDRES').split(), silent=True)
+
+ if not rescomp or not rescomp.found():
+ # Take windres from the config file after the environment, which is
diff --git a/meta/recipes-devtools/meson/meson/0002-environment.py-detect-windows-also-if-the-system-str.patch b/meta/recipes-devtools/meson/meson/0002-environment.py-detect-windows-also-if-the-system-str.patch
new file mode 100644
index 00000000000..1be5d663291
--- /dev/null
+++ b/meta/recipes-devtools/meson/meson/0002-environment.py-detect-windows-also-if-the-system-str.patch
@@ -0,0 +1,25 @@
+From 7bf4c2c02eb7fe1bf24b23e3ba2d7df36495e0aa Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 13 Feb 2019 17:45:09 +0100
+Subject: [PATCH] environment.py: detect windows also if the system string
+ contains 'mingw'
+
+Upstream-Status: Pending
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ mesonbuild/environment.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py
+index b4fc0dc..845077e 100644
+--- a/mesonbuild/environment.py
++++ b/mesonbuild/environment.py
+@@ -1247,7 +1247,7 @@ class MachineInfo:
+ """
+ Machine is windows?
+ """
+- return self.system == 'windows'
++ return self.system == 'windows' or 'mingw' in self.system
+
+ def is_cygwin(self):
+ """
--
2.17.1
next prev parent reply other threads:[~2019-02-18 12:41 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-18 12:41 [PATCH 1/8] clutter-gtk-1.0: convert to meson Alexander Kanavin
2019-02-18 12:41 ` Alexander Kanavin [this message]
2019-02-18 12:41 ` [PATCH 3/8] gdk-pixbuf: convert from autotools " Alexander Kanavin
2019-02-18 12:41 ` [PATCH 4/8] libsoup-2.4: " Alexander Kanavin
2019-02-18 12:41 ` [PATCH 5/8] libxkbcommon: update to 0.8.3 Alexander Kanavin
2019-02-18 12:41 ` [PATCH 6/8] pango: convert from autotools to meson Alexander Kanavin
2019-02-18 12:41 ` [PATCH 7/8] glib-2.0: " Alexander Kanavin
2019-02-19 6:57 ` Khem Raj
2019-02-19 9:41 ` Alexander Kanavin
2019-02-18 12:41 ` [PATCH 8/8] llvm: switch to the official git repository Alexander Kanavin
-- strict thread matches above, loose matches on Subject: below --
2019-02-19 13:58 [PATCH 1/8] clutter-gtk-1.0: convert to meson Alexander Kanavin
2019-02-19 13:58 ` [PATCH 2/8] meson: add a couple of patches to help with mingw builds Alexander Kanavin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190218124108.7846-2-alex.kanavin@gmail.com \
--to=alex.kanavin@gmail.com \
--cc=openembedded-core@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.