Commit Graph

46 Commits

Author SHA1 Message Date
Antoine Brodin
e7f4f60ba1 Clean up plist 2020-03-01 14:33:45 +00:00
Tobias C. Berner
78321ca20c Fix makefile ordering.
Reported by:	mat
2019-12-07 22:19:30 +00:00
Li-Wen Hsu
7a2c287047 Backport fix of https://bugs.python.org/issue32849
This is needed for starting sysutils/azure-agent at boot:
https://github.com/Azure/WALinuxAgent/issues/1687

Obtained from:	f9c01a16da
MFH:		2019Q4
Sponsored by:	The FreeBSD Foundation
2019-12-07 21:28:10 +00:00
Tobias C. Berner
6bd55ab779 Fix namespace pollution in python3.5 and python3.6 (upstreamed fix)
The standard math library (libm) may follow IEEE-754 recommendation to
include an implementation of sinPi(), i.e. sinPi(x):=sin(pi*x).
And this triggers a name clash, found by FreeBSD developer
Steve Kargl, who worked on putting sinpi into libm used on FreeBSD
(it has to be named "sinpi", not "sinPi", cf. e.g.
https://en.cppreference.com/w/c/experimental/fpext4).

- python2.7 and > 3.6 are already fixed

PR:		232792
Submitted by:	Steve Kargl <sgk@troutmask.apl.washington.edu>, Dima Pasechnik <dimpase+freebsd@gmail.com>
Approved by:	python (maintainer timeout)
Obtained from:	b545ba0a50
2019-12-07 19:11:47 +00:00
Kubilay Kocak
e4c2b30ce8 lang/python{27,35,36,37,38}: Add closefrom(2) support
A single close(fd) syscall is cheap, but when MAXFDS (maximum file
descriptor number) is high, the loop calling close(fd) on each file
descriptor can take several milliseconds.

The default value of subprocess.Popen "close_fds" parameter changed to True
in Python 3. Compared to Python 2, close_fds=True can make Popen 10x
slower: see bpo-37790 [1]

The present workaround on FreeBSD to improve performance is to load and
mount the fdescfs kernel module, but this is not enabled by default.

This change adds minimum viable (and upstreamable) closefrom(2) syscall
support to Python's subprocess and posix modules, improving performance
significantly for loads that involve working with many processes, such as
diffoscope, ansible, and many others.

For additional optimizations, upstream recently (3.8) landed posix_spawn(2)
support [3] and has stated that they will adopt close_range(2) after Linux
merges it [4]. Linux/FreeBSD developers are already collaborating on
ensuring compatible implementations, with FreeBSD's implementation pending
in D21627. [5]

Thank you emaste, cem, kevans for providing analysis, input,
clarifications, comms/upstream support and patches.

[1] https://bugs.python.org/issue37790
[2] https://bugs.python.org/issue38061
[3] https://bugs.python.org/issue35537
[4] https://lwn.net/Articles/789023/
[5] https://reviews.freebsd.org/D21627

Additional References:

https://bugs.python.org/issue8052
https://bugs.python.org/issue11284
https://bugs.python.org/issue13788
https://bugs.python.org/issue1663329
https://www.python.org/dev/peps/pep-0446/

PR:		242274, 221700
Submitted by:	kevans (emaste, cem)
Approved by:	koobs (python (maintainer), santa)
2019-11-29 10:55:00 +00:00
Baptiste Daroussin
7eab0ea11d Drop the ipv6 virtual category for l* category as it is not relevant anymore 2019-10-09 11:53:57 +00:00
Mathieu Arnold
558224994b onvert to UCL & cleanup pkg-message (categories l-m) 2019-08-13 22:29:42 +00:00
Wen Heping
068e793643 - Update to python-3.6.9(include security fix)
PR:		238952
Submitted by:	wenheping2000@hotmail.com(myself)
Reviewed by:	koobs@
Exp-run by:	antoine@
MFH:		2019Q3
2019-07-08 23:10:32 +00:00
Antoine Brodin
8a40adf64d Recompile _sysconfigdata.py after reinplacing it
Reported by:	tcberner
With hat:	portmgr
2019-04-14 16:27:25 +00:00
Sunpoet Po-Chuan Hsieh
40c9c7f7eb Update devel/readline to 8.0
- Bump PORTREVISION of dependent ports for shlib change

Changes:	https://tiswww.case.edu/php/chet/readline/CHANGES
PR:		236156
Exp-run by:	antoine
2019-04-09 14:04:49 +00:00
Sunpoet Po-Chuan Hsieh
052f94b90f Add note to update python documentation (lang/python-doc-*) 2019-03-29 14:16:57 +00:00
Sunpoet Po-Chuan Hsieh
519fc0a478 Fix CVE-2019-5010
- Bump PORTREVISION for package change

Obtained from:	216a4d83c3
Reference:	https://bugs.python.org/issue35746
Security:	d74371d2-4fee-11e9-a5cd-1df8a848de3d
MFH:		2019Q1
2019-03-27 19:23:34 +00:00
Wen Heping
bbc317680d - Update lang/python36 to 3.6.8
PR:		234397
Submitted by:	wenheping2000@hotmail.com
Exp-run by:	antoine@
2019-01-01 08:48:18 +00:00
Rene Ladan
8a502cb2d4 Remove compatibility code for FreeBSD < 11.2 from all ports.
Simplify some ports where DragonFlyBSD no longer needs to be special-cased.
Submitted by:	rene
Reviewed by:	bapt, jbeich
Differential Revision:	https://reviews.freebsd.org/D17724
2018-11-02 13:32:34 +00:00
Wen Heping
04e1cc5fe5 - Update to 3.6.7
PR:		232504
Submitted by:	wen@(myself)
Exp-run by:	antoine@
2018-10-27 04:06:06 +00:00
Kubilay Kocak
929a1b95c8 lang/python27,35+: Remove MAKE_JOBS_UNSAFE
ports r393217 via bug 200622 [1] originally set MAKE_JOBS_UNSAFE=yes due to
incorrect uses of recursive make [2], causing intermittent build failures when
run with multiple jobs (-jN).

Upstream committed a fix for the issue in default (3.6, at the time), 3.5 and
2.7 which are now contained in all released lang/python?? port versions. 3.4 did
not receieve a backport merge.

lang/python3.5+ ports inadvertently inherited MAKE_JOBS_UNSAFE=yes, via
repocopies from lang/python34 on their creation, when they were infact safe to
use with -j.

Remove MAKE_JOBS_UNSAFE in all lang/python?? ports except python34 accordingly.

[1] https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=200622
[2] https://bugs.python.org/issue22359

PR:		232308
Reported by:	cem
Reviewed by:	cem
Approved by:	koobs (python)
MFH:		2018Q4
Differential Revision:	D17579
2018-10-17 06:23:59 +00:00
Tobias Kortkamp
dcbb4afe98 lang/python3?: Fix python3.?-config behavior when symlinked
When python3.?-config is symlinked to another location it starts
outputting bogus paths.  For example

$ pwd
/home/tobias
$ python3.6-config --includes
-I/usr/local/include/python3.6m -I/usr/local/include/python3.6m
$ ln -s /usr/local/bin/python3.6-config python3-config
$ ./python3-config --includes
-I/home/include/python3.6m -I/home/include/python3.6m

This breaks ports trying to use BINARY_ALIAS together with
python3.?-config.  Apply a patch to resolve the symlink first before
trying to find the install prefix.

PR:		229749
Submitted by:	tobik
Reviewed by:	antoine, miwi
Approved by:	python (miwi)
2018-07-26 08:58:50 +00:00
Kurt Jaeger
a06e03ee79 lang/python36: update 3.6.5 -> 3.6.6
PR:		229386
Exp-run by:	antoine
Relnotes:	https://docs.python.org/3.6/whatsnew/changelog.html#python-3-6-6-final
2018-07-06 08:10:39 +00:00
Bernard Spil
ae29cd406a lang/python36: Fix build with LibreSSL 2.7
PR:		226883
Submitted by:	Charlie Li <ml+freebsd vishwin info>
Approved by:	python (koobs)
Differential Revision:	https://reviews.freebsd.org/D14837
2018-04-28 19:30:00 +00:00
Sunpoet Po-Chuan Hsieh
af761c00f4 Update to 3.6.5
Changes:	https://docs.python.org/3.6/whatsnew/changelog.html
PR:		227090
Exp-run by:	antoine
2018-04-03 09:46:13 +00:00
Antoine Brodin
16d1193031 Revert r466162, exp-run is still in progress
With hat:	portmgr
2018-04-01 14:53:58 +00:00
Wen Heping
b428529141 - Update to 3.6.5 2018-04-01 14:45:45 +00:00
Sunpoet Po-Chuan Hsieh
8fc5634d4f Remove BROKEN_SSL=openssl-devel
PR:		225871
Submitted by:	brnrd
MFH:		2018Q1
2018-02-15 12:48:15 +00:00
Sunpoet Po-Chuan Hsieh
22b1b2a5a7 Silence patch messages 2018-02-12 19:04:02 +00:00
Sunpoet Po-Chuan Hsieh
77c1dd85f1 Remove over-patched shebang fix of Lib/cgi.py
The change from /usr/local/bin/python to /usr/local/bin/python3.6 is already done by USES=shebangfix.

% head -1 /usr/local/lib/python3.6/cgi.py
#!/usr/local/bin/python3.63.6
2018-02-11 16:52:53 +00:00
Sunpoet Po-Chuan Hsieh
5327348fea Clean up Makefile
- Move BROKEN_SSL upward
- Sort USES
- Remove CPE_*: all of them are default values
- Update PLIST_FILES: do not use %%
- Update http:// links in Makefile comments and patch files
2018-02-11 14:36:16 +00:00
Dmitry Marakasov
a0805c0e13 - Fix more shebangs
Approved by:	portmgr blanket
2017-12-21 17:21:14 +00:00
Sunpoet Po-Chuan Hsieh
1f0bde91fb Update to 3.6.4
Changes:	https://docs.python.org/3.6/whatsnew/changelog.html
2017-12-20 14:38:13 +00:00
Mathieu Arnold
551be3c723 Convert Python ports to FLAVORS.
Ports using USE_PYTHON=distutils are now flavored.  They will
  automatically get flavors (py27, py34, py35, py36) depending on what
  versions they support.

  There is also a USE_PYTHON=flavors for ports that do not use distutils
  but need FLAVORS to be set.  A USE_PYTHON=noflavors can be set if
  using distutils but flavors are not wanted.

  A new USE_PYTHON=optsuffix that will add PYTHON_PKGNAMESUFFIX has been
  added to cope with Python ports that did not have the Python
  PKGNAMEPREFIX but are flavored.

  USES=python now also exports a PY_FLAVOR variable that contains the
  current python flavor.  It can be used in dependency lines when the
  port itself is not python flavored.  For example, deskutils/calibre.

  By default, all the flavors are generated.  To only generate flavors
  for the versions in PYTHON2_DEFAULT and PYTHON3_DEFAULT, define
  BUILD_DEFAULT_PYTHON_FLAVORS in your make.conf.

  In all the ports with Python dependencies, the *_DEPENDS entries MUST
  end with the flavor so that the framework knows which to build/use.
  This is done by appending '@${PY_FLAVOR}' after the origin (or
  @${FLAVOR} if in a Python module with Python flavors, as the content
  will be the same).  For example:

    RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}six>0:devel/py-six@${PY_FLAVOR}

