diff options
| author | Hannu Nyman <hannu.nyman@iki.fi> | 2015-12-07 13:46:08 +0200 |
|---|---|---|
| committer | Hannu Nyman <hannu.nyman@iki.fi> | 2015-12-07 13:46:08 +0200 |
| commit | 0fee8f5cb7ecdd6dc04cd6e3ac99e975fe156111 (patch) | |
| tree | 62339e27afe82fd9e3df27a23cada3e1671e8298 /lang/python3 | |
| parent | 98215f762ec724fe7ea652e653374340dbf19bb6 (diff) | |
| parent | da4d2e49dbbed514ed9a725f0fcf567dad9b8d74 (diff) | |
Merge pull request #1982 from FlorianFieber/python3
Python3: Add python3-pip, python3-setuptools and their dependencies
Diffstat (limited to 'lang/python3')
| -rw-r--r-- | lang/python3/Makefile | 10 | ||||
| -rw-r--r-- | lang/python3/files/python3-package-dev.mk | 25 | ||||
| -rw-r--r-- | lang/python3/files/python3-package-lib2to3.mk | 16 | ||||
| -rw-r--r-- | lang/python3/files/python3-package.mk | 12 |
4 files changed, 56 insertions, 7 deletions
diff --git a/lang/python3/Makefile b/lang/python3/Makefile index fa3d6e62e..250410756 100644 --- a/lang/python3/Makefile +++ b/lang/python3/Makefile @@ -14,11 +14,11 @@ PYTHON_VERSION:=$(PYTHON3_VERSION) PYTHON_VERSION_MICRO:=$(PYTHON3_VERSION_MICRO) PKG_NAME:=python3 -PKG_RELEASE:=1 +PKG_RELEASE:=3 PKG_VERSION:=$(PYTHON_VERSION).$(PYTHON_VERSION_MICRO) PKG_SOURCE:=Python-$(PKG_VERSION).tar.xz -PKG_SOURCE_URL:=http://www.python.org/ftp/python/$(PKG_VERSION) +PKG_SOURCE_URL:=https://www.python.org/ftp/python/$(PKG_VERSION) PKG_MD5SUM:=d149d2812f10cbe04c042232e7964171 PKG_LICENSE:=PSF @@ -41,7 +41,7 @@ define Package/python3/Default SECTION:=lang CATEGORY:=Languages TITLE:=Python $(PYTHON_VERSION) programming language - URL:=http://www.python.org/ + URL:=https://www.python.org/ MAINTAINER:=Alexandru Ardelean <ardeleanalex@gmail.com> endef @@ -92,7 +92,7 @@ include ./files/python3-package-*.mk define Package/python3 $(call Package/python3/Default) - DEPENDS:=+python3-light $(foreach package,$(PYTHON3_PACKAGES),+$(package)) + DEPENDS:=+python3-light $(foreach package,$(filter-out python3-dev python3-lib2to3,$(PYTHON3_PACKAGES)),+$(package)) endef define Package/python3/description @@ -179,12 +179,10 @@ endef define Py3Package/python3-light/filespec +|/usr/lib/python$(PYTHON_VERSION) --|/usr/lib/python$(PYTHON_VERSION)/config-$(PYTHON_VERSION) -|/usr/lib/python$(PYTHON_VERSION)/distutils/cygwinccompiler.py -|/usr/lib/python$(PYTHON_VERSION)/distutils/command/wininst* -|/usr/lib/python$(PYTHON_VERSION)/ensurepip -|/usr/lib/python$(PYTHON_VERSION)/idlelib --|/usr/lib/python$(PYTHON_VERSION)/lib2to3 -|/usr/lib/python$(PYTHON_VERSION)/tkinter -|/usr/lib/python$(PYTHON_VERSION)/turtledemo -|/usr/lib/python$(PYTHON_VERSION)/lib-dynload/_test*.so diff --git a/lang/python3/files/python3-package-dev.mk b/lang/python3/files/python3-package-dev.mk new file mode 100644 index 000000000..37ee05fda --- /dev/null +++ b/lang/python3/files/python3-package-dev.mk @@ -0,0 +1,25 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-dev +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) development files + DEPENDS:=+python3 +endef + +define Py3Package/python3-dev/install + $(INSTALL_DIR) $(1)/usr/bin + $(CP) $(PKG_INSTALL_DIR)/usr/bin/python$(PYTHON3_VERSION)-config $(1)/usr/bin + $(LN) python$(PYTHON3_VERSION)-config $(1)/usr/bin/python3-config + $(LN) python$(PYTHON_VERSION)/config-$(PYTHON_VERSION)/libpython$(PYTHON3_VERSION).a $(1)/usr/lib/libpython$(PYTHON3_VERSION).a +endef + +$(eval $(call Py3BasePackage,python3-dev, \ + /usr/lib/python$(PYTHON_VERSION)/config-$(PYTHON_VERSION) \ + /usr/include/python$(PYTHON_VERSION) \ + /usr/lib/pkgconfig \ +)) diff --git a/lang/python3/files/python3-package-lib2to3.mk b/lang/python3/files/python3-package-lib2to3.mk new file mode 100644 index 000000000..4426a42a3 --- /dev/null +++ b/lang/python3/files/python3-package-lib2to3.mk @@ -0,0 +1,16 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +define Package/python3-lib2to3 +$(call Package/python3/Default) + TITLE:=Python $(PYTHON3_VERSION) lib2to3 module + DEPENDS:=+python3 +endef + +$(eval $(call Py3BasePackage,python3-lib2to3, \ + /usr/lib/python$(PYTHON3_VERSION)/lib2to3 \ +)) diff --git a/lang/python3/files/python3-package.mk b/lang/python3/files/python3-package.mk index 37a023eb0..4fd3191eb 100644 --- a/lang/python3/files/python3-package.mk +++ b/lang/python3/files/python3-package.mk @@ -1,5 +1,5 @@ # -# Copyright (C) 2007-2014 OpenWrt.org +# Copyright (C) 2007-2015 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -28,11 +28,21 @@ define HostPython3 ( export PYTHONPATH="$(PYTHON3PATH)"; \ export PYTHONOPTIMIZE=""; \ export PYTHONDONTWRITEBYTECODE=1; \ + export _python_sysroot="$(STAGING_DIR)"; \ + export _python_prefix="/usr"; \ + export _python_exec_prefix="/usr"; \ $(1) \ $(HOST_PYTHON3_BIN) $(2); \ ) endef +# These configure args are needed in detection of path to Python header files +# using autotools. +CONFIGURE_ARGS += \ + _python_sysroot="$(STAGING_DIR)" \ + _python_prefix="/usr" \ + _python_exec_prefix="/usr" + PKG_USE_MIPS16:=0 # This is required in addition to PKG_USE_MIPS16:=0 because otherwise MIPS16 # flags are inherited from the Python base package (via sysconfig module) |
