diff options
author | joerg <joerg@pkgsrc.org> | 2009-03-20 19:23:50 +0000 |
---|---|---|
committer | joerg <joerg@pkgsrc.org> | 2009-03-20 19:23:50 +0000 |
commit | 2d1ba244e90207d03eef397a99aa4091baeec5b3 (patch) | |
tree | 647e974495c5d41703d41ca2e71c9b6063b9153a /comms | |
parent | 4bf0a20854ae9e07b7965977a713f2efee890976 (diff) | |
download | pkgsrc-2d1ba244e90207d03eef397a99aa4091baeec5b3.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 'comms')
-rw-r--r-- | comms/gnome-pilot/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/jpilot/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/libmal/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/libopensync/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/libsyncml/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/obexftp/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/openobex/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/pilot-link-libs/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/synce-librapi2/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/synce-libsynce/buildlink3.mk | 19 | ||||
-rw-r--r-- | comms/zaptel-netbsd/buildlink3.mk | 19 |
11 files changed, 66 insertions, 143 deletions
diff --git a/comms/gnome-pilot/buildlink3.mk b/comms/gnome-pilot/buildlink3.mk index 340abc55481..79d58ad27ea 100644 --- a/comms/gnome-pilot/buildlink3.mk +++ b/comms/gnome-pilot/buildlink3.mk @@ -1,26 +1,19 @@ -# $NetBSD: buildlink3.mk,v 1.20 2008/09/06 20:54:31 wiz Exp $ +# $NetBSD: buildlink3.mk,v 1.21 2009/03/20 19:24:02 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -GNOME_PILOT_BUILDLINK3_MK:= ${GNOME_PILOT_BUILDLINK3_MK}+ +BUILDLINK_TREE+= gnome-pilot -.if !empty(BUILDLINK_DEPTH:M+) -BUILDLINK_DEPENDS+= gnome-pilot -.endif +.if !defined(GNOME_PILOT_BUILDLINK3_MK) +GNOME_PILOT_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Ngnome-pilot} -BUILDLINK_PACKAGES+= gnome-pilot -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}gnome-pilot - -.if !empty(GNOME_PILOT_BUILDLINK3_MK:M+) BUILDLINK_API_DEPENDS.gnome-pilot?= gnome-pilot>=2.0.12nb2 BUILDLINK_ABI_DEPENDS.gnome-pilot?= gnome-pilot>=2.0.15nb6 BUILDLINK_PKGSRCDIR.gnome-pilot?= ../../comms/gnome-pilot -.endif # GNOME_PILOT_BUILDLINK3_MK .include "../../devel/gettext-lib/buildlink3.mk" .include "../../comms/pilot-link-libs/buildlink3.mk" .include "../../devel/libglade/buildlink3.mk" .include "../../textproc/libxml2/buildlink3.mk" .include "../../x11/gnome-panel/buildlink3.mk" +.endif # GNOME_PILOT_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -gnome-pilot diff --git a/comms/jpilot/buildlink3.mk b/comms/jpilot/buildlink3.mk index fd7ce54ead2..9484efa0f59 100644 --- a/comms/jpilot/buildlink3.mk +++ b/comms/jpilot/buildlink3.mk @@ -1,24 +1,17 @@ -# $NetBSD: buildlink3.mk,v 1.12 2008/10/09 19:01:57 bad Exp $ +# $NetBSD: buildlink3.mk,v 1.13 2009/03/20 19:24:02 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -JPILOT_BUILDLINK3_MK:= ${JPILOT_BUILDLINK3_MK}+ +BUILDLINK_TREE+= jpilot -.if !empty(BUILDLINK_DEPTH:M+) -BUILDLINK_DEPENDS+= jpilot -.endif +.if !defined(JPILOT_BUILDLINK3_MK) +JPILOT_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Njpilot} -BUILDLINK_PACKAGES+= jpilot -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}jpilot - -.if !empty(JPILOT_BUILDLINK3_MK:M+) BUILDLINK_API_DEPENDS.jpilot+= jpilot>=1.6.0 BUILDLINK_ABI_DEPENDS.jpilot+= jpilot>=1.6.0 BUILDLINK_PKGSRCDIR.jpilot?= ../../comms/jpilot -.endif # JPILOT_BUILDLINK3_MK .include "../../comms/pilot-link-libs/buildlink3.mk" .include "../../devel/gettext-lib/buildlink3.mk" .include "../../x11/gtk2/buildlink3.mk" +.endif # JPILOT_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -jpilot diff --git a/comms/libmal/buildlink3.mk b/comms/libmal/buildlink3.mk index be054bcc391..42998d23c14 100644 --- a/comms/libmal/buildlink3.mk +++ b/comms/libmal/buildlink3.mk @@ -1,22 +1,15 @@ -# $NetBSD: buildlink3.mk,v 1.7 2006/07/08 23:10:38 jlam Exp $ +# $NetBSD: buildlink3.mk,v 1.8 2009/03/20 19:24:02 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -LIBMAL_BUILDLINK3_MK:= ${LIBMAL_BUILDLINK3_MK}+ +BUILDLINK_TREE+= libmal -.if !empty(BUILDLINK_DEPTH:M+) -BUILDLINK_DEPENDS+= libmal -.endif +.if !defined(LIBMAL_BUILDLINK3_MK) +LIBMAL_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nlibmal} -BUILDLINK_PACKAGES+= libmal -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}libmal - -.if !empty(LIBMAL_BUILDLINK3_MK:M+) BUILDLINK_API_DEPENDS.libmal+= libmal>=0.40 BUILDLINK_ABI_DEPENDS.libmal+= libmal>=0.40nb2 BUILDLINK_PKGSRCDIR.libmal?= ../../comms/libmal -.endif # LIBMAL_BUILDLINK3_MK .include "../../comms/pilot-link-libs/buildlink3.mk" +.endif # LIBMAL_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -libmal diff --git a/comms/libopensync/buildlink3.mk b/comms/libopensync/buildlink3.mk index 4e6b8e0cfd9..ebb72c89fb5 100644 --- a/comms/libopensync/buildlink3.mk +++ b/comms/libopensync/buildlink3.mk @@ -1,23 +1,16 @@ -# $NetBSD: buildlink3.mk,v 1.2 2007/05/23 21:27:26 seb Exp $ +# $NetBSD: buildlink3.mk,v 1.3 2009/03/20 19:24:02 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -LIBOPENSYNC_BUILDLINK3_MK:= ${LIBOPENSYNC_BUILDLINK3_MK}+ +BUILDLINK_TREE+= libopensync -.if ${BUILDLINK_DEPTH} == "+" -BUILDLINK_DEPENDS+= libopensync -.endif +.if !defined(LIBOPENSYNC_BUILDLINK3_MK) +LIBOPENSYNC_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nlibopensync} -BUILDLINK_PACKAGES+= libopensync -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}libopensync - -.if ${LIBOPENSYNC_BUILDLINK3_MK} == "+" BUILDLINK_API_DEPENDS.libopensync+= libopensync>=0.22 BUILDLINK_PKGSRCDIR.libopensync?= ../../comms/libopensync -.endif # LIBOPENSYNC_BUILDLINK3_MK .include "../../databases/sqlite3/buildlink3.mk" .include "../../devel/glib2/buildlink3.mk" .include "../../textproc/libxml2/buildlink3.mk" +.endif # LIBOPENSYNC_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -libopensync diff --git a/comms/libsyncml/buildlink3.mk b/comms/libsyncml/buildlink3.mk index 90e83d9174c..df0f0f481f8 100644 --- a/comms/libsyncml/buildlink3.mk +++ b/comms/libsyncml/buildlink3.mk @@ -1,19 +1,12 @@ -# $NetBSD: buildlink3.mk,v 1.1.1.1 2008/01/12 14:09:35 dillo Exp $ +# $NetBSD: buildlink3.mk,v 1.2 2009/03/20 19:24:02 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -LIBSYNCML_BUILDLINK3_MK:= ${LIBSYNCML_BUILDLINK3_MK}+ +BUILDLINK_TREE+= libsyncml -.if ${BUILDLINK_DEPTH} == "+" -BUILDLINK_DEPENDS+= libsyncml -.endif +.if !defined(LIBSYNCML_BUILDLINK3_MK) +LIBSYNCML_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nlibsyncml} -BUILDLINK_PACKAGES+= libsyncml -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}libsyncml - -.if ${LIBSYNCML_BUILDLINK3_MK} == "+" BUILDLINK_API_DEPENDS.libsyncml+= libsyncml>=0.4.5 BUILDLINK_PKGSRCDIR.libsyncml?= ../../comms/libsyncml -.endif # LIBSYNCML_BUILDLINK3_MK +.endif # LIBSYNCML_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -libsyncml diff --git a/comms/obexftp/buildlink3.mk b/comms/obexftp/buildlink3.mk index d0cea24537f..b75205489f2 100644 --- a/comms/obexftp/buildlink3.mk +++ b/comms/obexftp/buildlink3.mk @@ -1,23 +1,16 @@ -# $NetBSD: buildlink3.mk,v 1.1 2006/11/30 00:07:03 xtraeme Exp $ +# $NetBSD: buildlink3.mk,v 1.2 2009/03/20 19:24:02 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -OBEXFTP_BUILDLINK3_MK:= ${OBEXFTP_BUILDLINK3_MK}+ +BUILDLINK_TREE+= obexftp -.if ${BUILDLINK_DEPTH} == "+" -BUILDLINK_DEPENDS+= obexftp -.endif +.if !defined(OBEXFTP_BUILDLINK3_MK) +OBEXFTP_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nobexftp} -BUILDLINK_PACKAGES+= obexftp -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}obexftp - -.if ${OBEXFTP_BUILDLINK3_MK} == "+" BUILDLINK_API_DEPENDS.obexftp+= obexftp>=0.20nb1 BUILDLINK_PKGSRCDIR.obexftp?= ../../comms/obexftp -.endif # OBEXFTP_BUILDLINK3_MK .include "../../comms/openobex/buildlink3.mk" .include "../../converters/libiconv/buildlink3.mk" .include "../../devel/libusb/buildlink3.mk" +.endif # OBEXFTP_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -obexftp diff --git a/comms/openobex/buildlink3.mk b/comms/openobex/buildlink3.mk index 1c61452edf2..857962688c2 100644 --- a/comms/openobex/buildlink3.mk +++ b/comms/openobex/buildlink3.mk @@ -1,21 +1,14 @@ -# $NetBSD: buildlink3.mk,v 1.10 2009/03/05 21:10:27 joerg Exp $ +# $NetBSD: buildlink3.mk,v 1.11 2009/03/20 19:24:03 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -OPENOBEX_BUILDLINK3_MK:= ${OPENOBEX_BUILDLINK3_MK}+ +BUILDLINK_TREE+= openobex -.if ${BUILDLINK_DEPTH} == "+" -BUILDLINK_DEPENDS+= openobex -.endif +.if !defined(OPENOBEX_BUILDLINK3_MK) +OPENOBEX_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nopenobex} -BUILDLINK_PACKAGES+= openobex -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}openobex - -.if ${OPENOBEX_BUILDLINK3_MK} == "+" BUILDLINK_API_DEPENDS.openobex+= openobex>=1.3 BUILDLINK_PKGSRCDIR.openobex?= ../../comms/openobex -.endif # OPENOBEX_BUILDLINK3_MK .include "../../devel/libusb/buildlink3.mk" +.endif # OPENOBEX_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -openobex diff --git a/comms/pilot-link-libs/buildlink3.mk b/comms/pilot-link-libs/buildlink3.mk index 1171533c0c1..dfc902ae6aa 100644 --- a/comms/pilot-link-libs/buildlink3.mk +++ b/comms/pilot-link-libs/buildlink3.mk @@ -1,24 +1,17 @@ -# $NetBSD: buildlink3.mk,v 1.9 2007/01/26 01:26:46 markd Exp $ +# $NetBSD: buildlink3.mk,v 1.10 2009/03/20 19:24:03 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -PILOT_LINK_LIBS_BUILDLINK3_MK:= ${PILOT_LINK_LIBS_BUILDLINK3_MK}+ +BUILDLINK_TREE+= pilot-link-libs -.if !empty(BUILDLINK_DEPTH:M+) -BUILDLINK_DEPENDS+= pilot-link-libs -.endif +.if !defined(PILOT_LINK_LIBS_BUILDLINK3_MK) +PILOT_LINK_LIBS_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Npilot-link-libs} -BUILDLINK_PACKAGES+= pilot-link-libs -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}pilot-link-libs - -.if !empty(PILOT_LINK_LIBS_BUILDLINK3_MK:M+) BUILDLINK_API_DEPENDS.pilot-link-libs+= pilot-link-libs>=0.11.7nb1 BUILDLINK_ABI_DEPENDS.pilot-link-libs+= pilot-link-libs>=0.12.1 BUILDLINK_PKGSRCDIR.pilot-link-libs?= ../../comms/pilot-link-libs -.endif # PILOT_LINK_LIBS_BUILDLINK3_MK .include "../../converters/libiconv/buildlink3.mk" .include "../../devel/ncurses/buildlink3.mk" .include "../../devel/readline/buildlink3.mk" +.endif # PILOT_LINK_LIBS_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -pilot-link-libs diff --git a/comms/synce-librapi2/buildlink3.mk b/comms/synce-librapi2/buildlink3.mk index df4d19baa93..3c33492ba99 100644 --- a/comms/synce-librapi2/buildlink3.mk +++ b/comms/synce-librapi2/buildlink3.mk @@ -1,21 +1,14 @@ -# $NetBSD: buildlink3.mk,v 1.5 2006/07/08 23:10:38 jlam Exp $ +# $NetBSD: buildlink3.mk,v 1.6 2009/03/20 19:24:03 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -SYNCE_LIBRAPI2_BUILDLINK3_MK:= ${SYNCE_LIBRAPI2_BUILDLINK3_MK}+ +BUILDLINK_TREE+= synce-librapi2 -.if !empty(BUILDLINK_DEPTH:M+) -BUILDLINK_DEPENDS+= synce-librapi2 -.endif +.if !defined(SYNCE_LIBRAPI2_BUILDLINK3_MK) +SYNCE_LIBRAPI2_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nsynce-librapi2} -BUILDLINK_PACKAGES+= synce-librapi2 -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}synce-librapi2 - -.if !empty(SYNCE_LIBRAPI2_BUILDLINK3_MK:M+) BUILDLINK_API_DEPENDS.synce-librapi2+= synce-librapi2>=0.9.1 BUILDLINK_PKGSRCDIR.synce-librapi2?= ../../comms/synce-librapi2 -.endif # SYNCE_LIBRAPI2_BUILDLINK3_MK .include "../../comms/synce-libsynce/buildlink3.mk" +.endif # SYNCE_LIBRAPI2_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -synce-librapi2 diff --git a/comms/synce-libsynce/buildlink3.mk b/comms/synce-libsynce/buildlink3.mk index 928e73846a7..4956258e2cd 100644 --- a/comms/synce-libsynce/buildlink3.mk +++ b/comms/synce-libsynce/buildlink3.mk @@ -1,21 +1,14 @@ -# $NetBSD: buildlink3.mk,v 1.5 2006/07/08 23:10:39 jlam Exp $ +# $NetBSD: buildlink3.mk,v 1.6 2009/03/20 19:24:03 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -SYNCE_LIBSYNCE_BUILDLINK3_MK:= ${SYNCE_LIBSYNCE_BUILDLINK3_MK}+ +BUILDLINK_TREE+= synce-libsynce -.if !empty(BUILDLINK_DEPTH:M+) -BUILDLINK_DEPENDS+= synce-libsynce -.endif +.if !defined(SYNCE_LIBSYNCE_BUILDLINK3_MK) +SYNCE_LIBSYNCE_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nsynce-libsynce} -BUILDLINK_PACKAGES+= synce-libsynce -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}synce-libsynce - -.if !empty(SYNCE_LIBSYNCE_BUILDLINK3_MK:M+) BUILDLINK_API_DEPENDS.synce-libsynce+= synce-libsynce>=0.9.1 BUILDLINK_PKGSRCDIR.synce-libsynce?= ../../comms/synce-libsynce -.endif # SYNCE_LIBSYNCE_BUILDLINK3_MK .include "../../converters/libiconv/buildlink3.mk" +.endif # SYNCE_LIBSYNCE_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -synce-libsynce diff --git a/comms/zaptel-netbsd/buildlink3.mk b/comms/zaptel-netbsd/buildlink3.mk index 5f5b9cdd258..f0cd577f489 100644 --- a/comms/zaptel-netbsd/buildlink3.mk +++ b/comms/zaptel-netbsd/buildlink3.mk @@ -1,23 +1,16 @@ -# $NetBSD: buildlink3.mk,v 1.7 2006/07/08 23:10:39 jlam Exp $ +# $NetBSD: buildlink3.mk,v 1.8 2009/03/20 19:24:03 joerg Exp $ -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ -ZAPTEL_NETBSD_BUILDLINK3_MK:= ${ZAPTEL_NETBSD_BUILDLINK3_MK}+ +BUILDLINK_TREE+= zaptel-netbsd -.if !empty(BUILDLINK_DEPTH:M+) -BUILDLINK_DEPENDS+= zaptel-netbsd -.endif +.if !defined(ZAPTEL_NETBSD_BUILDLINK3_MK) +ZAPTEL_NETBSD_BUILDLINK3_MK:= -BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nzaptel-netbsd} -BUILDLINK_PACKAGES+= zaptel-netbsd -BUILDLINK_ORDER:= ${BUILDLINK_ORDER} ${BUILDLINK_DEPTH}zaptel-netbsd - -.if !empty(ZAPTEL_NETBSD_BUILDLINK3_MK:M+) BUILDLINK_API_DEPENDS.zaptel-netbsd+= zaptel-netbsd>=20050314 BUILDLINK_ABI_DEPENDS.zaptel-netbsd?= zaptel-netbsd>=20060127nb1 BUILDLINK_PKGSRCDIR.zaptel-netbsd?= ../../comms/zaptel-netbsd BUILDLINK_DEPMETHOD.zaptel-netbsd?= build -.endif # ZAPTEL_NETBSD_BUILDLINK3_MK .include "../../devel/newt/buildlink3.mk" +.endif # ZAPTEL_NETBSD_BUILDLINK3_MK -BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//} +BUILDLINK_TREE+= -zaptel-netbsd |