PR:		223071
Reviewed by:	portmgr, python
Sponsored by:	Absolight
Differential Revision:	https://reviews.freebsd.org/D12464
2017-11-30 15:50:30 +00:00
Sunpoet Po-Chuan Hsieh
dc6db978a7 Update to 3.6.3
Changes:	https://docs.python.org/3.6/whatsnew/changelog.html
2017-10-04 10:55:25 +00:00
Sean Bruno
64c2c626f8 Add a code block for the qemu-user enabled cross build environment. When using
this environment in poudriere, CC is not set to the default of /usr/bin/cc and
a cross-compile toolchain is used.  We need to hand edit this so that the run
time configuration for python matches what the FreeBSD base system provides.

PR:		208282
Submitted by:	manu
Approved by:	portmgr (mat)
2017-08-03 00:56:08 +00:00
Sunpoet Po-Chuan Hsieh
a8598a611b Update to 3.6.2
Changes:	https://docs.python.org/3.6/whatsnew/changelog.html
2017-07-17 18:42:02 +00:00
Danilo G. Baio
a4046066e9 lang/python{27,33,34,35,36}: Make Python curses module work with Unicode
Use readline from ports (USES= readline:port) and patch
setup.py to ignore readline from base. The patch is necessary for
FreeBSD < 1100000, as after this the readline library became an
INTERNALLIB, see base r268461 [1]

