aboutsummaryrefslogtreecommitdiff
path: root/lang/python/files
Commit message (Collapse)AuthorAge
* python packages: move all things python under lang/pythonAlexandru Ardelean2017-05-17
| | | | | | | | | | | | I admit this may be be a bit aggressive, but the lang folder is getting cluttered/filled up with Python, PHP, Perl, Ruby, etc. packages. Makes sense to try to group them into per-lang folders. I took the Pythons. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: split source packages away from compiled packagesAlexandru Ardelean2017-03-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Well, they're not yet compiled, but in the next commit they should be. People have been complaining [citation needed] to me via email or via Github that Python's performance is crap because it packages sources directly and they're not compiled. And Python has to compile the sources on each run, and on-the-fly. Allowing compilation caching is also a no-no, because I'll get complaints that the flash storage fills up whenever a Python app runs. So, to give the user a choice, the new de-facto packaging for Python packages will be: * ship compiled + [ preferably ] optimized files * package sources separately The problem is that this doubles the number of packages in LEDE/OpenWrt, but build-times should not suffer a big hit, since the compilation is done once, and the install phase should not be too intensive. Oh, and people don't need ship source packages if they don't want to. To do that, a packager needs to just call `$(eval $(call BuildPackage,python-<package>-src))` The `python-` prefix is important. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python,python3: drop remove .pyc & .pyo filesAlexandru Ardelean2017-03-09
| | | | | | We'll control in the install phase what we ship [byte-codes or source files] Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: fix python-dev clash with python-baseAlexandru Ardelean2017-03-09
| | | | | | | Both want to install libpython.so. python-dev should install libpython.a Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python,python3: move PyPackage install rules in the beggining of the Package ↵Alexandru Ardelean2017-03-09
| | | | | | | | | install rules So that we can process Python sources installed by those rules, if we need to. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: move filespec shell code into fileAlexandru Ardelean2017-03-09
| | | | | | | Cleanup. And preparation for adding a bit more functionality. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python,python3: fix goof with multiline command breakAlexandru Ardelean2017-03-09
| | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python,python3: override python setuptools & pip versionsAlexandru Ardelean2017-02-09
| | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python,python3: add python-pip-conf package to be used by both python-pip & ↵Alexandru Ardelean2017-01-23
| | | | | | python3-pip Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* pip,setuptools: move as part of python,python3 buildAlexandru Ardelean2017-01-23
| | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* Merge pull request #3813 from NeoRaider/hostpkgMatthias Schiffer2017-01-11
|\ | | | | Use STAGING_DIR_HOSTPKG where appropriate
| * treewide: replace $(STAGING_DIR)/host and $(HOST_BUILD_PREFIX) with ↵Matthias Schiffer2017-01-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | $(STAGING_DIR_HOSTPKG) As both LEDE and OpenWrt have STAGING_DIR_HOSTPKG now, we can start to rely on it. See 73b7f55424de52d8179a9ad808252fe3bf8dcc9d for more information on STAGING_DIR_HOSTPKG. STAGING_DIR_HOSTPKG won't actually be changed before the first LEDE release (it is equivalent to $(STAGING_DIR)/host), so this simple search/replace cleanup is safe to apply. Doing this cleanup now will be useful for the Gluon project (an OpenWrt/LEDE based firmware framework) for experimenting with modifying STAGING_DIR_HOSTPKG before doing this in the LEDE upstream. Also fixes a typo in the dbus Makefile ("STAGIND_DIR"). Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
| * python{,3}: remove STAGING_DIR_HOSTPKG fallback definitionMatthias Schiffer2017-01-10
| | | | | | | | | | | | | | STAGING_DIR_HOSTPKG is now defined in both OpenWrt and LEDE, so we can start to rely on it. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* | python: remove Host/Install rule default addAlexandru Ardelean2017-01-11
|/ | | | | | | | I just found out that, that the BUILD_VARIANT var is not set for the host build, so technically this code would never get used. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: upgrade to version 2.7.13Alexandru Ardelean2017-01-04
| | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: simplify/unify default build rules for python packagesAlexandru Ardelean2017-01-04
| | | | | | | | | Most python packages use the same build rules & vars. So, adding them in python-package.mk. Also, preparing for using VARIANTs for python/python3 packages. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python-dev: add python-lib2to3 as dependencyAlexandru Ardelean2017-01-04
| | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python, python3: unify HOST_ vars and get rid of HOST_CFLAGSAlexandru Ardelean2016-11-07
| | | | | | | --sysconfigdir and --sbindir are obtained from --prefix and --exec-prefix, so no need to have them explicitly Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: move PYTHON_VERSION in own .mk fileAlexandru Ardelean2016-11-07
| | | | | | | Allows for more granularity with respect to python-host.mk and python-package.mk inclusions. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: add include guard for python-host.mk and include in MakefileAlexandru Ardelean2016-11-07
| | | | | | | | | | | | | | | So that it can be included twice. python-package.mk include python-host.mk, but at some point in time python-host.mk is not exported to staging_dir yet. So, to have in python's Makefile, we need to include it in the Makefile, and to prevent double inclusion (if python-host.mk is exported from a previous build), the include guard is added. Also, moved the includes after some vars were set. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: avoid use of HOST_BUILD_PREFIXJo-Philipp Wich2016-11-01
| | | | | | | | | | | | | | | | | | | | | | | | | Currently, the python-host.mk framework relies on HOST_BUILD_PREFIX to refer to the $(STAGING_DIR)/host directory but using the HOST_BUILD_PREFIX variable requires the use of include/host-build.mk which in turn includes python-host.mk, leading to target redefinition errors. In order to provide a global, uniform way to refer to the host staging directory, LEDE introduced a new variable STAGING_DIR_HOSTPKG which points to $(STAGING_DIR)/host for now with the purpose of eventually being able to relocate that directory in the future. This commit changes python-host.mk to ... - stop including include/host-build.mk (revert of #3423) - replace usages of $(HOST_BUILD_PREFIX) with $(STAGING_DIR_HOSTPKG) - warn and fallback to $(STAGING_DIR)/host if STAGING_DIR_HOSTPKG is unavailable The fallback code will ensure that the python host build infrastructure continues to work properly on older OpenWrt and LEDE versions until the STAGING_DIR_HOSTPKG is fully settled in and can be removed some time in the future. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* python,python3: include host-build.mk in python-host.mk & python3-package.mkAlexandru Ardelean2016-10-31
| | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* Merge pull request #3297 from NeoRaider/pythonHannu Nyman2016-10-27
|\ | | | | python, python3, python-*: use default prefix for host install
| * python, python-*: use default prefix for host installMatthias Schiffer2016-10-04
| | | | | | | | | | | | Also fixes a few incorrect "$(STAGING_DIR_HOST)/host" paths. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* | python: introduce Build/Compile/HostPyRun{Host,Target}Yousong Zhou2016-10-17
|/ | | | Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
* python: upgrade to version 2.7.12Alexandru Ardelean2016-09-13
| | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: do not allow packaging of windows exe filesAlexandru Ardelean2016-06-27
| | | | | | Thanks to @ryzhovau for reporting. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: revert $(STAGING_DIR)/host to $(STAGING_DIR)/host changeAlexandru Ardelean2016-04-15
| | | | | | | | | Also, override all prefix args in the HOST_CONFIGURE_ARGS so that this works fine on CC/15.05. There are some changes in core regarding package builds that require this. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: change $(STAGING_DIR)/host to $(STAGING_DIR_HOST)Alexandru Ardelean2016-04-14
| | | | | | | | | | It seems that this can become an issue. Found when building python3-setuptools from packages/trunk in openwrt/15.05. python3-setuptools is not in packages/for-15.05 Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: add rpath for host Python extension modulesJeffery To2016-03-13
| | | | Signed-off-by: Jeffery To <jeffery.to@gmail.com>
* python: use default host build prefix, remove cross-compile workarounds for hostJeffery To2016-03-05
| | | | | | | | | | | | | | | The sets host Python's prefix and exec-prefix to the same value ($(STAGING_DIR)/host for packages, as currently defined in include/host-build.mk), which avoids the case where pyconfig.h is not in the same location as Python's other header files (see https://bugs.python.org/issue896330). This also removes some cross compilation workarounds (_python_sysroot/prefix/exec_prefix, disabling byte-compilation, __PYVENV_LAUNCHER__) that are not necessary when compiling packages for host. Signed-off-by: Jeffery To <jeffery.to@gmail.com>
* python: fix HOST_PYTHON_INC_DIR pathJeffery To2016-02-14
| | | | | | | Host python moved in c5564133, this updates HOST_PYTHON_INC_DIR to match. Signed-off-by: Jeffery To <jeffery.to@gmail.com>
* treewide: use $(STAGING_DIR)/host instead of $(STAGING_DIR_HOST), sync with ↵Felix Fietkau2016-01-20
| | | | | | changes in trunk Signed-off-by: Felix Fietkau <nbd@openwrt.org>
* python: fixed _python_sysroot pathsJeffery To2015-12-31
| | | | | | | | AFAIK sysroot is combined with prefix/exec_prefix, so sysroot shouldn't include "/usr". (cf. the HostPython function in older versions of python-package.mk) Signed-off-by: Jeffery To <jeffery.to@gmail.com>
* lang/python: Make building additional (non-base) python modules easierDaniel Dickinson2015-12-18
| | | | | | | This adds code to make it easier to build third-party python modules such as ones from PyPi. Signed-off-by: Daniel Dickinson <openwrt@daniel.thecshore.com>
* Merge pull request #2092 from cshore/pull-request-python-system-expatHannu Nyman2015-12-16
|\ | | | | lang/python: Depend on system expat
| * lang/python: Depend on system expatDaniel Dickinson2015-12-09
| | | | | | | | Signed-off-by: Daniel Dickinson <openwrt@daniel.thecshore.com>
* | python2: fix typo in HostPython functionAlexandru Ardelean2015-12-13
| | | | | | | | | | | | I call this the curse of the End-Of-The-Year for me. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* | python: fix HostPython againAlexandru Ardelean2015-12-12
| | | | | | | | | | | | Tested on python-setuptools. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* | python: fix HostPython host/target selectionAlexandru Ardelean2015-12-11
| | | | | | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* | python: upgrade to version 2.7.11Alexandru Ardelean2015-12-11
| | | | | | | | | | | | | | And split python-dev and python-lib2to3 packages. Seems for python3 this was done, so we'll sync here. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* | python: unify HostPython and HostHostPython functionsAlexandru Ardelean2015-12-11
|/ | | | | | | | That means basically moving the host Python from $(STAGING_DIR_HOST) to $(STAGING_DIR_HOST)/usr and making the PYTHONPATH var as an argument. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: add capability to install python packages for the hostJeffery To2015-11-24
| | | | | | | | | | | | Some python packages (e.g. cffi) compile one or more shared libraries as part of their setup process. When these packages are setup dependencies of other packages (e.g. cryptography), these packages (and their shared libraries) will need to be loaded on the host system. This adds a makefile, similar to python-package.mk, to simplify installing python packages on the host. Signed-off-by: Jeffery To <jeffery.to@gmail.com>
* python: fix cross-compiling C++ modules.Attila Lendvai2015-09-28
| | | | Signed-off-by: Attila Lendvai <attila@lendvai.name>
* python: upgrade to 2.7.10Alexandru Ardelean2015-05-27
| | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: replace with libncursesw with libncursesAlexandru Ardelean2015-04-21
| | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: added configure args for distutils path detectionJan Čermák2015-03-16
| | | | | | | | | | | | python-package.mk now defines (extends) CONFIGURE_ARGS that are adjusting PREFIX and EXEC_PREFIX in distutils.sysconfig during compilation. These variables are sometimes used by autotools to detect path to Python header files. Adding these variables to python-package.mk fixes compilation of legacy autotools-configured packages that already include python-package.mk and do not overwrite CONFIGURE_ARGS. Signed-off-by: Jan Čermák <jan.cermak@nic.cz> Cc: Alexandru Ardelean <ardeleanalex@gmail.com>
* python: refine packaging and split more modules into packagesAlexandru Ardelean2015-03-13
| | | | | | | | | | | | | Rule of thumb is: any Python file that is greater than 100kb (or adds a dependency with which it adds more than 100 kb) should be a pretty useful/commonly used lib to stay in `python-light`. An example, is the Python IO lib, which summarized (Python source + binary module) is over 200kb. Also moved some files that should have been put into previously existing packages before, and re-organized the packages a bit. Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
* Merge pull request #992 from commodo/python-patch-updatesSteven Barth2015-03-06
|\ | | | | python: patch updates
| * python: add '_python_*' env vars to host pythonAlexandru Ardelean2015-03-06
| | | | | | | | Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>