diff options
author | Marcus von Appen <mva@FreeBSD.org> | 2013-09-15 12:52:28 +0000 |
---|---|---|
committer | Marcus von Appen <mva@FreeBSD.org> | 2013-09-15 12:52:28 +0000 |
commit | 1e35ab7368a5a1f3a39a62241480a34719680e9f (patch) | |
tree | ff94ebc9e7c79c921019300543c3b38f19ee3fa9 | |
parent | 2d9b5a640b61146297285b94093ac6e62d7c238d (diff) |
Notes
-rw-r--r-- | Mk/bsd.python.mk | 34 | ||||
-rw-r--r-- | lang/python2/Makefile | 3 |
2 files changed, 27 insertions, 10 deletions
diff --git a/Mk/bsd.python.mk b/Mk/bsd.python.mk index 19f538101470..e7552e8f3aba 100644 --- a/Mk/bsd.python.mk +++ b/Mk/bsd.python.mk @@ -11,11 +11,11 @@ Python_Include_MAINTAINER= python@FreeBSD.org # This file contains some variable definitions that are supposed to # make your life easier when dealing with ports related to the Python -# language. It's automatically included when USE_PYTHON or PYTHON_VERSION -# is defined in the ports' makefile. Define PYTHON_VERSION to override the -# defaults that USE_PYTHON would give you. If your port requires only some -# set of Python versions, you can define USE_PYTHON as [min]-[max] or -# min+. (eg. 3.1-3.2, 2.7+ or -3.2) +# language. It's automatically included when USE_PYTHON is defined in +# the ports' makefile. If your port requires only some set of Python +# versions, you can define USE_PYTHON as [min]-[max] or min+ or -max +# or as an explicit version (eg. 3.1-3.2 for [min]-[max], +# 2.7+ or -3.2 for min+ and -max or 2.6 for an explicit version). # # The variables: # @@ -87,13 +87,23 @@ 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 an older version as a default. +# in case you want to use a specific version as a default. +# default: 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 # # PYTHON3_DEFAULT_VERSION -# - Version of the default python binary in your ${PATH}, in +# - 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 an older version as a default. +# 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 # # PYTHON_MAJOR_VER - Python version major number. 2 for python-2.x, @@ -283,10 +293,16 @@ _PYTHON_DEFAULT_VERSION= ${_PYTHON_PORTBRANCH} PYTHON_DEFAULT_VERSION= python${_PYTHON_DEFAULT_VERSION} .endif +.if ${PYTHON_DEFAULT_VERSION:R} == "python2" +PYTHON2_DEFAULT_VERSION= ${PYTHON_DEFAULT_VERSION} +.else +PYTHON2_DEFAULT_VERSION?= python2.7 +.endif + .if ${PYTHON_DEFAULT_VERSION:R} == "python3" PYTHON3_DEFAULT_VERSION= ${PYTHON_DEFAULT_VERSION} .else -PYTHON3_DEFAULT_VERSION= python3.3 +PYTHON3_DEFAULT_VERSION?= python3.3 .endif .if defined(PYTHON_VERSION) diff --git a/lang/python2/Makefile b/lang/python2/Makefile index 1e0448e61aa8..6a6c6b950803 100644 --- a/lang/python2/Makefile +++ b/lang/python2/Makefile @@ -2,6 +2,7 @@ PORTNAME= python2 PORTVERSION= ${PYTHON_MAJOR_VER} +PORTREVISION= 1 CATEGORIES= lang python ipv6 MASTER_SITES= # empty DISTFILES= # empty @@ -11,7 +12,7 @@ MAINTAINER= python@FreeBSD.org COMMENT= The "meta-port" for version 2 of the Python interpreter USE_PYTHON_RUN= yes -PYTHON_VERSION= ${PYTHON_DEFAULT_VERSION} +PYTHON_VERSION= ${PYTHON2_DEFAULT_VERSION} NO_BUILD= yes PYTHON_NO_DEPENDS= yes |