Link devel/readline against termcapw instead of termcap is part of
this change, see ports r444463 [2]

Note that this is the **ports** approach for getting Python curses
module working with Unicode. The other way is splitting libncurses
into separate libncurses and libtinfo in base, for which an open
issue exists [3].

Apart from Python language ports, at least www/rtv and
sysutils/py-ranger ports have been tested to work correctly
(display Unicode) after this change.

[1] https://svnweb.freebsd.org/changeset/base/268461
[2] https://svnweb.freebsd.org/changeset/ports/444463
[3] https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=197317

PR:		171246, 197317
Reported by:	Vitaly Magerya <vmagerya gmail com>
Reviewed by:	garga, koobs, miwi, sunpoet
Approved by:	garga (mentor), sunpoet (python, with hat)
Differential Revision:	https://reviews.freebsd.org/D11127
2017-06-28 02:37:53 +00:00
Sunpoet Po-Chuan Hsieh
cb037d3c98 Update devel/readline to 7.0 patch 3
- Bump PORTREVISION for shlib change

Changes:	https://cnswww.cns.cwru.edu/php/chet/readline/CHANGES
		https://lists.gnu.org/archive/html/bug-bash/2016-09/msg00107.html
		https://lists.gnu.org/archive/html/bug-readline/2017-01/msg00002.html
