mirror of
https://git.FreeBSD.org/ports.git
synced 2024-10-18 19:49:40 +00:00
The default versions of lang/python* have been changed to support the
new DEFAULT_VERSIONS variable. PYTHON_DEFAULT_VERSION, PYTHON2_DEFAULT_VERSION and PYTHON3_DEFAULT_VERSION are deprecated. If you have set them in your make.conf, you should change them something like DEFAULT_VERSIONS=python=2.7 python2=2.7 python3=3.3
This commit is contained in:
parent
f2803a979a
commit
f106670c04
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=329164
@ -20,5 +20,8 @@ ${_l:U}_DEFAULT= ${lang:C/.*=//g}
|
||||
PERL5_DEFAULT?= 5.14
|
||||
RUBY_DEFAULT?= 1.9
|
||||
TCLTK_DEFAULT?= 8.6
|
||||
PYTHON_DEFAULT?= 2.7
|
||||
PYTHON2_DEFAULT?= 2.7
|
||||
PYTHON3_DEFAULT?= 3.3
|
||||
|
||||
.endif
|
||||
|
@ -87,25 +87,15 @@ Python_Include_MAINTAINER= python@FreeBSD.org
|
||||
#
|
||||
# PYTHON_DEFAULT_VERSION
|
||||
# - Version of the default python binary in your ${PATH}, in
|
||||
# the format "python2.7". Set this in your /etc/make.conf
|
||||
# in case you want to use a specific version as a default.
|
||||
# default: python2.7
|
||||
# the format "python2.7".
|
||||
#
|
||||
# PYTHON2_DEFAULT_VERSION
|
||||
# - Version of the default python2 binary in your ${PATH}, in
|
||||
# the format "python2.7". Set this in your /etc/make.conf
|
||||
# in case you want to use a specific version as a default.
|
||||
# Note that PYTHON_DEFAULT_VERSION always will have
|
||||
# precedence before this value, if it matches "python2*"
|
||||
# default: python2.7
|
||||
# the format "python2.7".
|
||||
#
|
||||
# PYTHON3_DEFAULT_VERSION
|
||||
# - Version of the default python3 binary in your ${PATH}, in
|
||||
# the format "python3.2". Set this in your /etc/make.conf
|
||||
# in case you want to use a specific version as a default.
|
||||
# Note that PYTHON_DEFAULT_VERSION always will have
|
||||
# precedence before this value, if it matches "python3*"
|
||||
# default: python3.3
|
||||
# the format "python3.2".
|
||||
#
|
||||
# PYTHON_MAJOR_VER - Python version major number. 2 for python-2.x,
|
||||
# 3 for python-3.x and so on.
|
||||
@ -227,27 +217,45 @@ _PYTHON_PORTBRANCH= 2.7
|
||||
_PYTHON_ALLBRANCHES= 2.7 2.6 3.3 3.2 3.1 # preferred first
|
||||
|
||||
# Determine version number of Python to use
|
||||
.if !defined(PYTHON_DEFAULT_VERSION)
|
||||
. if exists(${LOCALBASE}/bin/python)
|
||||
.include "${PORTSDIR}/Mk/bsd.default-versions.mk"
|
||||
|
||||
.if defined(PYTHON_DEFAULT_VERSION)
|
||||
WARNING+= "PYTHON_DEFAULT_VERSION is defined, consider using DEFAULT_VERSIONS=python=${PYTHON_DEFAULT_VERSION:S/^python//} instead"
|
||||
.endif
|
||||
.if defined(PYTHON2_DEFAULT_VERSION)
|
||||
WARNING+= "PYTHON2_DEFAULT_VERSION is defined, consider using DEFAULT_VERSIONS=python2=${PYTHON2_DEFAULT_VERSION:S/^python//} instead"
|
||||
.endif
|
||||
.if defined(PYTHON3_DEFAULT_VERSION)
|
||||
WARNING+= "PYTHON3_DEFAULT_VERSION is defined, consider using DEFAULT_VERSIONS=python3=${PYTHON3_DEFAULT_VERSION:S/^python//} instead"
|
||||
.endif
|
||||
|
||||
.if exists(${LOCALBASE}/bin/python)
|
||||
_PYTHON_DEFAULT_VERSION!= (${LOCALBASE}/bin/python -c \
|
||||
'import sys; print(sys.version[:3])' 2> /dev/null \
|
||||
|| ${ECHO_CMD} ${_PYTHON_PORTBRANCH}) | ${TAIL} -1
|
||||
. else
|
||||
_PYTHON_DEFAULT_VERSION= ${_PYTHON_PORTBRANCH}
|
||||
. endif
|
||||
PYTHON_DEFAULT_VERSION= python${_PYTHON_DEFAULT_VERSION}
|
||||
.if defined(PYTHON_DEFAULT) && (${PYTHON_DEFAULT} != ${_PYTHON_DEFAULT_VERSION})
|
||||
WARNING+= "Your requested default python version ${PYTHON_DEFAULT} is different from the installed default python interpreter version ${_PYTHON_DEFAULT_VERSION}"
|
||||
.endif
|
||||
PYTHON_DEFAULT_VERSION= python${_PYTHON_DEFAULT_VERSION}
|
||||
.else
|
||||
PYTHON_DEFAULT_VERSION= python${PYTHON_DEFAULT}
|
||||
.endif # exists(${LOCALBASE}/bin/python)
|
||||
|
||||
.if ${PYTHON_DEFAULT_VERSION:R} == "python2"
|
||||
# Is only a meta-port version defined?
|
||||
.if ${PYTHON_DEFAULT_VERSION} == "python2"
|
||||
PYTHON2_DEFAULT_VERSION?= python${PYTHON2_DEFAULT}
|
||||
.elif ${PYTHON_DEFAULT_VERSION:R} == "python2"
|
||||
PYTHON2_DEFAULT_VERSION= ${PYTHON_DEFAULT_VERSION}
|
||||
.else
|
||||
PYTHON2_DEFAULT_VERSION?= python2.7
|
||||
PYTHON2_DEFAULT_VERSION?= python${PYTHON2_DEFAULT}
|
||||
.endif
|
||||
|
||||
.if ${PYTHON_DEFAULT_VERSION:R} == "python3"
|
||||
PYTHON3_DEFAULT_VERSION= ${PYTHON_DEFAULT_VERSION}
|
||||
.if ${PYTHON_DEFAULT_VERSION} == "python3"
|
||||
PYTHON3_DEFAULT_VERSION?= python${PYTHON3_DEFAULT}
|
||||
.elif ${PYTHON_DEFAULT_VERSION:R} == "python3"
|
||||
PYTHON3_DEFAULT_VERSION= ${PYTHON_DEFAULT_VERSION}
|
||||
.else
|
||||
PYTHON3_DEFAULT_VERSION?= python3.3
|
||||
PYTHON3_DEFAULT_VERSION?= python${PYTHON3_DEFAULT}
|
||||
.endif
|
||||
|
||||
.if defined(PYTHON_VERSION)
|
||||
|
14
UPDATING
14
UPDATING
@ -5,6 +5,20 @@ they are unavoidable.
|
||||
You should get into the habit of checking this file for changes each time
|
||||
you update your ports collection, before attempting any port upgrades.
|
||||
|
||||
20131003:
|
||||
AFFECTS: users of lang/python* and ports
|
||||
AUTHOR: mva@FreeBSD.org
|
||||
|
||||
The default versions of lang/python* have been changed to support the
|
||||
new DEFAULT_VERSIONS variable.
|
||||
|
||||
PYTHON_DEFAULT_VERSION, PYTHON2_DEFAULT_VERSION and
|
||||
PYTHON3_DEFAULT_VERSION are deprecated. If you have set them in your
|
||||
make.conf, you should change them something like
|
||||
|
||||
DEFAULT_VERSIONS=python=2.7 python2=2.7 python3=3.3
|
||||
|
||||
|
||||
20130929:
|
||||
AFFECTS: users of x11/pixman
|
||||
AUTHOR: zeising@FreeBSD.org
|
||||
|
Loading…
Reference in New Issue
Block a user