Previously, binaries installed by Python packages will have a
non-suffixed Python 2 version and a suffixed Python 3 version, e.g. pip
and pip3. With the removal of Python 2, the non-suffixed names are no
longer taken.
This adds symlinks for the non-suffixed names linking to the suffixed
scripts (or in the case of pip, easy_install, and python-config, to the
fully-versioned scripts).
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
When a Python package is installed from source (i.e. using setup.py)
into a custom location (with --home), setuptools may want to create a
site.py file in the custom location. This file is created based on the
source code of site-patch.py, a file bundled with setuptools.
Because the normal OpenWrt setuptools package does not contain Python
source code, this file is missing and the installation will end with an
error.
This copies site-patch.py to site-patch.py.txt so that it will be
included in python3-setuptools, and patches setuptools to look for this
file.
See https://github.com/openwrt/packages/issues/12223
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This is not the newest version but the last version compatible with
Django 1.11.
This also updates the jsonfield dependency to jsonfield2.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This package mainly serves to support django-post-office 3.3.0, as that
version switched its dependency from jsonfield to jsonfield2 (a fork of
jsonfield).
The version packaged in this package (3.0.3) is the last version that
supports Django 1.11.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
The ssl module assumes OpenSSL can load the default trust anchors (root
CA certificates).
From https://github.com/openwrt/packages/issues/12209
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This adds the --enable-optimizations configure option (for
profile-guided optimization) for both host and target Python, and the
--with-lto configure option (for link-time optimization) for target
Python (for non-MIPS platforms).
Currently, compiling Python with LTO leads to link errors on mips and
mipsel. (Compiling with LTO appears to succeed on mips64 but there is
only one mips64 target available for convenient testing.)
This also cleans up the host and target configure options:
* Sort options/variables
- Alphabetically
- Flags/options before child-process environment variables
- Group options by type (enable/disable/with/without)
- Static options/variables before conditional ones
* Remove the prefix/dir options, as they are the same as the defaults
set by the build system
* Remove --with-threads, as it is no longer a valid option (threads are
always enabled)
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This adds a script that searches a Python package's source code to find
imports for separately-packaged standard library modules.
The script can be run by calling make with the configure target and
"PY3=stdlib V=s" arguments, e.g.
make package/python3-lxml/configure PY3=stdlib V=s
This also updates the readme on how to call this script, as well as more
information on Python package dependencies in general.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This changes the package to download from PyPI (using pypi.mk) and
removes the incorrect PKG_CPE_ID.
The CPE id was for Debian's python-dns package which contains PyDNS
("pydns" on PyPI). This package contains "dnspython" from PyPI.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
Python will record the values of CC, CXX, AR, and READELF (and other
configure options) used during compilation. pip will use these programs
when asked to compile extension modules on the target device.
* If ccache is used during build, CC and CXX will be ccache_cc and
ccache_cxx, respectively, which are not available on-device (#11912).
* If an external toolchain is used during build, the values of these
variables will contain the external toolchain prefix, which may not be
available on target.
* If the normal toolchain is used during build, AR and READELF will
contain the toolchain prefix, but the names of ar and readelf
on-device do not contain the prefix; they are named "ar" and
"readelf".
This changes the values of these variables in Python's files to match
the names available on-device, and without any toolchain prefix.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This also updates all package metadata (it appears this information was
not updated when the package switched from packaging "gnupg" from PyPI
to "python-gnupg"), updates the package to use the default Python
package build recipe, and adds a src package.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
python-django1-common was added to allow both Python 2 and 3 versions of
Django 1.11 to be installed at the same time. With the removal of Python
2, this package is no longer necessary.
This removes this common package and updates the CONFLICTS value for the
django package.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
The previous maintainer has removed himself from his other packages
(#11612). This package appears to have been omitted by mistake.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This removes:
* Python 3 variants (VARIANT:=python3)
* "for Python3" from package titles
* Package selection condition from package dependencies, e.g.
+PACKAGE_python3-six:python3-light replaced with +python3-light
* "Default" package information sections, e.g.
Package/python-six/Default removed and package details merged into
Package/python3-six
* "(Variant for Python3)" from package descriptions
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
PYTHON_VERSION is a holdover from Python 2; all Python 3 variables are
prefixed with PYTHON3 (or some variation with "3").
This updates all uses of PYTHON_VERSION to PYTHON3_VERSION.
This also sets PYTHON3_PKG_BUILD:=0 before python3-package.mk is
included in the python3 Makefile.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This replaces the use of BUILD_VARIANT with PYTHON3_PKG_BUILD to opt
in/out of the default Python package build recipe (Py3Build/Compile).
PYTHON3_PKG_BUILD defaults to true (1), i.e. if a package includes
python3-package.mk, then by default it will set the package's
Build/Compile to Py3Build/Compile.
If PYTHON3_PKG_BUILD is set to 0 before python3-package.mk is included,
then Build/Compile will not be modified.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
There are no bug reports or other evidence to suggest Python is not
compatible with MIPS16 compilation.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
* Remove PYTHON3_BIN_DIR, it isn't used anywhere in the repo
* Rephrase *-src package description
* Reduce Py3Package/$(1)/install indentation
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This extracts filespec export and processing into
Py3Package/ProcessFilespec.
This also allows the filespec variable to be explicitly set to an empty
value, to bypass filespec processing. (The default filespec is also
available as Py3Package/filespec/Default to be explicitly assigned to
the filespec variable.)
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This moves functionality from python-package-install.sh into
python3-package.mk, so that they can be reused separate from filespec
processing.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
Group Python3/* recipes together, group Py3Package and Py3Build
together.
This also adds headings and whitespace to separate major sections.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This renames "internal" recipes to use the Python3/ prefix and clarifies
the names (RunTarget to Run, Mod to ModSetup, Shebang to FixShebang).
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
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>
HostPython3 only adds a few environment variables before running host
Python. It has only two users, Build/Compile/HostPy3RunHost and
Build/Compile/HostPy3RunTarget.
HostPython3 also accesses $(PYTHON3PATH), even though python3-host.mk
does not include python3-package.mk, where the variable is defined.
This removes HostPython3 and has its two users run host Python directly.
This also combines the environment variables of HostPython3 and the two
users into HOST_PYTHON3_VARS and PYTHON3_VARS.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
Since it only defines variables and canned recipes, it is safe to
include python3-host.mk more than once.
Signed-off-by: Jeffery To <jeffery.to@gmail.com>
This was needed for Seafile up to a certain version. Since it's not
required anymore by any other package/known-user, remove it.
Should be installable via pip or manually.
Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
This adds a 'Package/<pkg>-src/config' definition with a 'depends on
<pkg>' line, which will hide <pkg>-src unless <pkg> is selected. This
makes the long list of python packages a bit shorter, and also indents
the src package:
<M> python3-base................................ Python 3.8 interpreter
< > python3-base-src................. Python 3.8 interpreter (sources)
Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
Time to make it more official.
Running 'python' should get you an interpreter running, and that one is now
Python3.
Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
Was mostly required for Seafile.
Now it isn't.
It's also pretty ancient.
https://www.saddi.com/software/flup/
Page was last updated in 2005.
Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
This change bumps gunicorn to version 20.0.4.
It also installs the binary for gunicorn without any suffix, via symlink.
And remove gunicorn_paster; that was removed from the package and moved
into the gunicorn library.
Also, now we need to use the full python3-setuptools package for the
gunicorn executable, as it won't start without it.
Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>