Differential Revision:	https://reviews.freebsd.org/D11172
PR:		219947
Exp-run by:	antoine
2017-06-27 13:46:53 +00:00
Mathieu Arnold
d43901881d Mark BROKEN with openssl-devel.
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/python36/work/stage/usr/local/lib/python3.6/lib-dynload/_ssl.so:No such file or directory

Sponsored by:	Absolight
2017-06-08 10:31:15 +00:00
Kubilay Kocak
2f6fe8dcec lang/python{27,33,34,35,36}: Install GDB debugging script
Users with a GDB that supports [1] Python extensions will automatically
load the extra debugging extensions when debugging programs that are
linked with libpythonX.Y.so.foo.

This enables extensions like 'py-bt' and 'py-frame' as described in
the Fedora Wiki Article: Easier Python Debugging [2], which can be
useful for debugging Python program state from crashes in C extensions,
for example.

[1] PYTHON option enabled in devel/gdb
[2] https://fedoraproject.org/wiki/Features/EasierPythonDebugging

PR:		203021
Submitted by:	cem
Reviewed by:	mat, koobs (python)
Approved by:	koobs (python)
Differential Revision: D10398
2017-06-06 12:56:47 +00:00
Sunpoet Po-Chuan Hsieh
b242df8cd3 Remove BROKEN_SSL
PR:		217703
Submitted by:	Melvyn Sopacua <m.r.sopacua@gmail.com>
2017-05-27 19:30:33 +00:00
Sunpoet Po-Chuan Hsieh
2619ed3ece Use BROKEN_SSL and fix indent 2017-04-16 11:08:44 +00:00
Martin Wilke
d69a0b0f5d - Fix shebang
Thanks to: amdmi3
2017-04-14 18:07:08 +00:00
Wen Heping
bb6cdc7f1f - Update to 3.6.1 2017-03-23 14:15:41 +00:00
Sunpoet Po-Chuan Hsieh
a92815fe29 Clean up Makefile
- Use PORTVERSION
- Remove CPE_VERSION
- Update WWW
2017-03-14 21:35:52 +00:00
Sunpoet Po-Chuan Hsieh
99f848d853 Fix PLIST
- While I'm here, sort PLIST

PR:		216444
Reported by:	Randy <randy+bsd@terbush.org>
2017-01-24 18:42:57 +00:00
Wen Heping
ec6ab67338 - Fix plist when build with WITHOUT_NIS=yes
PR:		216369
Submitted by:	claudius@ambtec.de
2017-01-23 02:49:10 +00:00
Sunpoet Po-Chuan Hsieh
f51c2f0758 - Remove TSC option
PR:		215580
Submitted by:	Roland Smith <rsmith@xs4all.nl>
2016-12-26 16:45:31 +00:00
Antoine Brodin
fd96352229 Fix packaging with non default ABI 2016-12-26 14:30:53 +00:00
Wen Heping
234f3ad658 - Repocopy lang/python35 --> lang/python36 and update to 3.6.0 2016-12-25 15:08:35 +00:00