summaryrefslogtreecommitdiff
path: root/lang/python
diff options
context:
space:
mode:
authorjoerg <joerg@pkgsrc.org>2008-04-18 12:24:21 +0000
committerjoerg <joerg@pkgsrc.org>2008-04-18 12:24:21 +0000
commit2bdd4daeaad1e0cc0a7b7b19b7d5cd4b7a555795 (patch)
tree7e769fcc66a24a17b3ff7fe16f040e849ea36710 /lang/python
parentfcc5b2a0e1adc7aaee69639166934a0f36c05f10 (diff)
downloadpkgsrc-2bdd4daeaad1e0cc0a7b7b19b7d5cd4b7a555795.tar.gz
As all Python packages are required to include lang/python/pyversion.mk
anyway, simplify logic a bit: Add Python 2.5 to the default list, but also mark it as incompatible if wip/python25 is not present. Move the Darwin handling after setting a default value. Provide a new variable _PYTHON_VERSIONS_ACCEPTED that is filtered by PYTHON_VERSIONS_INCOMPATIBLE. This helps to avoid providing broken dependencies when a version is not supported as PYPKGPREFIX wouldn't be set in that case.
Diffstat (limited to 'lang/python')
-rw-r--r--lang/python/pyversion.mk14
1 files changed, 8 insertions, 6 deletions
diff --git a/lang/python/pyversion.mk b/lang/python/pyversion.mk
index 66368c22bff..7a56840ade5 100644
--- a/lang/python/pyversion.mk
+++ b/lang/python/pyversion.mk
@@ -1,4 +1,4 @@
-# $NetBSD: pyversion.mk,v 1.55 2008/04/11 15:37:30 abs Exp $
+# $NetBSD: pyversion.mk,v 1.56 2008/04/18 12:24:21 joerg Exp $
# This file determines which Python version is used as a dependency for
# a package.
@@ -62,15 +62,16 @@ BUILD_DEFS+= PYTHON_VERSION_DEFAULT
BUILD_DEFS_EFFECTS+= PYPACKAGE
PYTHON_VERSION_DEFAULT?= 24
+PYTHON_VERSIONS_ACCEPTED?= 25 24 23 22 21 20
+PYTHON_VERSIONS_INCOMPATIBLE?= # empty by default
+
.if ${OPSYS} == "Darwin"
PYTHON_VERSIONS_INCOMPATIBLE+= 22 21 20 15
.endif
-.if exists(../../wip/python25/Makefile)
-PYTHON_VERSIONS_ACCEPTED?= 25 24 23 22 21 20
-.else
-PYTHON_VERSIONS_ACCEPTED?= 24 23 22 21 20
+
+.if !exists(../../wip/python25/Makefile)
+PYTHON_VERSIONS_INCOMPATIBLE+= 25
.endif
-PYTHON_VERSIONS_INCOMPATIBLE?= # empty by default
BUILDLINK_API_DEPENDS.python15?= python15>=1.5
BUILDLINK_API_DEPENDS.python20?= python20>=2.0
@@ -84,6 +85,7 @@ BUILDLINK_API_DEPENDS.python25?= python25>=2.5.1
.for pv in ${PYTHON_VERSIONS_ACCEPTED}
.if empty(PYTHON_VERSIONS_INCOMPATIBLE:M${pv})
_PYTHON_VERSION_${pv}_OK= yes
+_PYTHON_VERSIONS_ACCEPTED+= ${pv}
.endif
.endfor