mirror of
https://github.com/openwrt/packages.git
synced 2026-01-10 11:44:48 +00:00
python,python3: install built-in pip and setuptools
Easier than using external package. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
This commit is contained in:
@@ -17,16 +17,10 @@ PKG_MD5SUM:=87083c0b9867963b29f7aba3613e8f4a
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/python-pip-$(PKG_VERSION)
|
||||
PKG_UNPACK=$(HOST_TAR) -C $(PKG_BUILD_DIR) --strip-components=1 -xzf $(DL_DIR)/$(PKG_SOURCE)
|
||||
HOST_BUILD_DIR:=$(BUILD_DIR_HOST)/python-pip-$(PKG_VERSION)
|
||||
HOST_UNPACK=$(HOST_TAR) -C $(HOST_BUILD_DIR) --strip-components=1 -xzf $(DL_DIR)/$(PKG_SOURCE)
|
||||
PKG_USE_MIPS16:=0
|
||||
|
||||
HOST_BUILD_DEPENDS:=python python/host python-setuptools/host
|
||||
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
$(call include_mk, python-package.mk)
|
||||
$(call include_mk, python-host.mk)
|
||||
|
||||
define Package/python-pip
|
||||
SUBMENU:=Python
|
||||
@@ -60,17 +54,5 @@ define PyPackage/python-pip/install
|
||||
$(INSTALL_CONF) ./files/pip.conf $(1)/etc/
|
||||
endef
|
||||
|
||||
define Host/Compile
|
||||
$(call Build/Compile/HostPyMod,,\
|
||||
install --root="$(STAGING_DIR_HOSTPKG)" --prefix="" \
|
||||
--single-version-externally-managed \
|
||||
)
|
||||
endef
|
||||
|
||||
define Host/Install
|
||||
endef
|
||||
|
||||
$(eval $(call HostBuild))
|
||||
|
||||
$(eval $(call PyPackage,python-pip))
|
||||
$(eval $(call BuildPackage,python-pip))
|
||||
|
||||
@@ -15,18 +15,11 @@ PKG_SOURCE:=setuptools-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://pypi.python.org/packages/87/ba/54197971d107bc06f5f3fbdc0d728a7ae0b10cafca46acfddba65a0899d8/
|
||||
PKG_MD5SUM:=b39715612fdc0372dbfd7b3fcf5d4fe5
|
||||
|
||||
HOST_BUILD_DEPENDS:=python python/host
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
PKG_UNPACK=$(HOST_TAR) -C $(PKG_BUILD_DIR) --strip-components=1 -xzf $(DL_DIR)/$(PKG_SOURCE)
|
||||
|
||||
HOST_BUILD_DIR:=$(BUILD_DIR_HOST)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
HOST_UNPACK=$(HOST_TAR) -C $(HOST_BUILD_DIR) --strip-components=1 -xzf $(DL_DIR)/$(PKG_SOURCE)
|
||||
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
$(call include_mk, python-package.mk)
|
||||
$(call include_mk, python-host.mk)
|
||||
|
||||
define Package/python-setuptools
|
||||
SUBMENU:=Python
|
||||
@@ -61,18 +54,6 @@ define PyPackage/python-setuptools/install
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
|
||||
endef
|
||||
|
||||
define Host/Compile
|
||||
$(call Build/Compile/HostPyMod,,\
|
||||
install --root="$(STAGING_DIR_HOSTPKG)" --prefix="" \
|
||||
--single-version-externally-managed \
|
||||
)
|
||||
endef
|
||||
|
||||
define Host/Install
|
||||
endef
|
||||
|
||||
$(eval $(call HostBuild))
|
||||
|
||||
$(eval $(call PyPackage,python-setuptools))
|
||||
$(eval $(call BuildPackage,python-setuptools))
|
||||
|
||||
|
||||
@@ -240,6 +240,7 @@ HOST_CONFIGURE_ARGS+= \
|
||||
--exec-prefix=$(HOST_PYTHON_DIR) \
|
||||
--with-system-expat=$(STAGING_DIR_HOSTPKG) \
|
||||
--with-system-ffi=no \
|
||||
--with-ensurepip=install \
|
||||
CONFIG_SITE=
|
||||
|
||||
define Host/Install
|
||||
|
||||
@@ -238,7 +238,7 @@ HOST_CONFIGURE_ARGS+= \
|
||||
--exec-prefix=$(HOST_PYTHON3_DIR) \
|
||||
--with-system-expat=$(STAGING_DIR_HOSTPKG) \
|
||||
--with-system-ffi=no \
|
||||
--with-ensurepip=no \
|
||||
--with-ensurepip=install \
|
||||
CONFIG_SITE=
|
||||
|
||||
define Host/Compile
|
||||
|
||||
Reference in New Issue
Block a user