Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH next 1/2] package/pkg-cargo: provide a single definition of CARGO_HOME value
@ 2022-11-03 22:45 Thomas Petazzoni via buildroot
  2022-11-03 22:45 ` [Buildroot] [PATCH next 2/2] package/pkg-cargo: move CARGO_HOME into DL_DIR Thomas Petazzoni via buildroot
  2022-11-06 15:18 ` [Buildroot] [PATCH next 1/2] package/pkg-cargo: provide a single definition of CARGO_HOME value Yann E. MORIN
  0 siblings, 2 replies; 10+ messages in thread
From: Thomas Petazzoni via buildroot @ 2022-11-03 22:45 UTC (permalink / raw)
  To: Buildroot List
  Cc: Moritz Bitsch, James Hilliard, Fabrice Fontaine, Thomas Petazzoni

Instead of replicating $(HOST_DIR)/share/cargo in several place,
define BR_CARGO_HOME. This will help when we'll want to change this
location.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
 package/pkg-cargo.mk         | 6 ++++--
 package/suricata/suricata.mk | 2 +-
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/package/pkg-cargo.mk b/package/pkg-cargo.mk
index f7e3f39503..5923725f5e 100644
--- a/package/pkg-cargo.mk
+++ b/package/pkg-cargo.mk
@@ -20,8 +20,10 @@
 #
 ################################################################################
 
+BR_CARGO_HOME = $(HOST_DIR)/share/cargo
+
 PKG_COMMON_CARGO_ENV = \
-	CARGO_HOME=$(HOST_DIR)/share/cargo
+	CARGO_HOME=$(BR_CARGO_HOME)
 
 # __CARGO_TEST_CHANNEL_OVERRIDE_DO_NOT_USE_THIS is needed to allow
 # passing the -Z target-applies-to-host, which is needed together with
@@ -79,7 +81,7 @@ $(2)_DOWNLOAD_DEPENDENCIES += host-rustc
 $(2)_DEPENDENCIES += host-rustc
 
 $(2)_DOWNLOAD_POST_PROCESS = cargo
-$(2)_DL_ENV += CARGO_HOME=$$(HOST_DIR)/share/cargo
+$(2)_DL_ENV += CARGO_HOME=$$(BR_CARGO_HOME)
 
 # If building in a sub directory, use that to find the Cargo.toml
 ifneq ($$($(2)_SUBDIR),)
diff --git a/package/suricata/suricata.mk b/package/suricata/suricata.mk
index 8c38b7c713..72b72cc94d 100644
--- a/package/suricata/suricata.mk
+++ b/package/suricata/suricata.mk
@@ -29,7 +29,7 @@ SURICATA_DEPENDENCIES = \
 
 SURICATA_CONF_ENV = \
 	ac_cv_path_HAVE_SPHINXBUILD=no \
-	CARGO_HOME=$(HOST_DIR)/share/cargo \
+	CARGO_HOME=$(BR_CARGO_HOME) \
 	RUST_TARGET=$(RUSTC_TARGET_NAME)
 
 SURICATA_CONF_OPTS = \
-- 
2.38.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

end of thread, other threads:[~2023-01-14 14:19 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-03 22:45 [Buildroot] [PATCH next 1/2] package/pkg-cargo: provide a single definition of CARGO_HOME value Thomas Petazzoni via buildroot
2022-11-03 22:45 ` [Buildroot] [PATCH next 2/2] package/pkg-cargo: move CARGO_HOME into DL_DIR Thomas Petazzoni via buildroot
2022-11-04  8:54   ` Moritz Bitsch via buildroot
2022-11-06 15:03   ` Yann E. MORIN
2022-11-07  7:52     ` Thomas Petazzoni via buildroot
2022-11-07 17:33       ` Yann E. MORIN
2023-01-14 13:58   ` Yann E. MORIN
2023-01-14 14:17     ` Thomas Petazzoni via buildroot
2023-01-14 14:19     ` Yann E. MORIN
2022-11-06 15:18 ` [Buildroot] [PATCH next 1/2] package/pkg-cargo: provide a single definition of CARGO_HOME value Yann E. MORIN

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