* [Buildroot] [PATCH] package/rust: drop host-python2 support
@ 2022-02-10 19:22 Peter Korsgaard
0 siblings, 0 replies; only message in thread
From: Peter Korsgaard @ 2022-02-10 19:22 UTC (permalink / raw)
To: buildroot; +Cc: Eric Le Bihan
host-python2 is gone, so always use host-python3.
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
---
package/rust/rust.mk | 17 +++++------------
1 file changed, 5 insertions(+), 12 deletions(-)
diff --git a/package/rust/rust.mk b/package/rust/rust.mk
index 5fad7d404c..46487fe4b7 100644
--- a/package/rust/rust.mk
+++ b/package/rust/rust.mk
@@ -14,18 +14,11 @@ HOST_RUST_PROVIDES = host-rustc
HOST_RUST_DEPENDENCIES = \
toolchain \
+ host-python3 \
host-rust-bin \
host-openssl \
$(BR2_CMAKE_HOST_DEPENDENCY)
-ifeq ($(BR2_PACKAGE_PYTHON3),y)
-HOST_RUST_PYTHON_VERSION = $(PYTHON3_VERSION_MAJOR)
-HOST_RUST_DEPENDENCIES += host-python3
-else
-HOST_RUST_PYTHON_VERSION = $(PYTHON_VERSION_MAJOR)
-HOST_RUST_DEPENDENCIES += host-python
-endif
-
HOST_RUST_VERBOSITY = $(if $(VERBOSE),2,0)
# Some vendor crates contain Cargo.toml.orig files. The associated
@@ -50,7 +43,7 @@ define HOST_RUST_CONFIGURE_CMDS
echo 'target = ["$(RUSTC_TARGET_NAME)"]'; \
echo 'cargo = "$(HOST_RUST_BIN_DIR)/cargo/bin/cargo"'; \
echo 'rustc = "$(HOST_RUST_BIN_DIR)/rustc/bin/rustc"'; \
- echo 'python = "$(HOST_DIR)/bin/python$(HOST_RUST_PYTHON_VERSION)"'; \
+ echo 'python = "$(HOST_DIR)/bin/python$(PYTHON3_VERSION_MAJOR)"'; \
echo 'submodules = false'; \
echo 'vendor = true'; \
echo 'extended = true'; \
@@ -71,12 +64,12 @@ define HOST_RUST_CONFIGURE_CMDS
endef
define HOST_RUST_BUILD_CMDS
- cd $(@D); $(HOST_MAKE_ENV) $(HOST_DIR)/bin/python$(HOST_RUST_PYTHON_VERSION) x.py build
+ cd $(@D); $(HOST_MAKE_ENV) $(HOST_DIR)/bin/python$(PYTHON3_VERSION_MAJOR) x.py build
endef
define HOST_RUST_INSTALL_CMDS
- cd $(@D); $(HOST_MAKE_ENV) $(HOST_DIR)/bin/python$(HOST_RUST_PYTHON_VERSION) x.py dist
- cd $(@D); $(HOST_MAKE_ENV) $(HOST_DIR)/bin/python$(HOST_RUST_PYTHON_VERSION) x.py install
+ cd $(@D); $(HOST_MAKE_ENV) $(HOST_DIR)/bin/python$(PYTHON3_VERSION_MAJOR) x.py dist
+ cd $(@D); $(HOST_MAKE_ENV) $(HOST_DIR)/bin/python$(PYTHON3_VERSION_MAJOR) x.py install
endef
$(eval $(host-generic-package))
--
2.20.1
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2022-02-10 19:22 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-10 19:22 [Buildroot] [PATCH] package/rust: drop host-python2 support Peter Korsgaard
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.