python3: Rename canned recipes in python3-host.mk

This changes the recipe name prefix from Build/Compile/HostPy3 to
HostPython3, and clarifies some of the names (RunHost to Run, Mod to
ModSetup).

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This commit is contained in:
Jeffery To 2020-04-09 23:02:14 +08:00
parent 3642b18441
commit 87b8f45230
5 changed files with 9 additions and 9 deletions

View file

@ -49,7 +49,7 @@ documentation for more information on what is provided.
endef endef
define Host/Compile define Host/Compile
$(call Build/Compile/HostPy3Mod,,install --prefix="" --root="$(STAGING_DIR_HOSTPKG)") $(call HostPython3/ModSetup,,install --prefix="" --root="$(STAGING_DIR_HOSTPKG)")
endef endef
Host/Install:= Host/Install:=

View file

@ -5,7 +5,7 @@
# See /LICENSE for more information. # See /LICENSE for more information.
# #
# Note: include this after `include $(TOPDIR)/rules.mk in your package Makefile # Note: include this file after `include $(TOPDIR)/rules.mk in your package Makefile
# if `python3-package.mk` is included, this will already be included # if `python3-package.mk` is included, this will already be included
# For PYTHON3_VERSION # For PYTHON3_VERSION
@ -40,7 +40,7 @@ HOST_PYTHON3_VARS = \
# $(1) => directory of python script # $(1) => directory of python script
# $(2) => python script and its arguments # $(2) => python script and its arguments
# $(3) => additional variables # $(3) => additional variables
define Build/Compile/HostPy3RunHost define HostPython3/Run
cd "$(if $(strip $(1)),$(strip $(1)),.)" && \ cd "$(if $(strip $(1)),$(strip $(1)),.)" && \
$(HOST_PYTHON3_VARS) \ $(HOST_PYTHON3_VARS) \
$(3) \ $(3) \
@ -51,7 +51,7 @@ endef
HOST_PYTHON3_PIP:=$(STAGING_DIR_HOSTPKG)/bin/pip$(PYTHON3_VERSION) HOST_PYTHON3_PIP:=$(STAGING_DIR_HOSTPKG)/bin/pip$(PYTHON3_VERSION)
# $(1) => packages to install # $(1) => packages to install
define Build/Compile/HostPy3PipInstall define HostPython3/PipInstall
$(HOST_PYTHON3_VARS) \ $(HOST_PYTHON3_VARS) \
$(HOST_PYTHON3_PIP) \ $(HOST_PYTHON3_PIP) \
--disable-pip-version-check \ --disable-pip-version-check \
@ -63,8 +63,8 @@ endef
# $(1) => build subdir # $(1) => build subdir
# $(2) => additional arguments to setup.py # $(2) => additional arguments to setup.py
# $(3) => additional variables # $(3) => additional variables
define Build/Compile/HostPy3Mod define HostPython3/ModSetup
$(call Build/Compile/HostPy3RunHost, \ $(call HostPython3/Run, \
$(HOST_BUILD_DIR)/$(strip $(1)), \ $(HOST_BUILD_DIR)/$(strip $(1)), \
setup.py $(2), \ setup.py $(2), \
$(3)) $(3))

View file

@ -142,7 +142,7 @@ PYTHON3_PKG_SETUP_VARS ?=
define Py3Build/Compile/Default define Py3Build/Compile/Default
$(if $(HOST_PYTHON3_PACKAGE_BUILD_DEPENDS), $(if $(HOST_PYTHON3_PACKAGE_BUILD_DEPENDS),
$(call Build/Compile/HostPy3PipInstall,$(HOST_PYTHON3_PACKAGE_BUILD_DEPENDS)) $(call HostPython3/PipInstall,$(HOST_PYTHON3_PACKAGE_BUILD_DEPENDS))
) )
$(call Build/Compile/Py3Mod, \ $(call Build/Compile/Py3Mod, \
$(PYTHON3_PKG_SETUP_DIR), \ $(PYTHON3_PKG_SETUP_DIR), \

View file

@ -101,7 +101,7 @@ HOST_PYTHON3_PIP_INSTALL_CLEANUP:=$(call HOST_PYTHON3_PIP_INSTALL,$(PKG_INSTALL_
define Build/Compile define Build/Compile
$(foreach pkg,$(CONFIG_PACKAGE_python3-packages-list-host), $(foreach pkg,$(CONFIG_PACKAGE_python3-packages-list-host),
$(call Build/Compile/HostPy3RunHost,,$(HOST_PYTHON3_PIP_INSTALL_HOST) $(pkg)) $(call HostPython3/Run,,$(HOST_PYTHON3_PIP_INSTALL_HOST) $(pkg))
) )
$(foreach pkg,$(CONFIG_PACKAGE_python3-packages-list), $(foreach pkg,$(CONFIG_PACKAGE_python3-packages-list),
$(call Build/Compile/HostPy3RunTarget,,$(call HOST_PYTHON3_PIP_INSTALL_TARGET,$(pkg)) $(pkg),$(CONFIG_PACKAGE_python3-packages-envs)) $(call Build/Compile/HostPy3RunTarget,,$(call HOST_PYTHON3_PIP_INSTALL_TARGET,$(pkg)) $(pkg),$(CONFIG_PACKAGE_python3-packages-envs))

View file

@ -76,7 +76,7 @@ MAKE_VARS += \
DJANGO_ADMIN_PY="$(STAGING_DIR_HOSTPKG)/bin/django-admin" DJANGO_ADMIN_PY="$(STAGING_DIR_HOSTPKG)/bin/django-admin"
define Py3Build/Compile define Py3Build/Compile
$(call Build/Compile/HostPy3PipInstall,$(HOST_PYTHON3_PACKAGE_BUILD_DEPENDS)) $(call HostPython3/PipInstall,$(HOST_PYTHON3_PACKAGE_BUILD_DEPENDS))
$(call Build/Compile/Default,locale) $(call Build/Compile/Default,locale)
$(INSTALL_DIR) $(PKG_INSTALL_DIR)/$(PYTHON3_PKG_DIR) $(INSTALL_DIR) $(PKG_INSTALL_DIR)/$(PYTHON3_PKG_DIR)
endef endef