public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
* [PATCH v6 1/6] meson: Allow user to override setup command options
@ 2025-04-11 17:27 Tom Hochstein
  2025-04-11 17:27 ` [PATCH v6 2/6] toolchain-scripts: Add Meson settings for Yocto build SDK Tom Hochstein
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: Tom Hochstein @ 2025-04-11 17:27 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tom Hochstein

The user cannot override the setup command options --cross-file and
--native-file because the meson-wrapper places these options on the
command line after the user options. This problem was noticed when
trying to build with an SDK using a custom cross-file.

Signed-off-by: Tom Hochstein <tom.hochstein@oss.nxp.com>
---
 meta/recipes-devtools/meson/meson/meson-wrapper | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/meta/recipes-devtools/meson/meson/meson-wrapper b/meta/recipes-devtools/meson/meson/meson-wrapper
index 7455985297..3aa1a93520 100755
--- a/meta/recipes-devtools/meson/meson/meson-wrapper
+++ b/meta/recipes-devtools/meson/meson/meson-wrapper
@@ -14,8 +14,14 @@ fi
 unset CC CXX CPP LD AR NM STRIP
 
 case "$1" in
-setup|configure|dist|install|introspect|init|test|wrap|subprojects|rewrite|compile|devenv|env2mfile|help) MESON_CMD="$1" ;;
-*) echo meson-wrapper: Implicit setup command assumed; MESON_CMD=setup ;;
+setup|configure|dist|install|introspect|init|test|wrap|subprojects|rewrite|compile|devenv|env2mfile|help)
+    MESON_CMD="$1"
+    shift
+    ;;
+*)
+    MESON_CMD=setup
+    echo meson-wrapper: Implicit setup command assumed
+    ;;
 esac
 
 if [ "$MESON_CMD" = "setup" ]; then
@@ -27,5 +33,6 @@ if [ "$MESON_CMD" = "setup" ]; then
 fi
 
 exec "$OECORE_NATIVE_SYSROOT/usr/bin/meson.real" \
-    "$@" \
-    $MESON_SETUP_OPTS
+    $MESON_CMD \
+    $MESON_SETUP_OPTS \
+    "$@"
-- 
2.34.1



^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2025-04-17 13:48 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-11 17:27 [PATCH v6 1/6] meson: Allow user to override setup command options Tom Hochstein
2025-04-11 17:27 ` [PATCH v6 2/6] toolchain-scripts: Add Meson settings for Yocto build SDK Tom Hochstein
2025-04-11 17:28 ` [PATCH v6 3/6] toolchain-scripts: Export meson settings for SDK builds Tom Hochstein
2025-04-11 17:28 ` [PATCH v6 4/6] meson: Fix host_machine setting for native cross-file Tom Hochstein
2025-04-11 17:28 ` [PATCH v6 5/6] oeqa/sdk/meson: improve test to validate host/build target assignments Tom Hochstein
2025-04-15  9:12   ` [OE-core] " Mathieu Dubois-Briand
2025-04-11 17:28 ` [PATCH v6 6/6] oeqa/sdk/meson: Skip test when SDK arch != build machine arch Tom Hochstein
2025-04-15 10:48   ` [OE-core] " Richard Purdie
2025-04-16 16:16     ` Tom Hochstein
     [not found]     ` <1836D8BA73D61DA5.22324@lists.openembedded.org>
2025-04-17 13:48       ` Tom Hochstein

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox