Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH 1/2] cargo.bbclass: show PACKAGECONFIG_CONFARGS in bbnote
@ 2025-03-20 16:55 martin.jansa
  2025-03-20 16:55 ` [PATCH 2/2] cargo.bbclass: allow to avoid appending PACKAGECONFIG_CONFARGS martin.jansa
       [not found] ` <182E912DEB60EF95.20788@lists.openembedded.org>
  0 siblings, 2 replies; 19+ messages in thread
From: martin.jansa @ 2025-03-20 16:55 UTC (permalink / raw)
  To: openembedded-core
  Cc: Jean-Pierre Geslin, Bartosz Golaszewski, Bartosz Golaszewski,
	Martin Jansa

From: Martin Jansa <martin.jansa@gmail.com>

* PACKAGECONFIG_CONFARGS was added in:
  https://git.openembedded.org/openembedded-core/commit/?id=16745b20452de60ae2474433cc1a2fb1ed9f6a64
  but it wasn't added in bbnote above which might lead to confusing errors like I got now:

  NOTE: cargo build -v --frozen --target aarch64-webos-linux-gnu --release --manifest-path=.../git//Cargo.toml
  error: unexpected argument '--cfg' found

  Usage: cargo build --verbose... --frozen --target [<TRIPLE>] --release --manifest-path <PATH>

  and was wondering where --cfg came from.

* it was from recipe where we already use:
  RUSTFLAGS:append = " ${PACKAGECONFIG_CONFARGS}"
  it will be difficult to use PACKAGECONFIG for RUSTFLAGS and prevent
  them to be used here for cargo as well, what about the recipes which
  need them to explicitly append them to CARGO_BUILD_FLAGS ?

Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
---
 meta/classes-recipe/cargo.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/classes-recipe/cargo.bbclass b/meta/classes-recipe/cargo.bbclass
index 461d100dd9..2dd28e95d3 100644
--- a/meta/classes-recipe/cargo.bbclass
+++ b/meta/classes-recipe/cargo.bbclass
@@ -47,7 +47,7 @@ oe_cargo_build () {
 	export RUSTFLAGS="${RUSTFLAGS}"
 	bbnote "Using rust targets from ${RUST_TARGET_PATH}"
 	bbnote "cargo = $(which ${CARGO})"
-	bbnote "${CARGO} build ${CARGO_BUILD_FLAGS} $@"
+	bbnote "${CARGO} build ${CARGO_BUILD_FLAGS} ${PACKAGECONFIG_CONFARGS} $@"
 	"${CARGO}" build ${CARGO_BUILD_FLAGS} ${PACKAGECONFIG_CONFARGS} "$@"
 }
 


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

end of thread, other threads:[~2025-05-16 17:47 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-20 16:55 [PATCH 1/2] cargo.bbclass: show PACKAGECONFIG_CONFARGS in bbnote martin.jansa
2025-03-20 16:55 ` [PATCH 2/2] cargo.bbclass: allow to avoid appending PACKAGECONFIG_CONFARGS martin.jansa
     [not found] ` <182E912DEB60EF95.20788@lists.openembedded.org>
2025-03-20 16:59   ` [OE-core] " Martin Jansa
2025-03-20 17:06     ` Richard Purdie
     [not found]     ` <182E91CCE4A2B275.19116@lists.openembedded.org>
2025-03-20 17:16       ` Richard Purdie
2025-03-20 17:36         ` Martin Jansa
2025-03-20 17:51           ` Jean-Pierre Geslin
2025-03-20 18:11           ` [OE-core] " Jean-Pierre Geslin
2025-03-24 18:55             ` Alexander Kanavin
2025-03-24 19:30               ` Martin Jansa
2025-03-24 22:29                 ` Richard Purdie
2025-03-31 16:18                 ` akuster808
2025-03-31 16:28                   ` Alexander Kanavin
2025-05-16 15:07                     ` Anton Antonov
2025-05-16 15:55                       ` [OE-core] " Alexander Kanavin
2025-05-16 16:39                         ` Anton Antonov
2025-05-16 17:19                           ` [OE-core] " Alexander Kanavin
2025-05-16 17:43                             ` Marko, Peter
2025-05-16 17:47                             ` Anton Antonov

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