summaryrefslogtreecommitdiff
path: root/lang/python25
diff options
context:
space:
mode:
authorjoerg <joerg>2009-03-20 19:23:50 +0000
committerjoerg <joerg>2009-03-20 19:23:50 +0000
commit405c61d80251d8e80401aed2264d4bede218cb22 (patch)
tree647e974495c5d41703d41ca2e71c9b6063b9153a /lang/python25
parentf0f715d4dd4a290c5c6ae716c774f59caf5aa61c (diff)
downloadpkgsrc-405c61d80251d8e80401aed2264d4bede218cb22.tar.gz
Simply and speed up buildlink3.mk files and processing.
This changes the buildlink3.mk files to use an include guard for the recursive include. The use of BUILDLINK_DEPTH, BUILDLINK_DEPENDS, BUILDLINK_PACKAGES and BUILDLINK_ORDER is handled by a single new variable BUILDLINK_TREE. Each buildlink3.mk file adds a pair of enter/exit marker, which can be used to reconstruct the tree and to determine first level includes. Avoiding := for large variables (BUILDLINK_ORDER) speeds up parse time as += has linear complexity. The include guard reduces system time by avoiding reading files over and over again. For complex packages this reduces both %user and %sys time to half of the former time.
Diffstat (limited to 'lang/python25')
-rw-r--r--lang/python25/buildlink3.mk20
1 files changed, 6 insertions, 14 deletions
diff --git a/lang/python25/buildlink3.mk b/lang/python25/buildlink3.mk
index 34c92fd4a6b..046af0b6d14 100644
--- a/lang/python25/buildlink3.mk
+++ b/lang/python25/buildlink3.mk
@@ -1,17 +1,10 @@
-# $NetBSD: buildlink3.mk,v 1.2 2009/01/23 03:05:53 dsainty Exp $
+# $NetBSD: buildlink3.mk,v 1.3 2009/03/20 19:24:52 joerg Exp $
-BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
-PYTHON25_BUILDLINK3_MK:= ${PYTHON25_BUILDLINK3_MK}+
+BUILDLINK_TREE+= python25
-.if !empty(BUILDLINK_DEPTH:M+)
-BUILDLINK_DEPENDS+= python25
-.endif
-
-BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Npython25}
-BUILDLINK_PACKAGES+= python25
-BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}python25
+.if !defined(PYTHON25_BUILDLINK3_MK)
+PYTHON25_BUILDLINK3_MK:=
-.if !empty(PYTHON25_BUILDLINK3_MK:M+)
BUILDLINK_API_DEPENDS.python25+= python25>=2.5
BUILDLINK_ABI_DEPENDS.python25+= python25>=2.5.2
BUILDLINK_PKGSRCDIR.python25?= ../../lang/python25
@@ -24,8 +17,6 @@ BUILDLINK_INCDIRS.python25+= include/python2.5
BUILDLINK_LIBDIRS.python25+= lib/python2.5/config
BUILDLINK_TRANSFORM+= l:python:python2.5
-.endif # PYTHON25_BUILDLINK3_MK
-
.include "../../mk/bsd.fast.prefs.mk"
.if ${OPSYS} != "IRIX"
. include "../../mk/bdb.buildlink3.mk"
@@ -34,5 +25,6 @@ BUILDLINK_TRANSFORM+= l:python:python2.5
.include "../../mk/dlopen.buildlink3.mk"
.include "../../mk/pthread.buildlink3.mk"
.include "../../devel/gettext-lib/buildlink3.mk"
+.endif # PYTHON25_BUILDLINK3_MK
-BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//}
+BUILDLINK_TREE+= -python25