diff options
author | jlam <jlam@pkgsrc.org> | 2006-03-30 18:06:17 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2006-03-30 18:06:17 +0000 |
commit | d71a98aa8eb185cc8c26f46f2502a25cb3135389 (patch) | |
tree | a4e8c404ab7153a9727f5d7f913a25bdd6b97971 /x11 | |
parent | 3987a638118f7f4cad35ee461afa830350d86564 (diff) | |
download | pkgsrc-d71a98aa8eb185cc8c26f46f2502a25cb3135389.tar.gz |
Avoid extra stat() calls by not repeatedly checking whether a file
exists on the disk -- we can just check whether a variable defined by
find-files.mk is "__nonexistent__" or not.
Diffstat (limited to 'x11')
-rw-r--r-- | x11/XFree86-libs/builtin.mk | 6 | ||||
-rw-r--r-- | x11/Xcomposite/builtin.mk | 4 | ||||
-rw-r--r-- | x11/Xfixes/builtin.mk | 4 | ||||
-rw-r--r-- | x11/Xrandr-mixedcase/builtin.mk | 6 | ||||
-rw-r--r-- | x11/Xrender/builtin.mk | 6 | ||||
-rw-r--r-- | x11/compositeext/builtin.mk | 5 | ||||
-rw-r--r-- | x11/fixesext/builtin.mk | 5 | ||||
-rw-r--r-- | x11/randrext/builtin.mk | 6 | ||||
-rw-r--r-- | x11/renderext/builtin.mk | 6 | ||||
-rw-r--r-- | x11/xcursor/builtin.mk | 6 | ||||
-rw-r--r-- | x11/xextensions/builtin.mk | 4 | ||||
-rw-r--r-- | x11/xorg-libs/builtin.mk | 6 |
12 files changed, 33 insertions, 31 deletions
diff --git a/x11/XFree86-libs/builtin.mk b/x11/XFree86-libs/builtin.mk index a0f3a3f5c92..5e0007c2f4e 100644 --- a/x11/XFree86-libs/builtin.mk +++ b/x11/XFree86-libs/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.2 2005/06/24 05:21:31 jlam Exp $ +# $NetBSD: builtin.mk,v 1.3 2006/03/30 18:06:18 jlam Exp $ BUILTIN_PKG:= XFree86-libs @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.CF_XFREE86= ${X11BASE}/lib/X11/config/xfree86.cf ### .if !defined(IS_BUILTIN.XFree86-libs) IS_BUILTIN.XFree86-libs= no -. if empty(CF_XFREE86:M${LOCALBASE}/*) && exists(${CF_XFREE86}) +. if empty(CF_XFREE86:M__nonexistent__) && empty(CF_XFREE86:M${LOCALBASE}/*) IS_BUILTIN.XFree86-libs= yes . endif .endif @@ -25,7 +25,7 @@ MAKEVARS+= IS_BUILTIN.XFree86-libs ### .if !defined(BUILTIN_PKG.XFree86-libs) && \ !empty(IS_BUILTIN.XFree86-libs:M[yY][eE][sS]) && \ - exists(${CF_XFREE86}) + empty(CF_XFREE86:M__nonexistent__) . include "${BUILDLINK_PKGSRCDIR.XFree86-libs}/version.mk" BUILTIN_PKG.XFree86-libs= XFree86-libs-${BUILTIN_X11_VERSION.XFree86} .endif diff --git a/x11/Xcomposite/builtin.mk b/x11/Xcomposite/builtin.mk index 53c51ee2e04..52d643625b3 100644 --- a/x11/Xcomposite/builtin.mk +++ b/x11/Xcomposite/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.9 2005/06/03 19:12:49 jlam Exp $ +# $NetBSD: builtin.mk,v 1.10 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= Xcomposite @@ -14,7 +14,7 @@ BUILTIN_FIND_FILES.H_XCOMPOSITE= \ ### .if !defined(IS_BUILTIN.Xcomposite) IS_BUILTIN.Xcomposite= no -. if exists(${H_XCOMPOSITE}) +. if empty(H_XCOMPOSITE:M__nonexistent__) BUILTIN_IMAKE_CHECK:= Xcomposite:BuildCompositeLibrary . include "../../mk/buildlink3/imake-check.mk" IS_BUILTIN.Xcomposite= ${BUILTIN_IMAKE_CHECK.Xcomposite} diff --git a/x11/Xfixes/builtin.mk b/x11/Xfixes/builtin.mk index 59d68dac2ac..f5696f18a59 100644 --- a/x11/Xfixes/builtin.mk +++ b/x11/Xfixes/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.8 2005/06/03 19:12:49 jlam Exp $ +# $NetBSD: builtin.mk,v 1.9 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= Xfixes @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.H_XFIXES= ${X11BASE}/include/X11/extensions/Xfixes.h ### .if !defined(IS_BUILTIN.Xfixes) IS_BUILTIN.Xfixes= no -. if exists(${H_XFIXES}) +. if empty(H_XFIXES:M__nonexistent__) BUILTIN_IMAKE_CHECK:= Xfixes:BuildXfixesLibrary . include "../../mk/buildlink3/imake-check.mk" IS_BUILTIN.Xfixes= ${BUILTIN_IMAKE_CHECK.Xfixes} diff --git a/x11/Xrandr-mixedcase/builtin.mk b/x11/Xrandr-mixedcase/builtin.mk index 832179c1213..c62345d1bc2 100644 --- a/x11/Xrandr-mixedcase/builtin.mk +++ b/x11/Xrandr-mixedcase/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.13 2005/07/09 03:14:36 grant Exp $ +# $NetBSD: builtin.mk,v 1.14 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= Xrandr @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.H_XRANDR= ${X11BASE}/include/X11/extensions/Xrandr.h ### .if !defined(IS_BUILTIN.Xrandr) IS_BUILTIN.Xrandr= no -. if exists(${H_XRANDR}) +. if empty(H_XRANDR:M__nonexistent__) BUILTIN_IMAKE_CHECK:= Xrandr:BuildRandRLibrary . include "../../mk/buildlink3/imake-check.mk" IS_BUILTIN.Xrandr= ${BUILTIN_IMAKE_CHECK.Xrandr} @@ -27,7 +27,7 @@ MAKEVARS+= IS_BUILTIN.Xrandr ### .if !defined(BUILTIN_PKG.Xrandr) && \ !empty(IS_BUILTIN.Xrandr:M[yY][eE][sS]) && \ - exists(${H_XRANDR}) + empty(H_XRANDR:M__nonexistent__) # # Xrandr doesn't provide a method of discovering the version number of # the software. Match up Xrandr versions with X11 versions for an diff --git a/x11/Xrender/builtin.mk b/x11/Xrender/builtin.mk index 4f28f9daf1c..cccc7ec9213 100644 --- a/x11/Xrender/builtin.mk +++ b/x11/Xrender/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.15 2005/10/09 21:30:55 jmmv Exp $ +# $NetBSD: builtin.mk,v 1.16 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= Xrender @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.H_XRENDER= ${X11BASE}/include/X11/extensions/Xrender.h ### .if !defined(IS_BUILTIN.Xrender) IS_BUILTIN.Xrender= no -. if exists(${H_XRENDER}) +. if empty(H_XRENDER:M__nonexistent__) BUILTIN_IMAKE_CHECK:= Xrender:BuildRenderLibrary . include "../../mk/buildlink3/imake-check.mk" IS_BUILTIN.Xrender= ${BUILTIN_IMAKE_CHECK.Xrender} @@ -27,7 +27,7 @@ MAKEVARS+= IS_BUILTIN.Xrender ### .if !defined(BUILTIN_PKG.Xrender) && \ !empty(IS_BUILTIN.Xrender:M[yY][eE][sS]) && \ - exists(${H_XRENDER}) + empty(H_XRENDER:M__nonexistent__) # # Xrender doesn't provide a method of discovering the version number of # the software. Match up Xrender versions with X11 versions for an diff --git a/x11/compositeext/builtin.mk b/x11/compositeext/builtin.mk index af622262ed8..2d536a2d9ce 100644 --- a/x11/compositeext/builtin.mk +++ b/x11/compositeext/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.5 2005/06/01 18:03:27 jlam Exp $ +# $NetBSD: builtin.mk,v 1.6 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= compositeext @@ -21,7 +21,8 @@ IS_BUILTIN.compositeext= no # we'll consider this X11 package to be built-in even if it's a part # of one of the pkgsrc-installed X11 distributions. # -. if exists(${H_COMPOSITE}) && exists(${H_COMPOSITEPROTO}) +. if empty(H_COMPOSITE:M__nonexistent__) && \ + empty(H_COMPOSITEPROTO:M__nonexistent__) IS_BUILTIN.compositeext= yes . endif .endif diff --git a/x11/fixesext/builtin.mk b/x11/fixesext/builtin.mk index 5c2be9fd331..56586af3ee9 100644 --- a/x11/fixesext/builtin.mk +++ b/x11/fixesext/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.4 2005/06/01 18:03:28 jlam Exp $ +# $NetBSD: builtin.mk,v 1.5 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= fixesext @@ -21,7 +21,8 @@ IS_BUILTIN.fixesext= no # we'll consider this X11 package to be built-in even if it's a part # of one of the pkgsrc-installed X11 distributions. # -. if exists(${H_XFIXESPROTO}) && exists(${H_XFIXESWIRE}) +. if empty(H_XFIXESPROTO:M__nonexistent__) && \ + empty(H_XFIXESWIRE:M__nonexistent__) IS_BUILTIN.fixesext= yes . endif .endif diff --git a/x11/randrext/builtin.mk b/x11/randrext/builtin.mk index f4604f81fa8..c5a26239366 100644 --- a/x11/randrext/builtin.mk +++ b/x11/randrext/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.3 2005/06/01 18:03:30 jlam Exp $ +# $NetBSD: builtin.mk,v 1.4 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= randrext @@ -18,7 +18,7 @@ IS_BUILTIN.randrext= no # we'll consider this X11 package to be built-in even if it's a part # of one of the pkgsrc-installed X11 distributions. # -. if exists(${H_RANDR}) +. if empty(H_RANDR:M__nonexistent__) IS_BUILTIN.randrext= yes . endif .endif @@ -30,7 +30,7 @@ MAKEVARS+= IS_BUILTIN.randrext ### .if !defined(BUILTIN_PKG.randrext) && \ !empty(IS_BUILTIN.randrext:M[yY][eE][sS]) && \ - exists(${H_RANDR}) + empty(H_RANDR:M__nonexistent__) BUILTIN_VERSION.randrext!= \ ${AWK} '/\#define[ ]*RANDR_MAJOR/ { M = $$3 } \ /\#define[ ]*RANDR_MINOR/ { m = "."$$3 } \ diff --git a/x11/renderext/builtin.mk b/x11/renderext/builtin.mk index a1fb34091da..f85455cf1fb 100644 --- a/x11/renderext/builtin.mk +++ b/x11/renderext/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.1.1.1 2005/10/15 16:36:57 wiz Exp $ +# $NetBSD: builtin.mk,v 1.2 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= renderext @@ -18,7 +18,7 @@ IS_BUILTIN.renderext= no # we'll consider this X11 package to be built-in even if it's a part # of one of the pkgsrc-installed X11 distributions. # -. if exists(${H_RENDER}) +. if empty(H_RENDER:M__nonexistent__) IS_BUILTIN.renderext= yes . endif .endif @@ -30,7 +30,7 @@ MAKEVARS+= IS_BUILTIN.renderext ### .if !defined(BUILTIN_PKG.renderext) && \ !empty(IS_BUILTIN.renderext:M[yY][eE][sS]) && \ - exists(${H_RENDER}) + empty(H_RENDER:M__nonexistent__) BUILTIN_VERSION.renderext!= \ ${AWK} '/\#define[ ]*RENDER_MAJOR/ { M = $$3 } \ /\#define[ ]*RENDER_MINOR/ { m = "."$$3 } \ diff --git a/x11/xcursor/builtin.mk b/x11/xcursor/builtin.mk index d10ae5b057b..d29ac9b8630 100644 --- a/x11/xcursor/builtin.mk +++ b/x11/xcursor/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.10 2005/12/04 01:46:45 rxg Exp $ +# $NetBSD: builtin.mk,v 1.11 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= xcursor @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.H_XCURSOR= ${X11BASE}/include/X11/Xcursor/Xcursor.h ### .if !defined(IS_BUILTIN.xcursor) IS_BUILTIN.xcursor= no -. if exists(${H_XCURSOR}) +. if empty(H_XCURSOR:M__nonexistent__) BUILTIN_IMAKE_CHECK:= xcursor:BuildXcursorLibrary . include "../../mk/buildlink3/imake-check.mk" IS_BUILTIN.xcursor= ${BUILTIN_IMAKE_CHECK.xcursor} @@ -27,7 +27,7 @@ MAKEVARS+= IS_BUILTIN.xcursor ### .if !defined(BUILTIN_PKG.xcursor) && \ !empty(IS_BUILTIN.xcursor:M[yY][eE][sS]) && \ - exists(${H_XCURSOR}) + empty(H_XCURSOR:M__nonexistent__) BUILTIN_VERSION.xcursor!= \ ${AWK} '/\#define[ ]*XCURSOR_(LIB_)?MAJOR/ { M = $$3 } \ /\#define[ ]*XCURSOR_(LIB_)?MINOR/ { m = "."$$3 } \ diff --git a/x11/xextensions/builtin.mk b/x11/xextensions/builtin.mk index a98317d134a..7e207fca3b1 100644 --- a/x11/xextensions/builtin.mk +++ b/x11/xextensions/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.8 2005/10/09 21:43:02 jmmv Exp $ +# $NetBSD: builtin.mk,v 1.9 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= xextensions @@ -19,7 +19,7 @@ IS_BUILTIN.xextensions= no # we'll consider this X11 package to be built-in even if it's a part # of one of the pkgsrc-installed X11 distributions. # -. if exists(${H_XEXTENSIONS}) +. if empty(H_XEXTENSIONS:M__nonexistent__) IS_BUILTIN.xextensions= yes . endif .endif diff --git a/x11/xorg-libs/builtin.mk b/x11/xorg-libs/builtin.mk index 63191f389c0..7e85d9df883 100644 --- a/x11/xorg-libs/builtin.mk +++ b/x11/xorg-libs/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.3 2005/10/16 19:53:36 tonio Exp $ +# $NetBSD: builtin.mk,v 1.4 2006/03/30 18:06:19 jlam Exp $ BUILTIN_PKG:= xorg-libs @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.CF_XORG= ${X11BASE}/lib/X11/config/xorg.cf ### .if !defined(IS_BUILTIN.xorg-libs) IS_BUILTIN.xorg-libs= no -. if empty(CF_XORG:M${LOCALBASE}/*) && exists(${CF_XORG}) +. if empty(CF_XORG:M__nonexistent__) && empty(CF_XORG:M${LOCALBASE}/*) IS_BUILTIN.xorg-libs= yes . endif .endif @@ -25,7 +25,7 @@ MAKEVARS+= IS_BUILTIN.xorg-libs ### .if !defined(BUILTIN_PKG.xorg-libs) && \ !empty(IS_BUILTIN.xorg-libs:M[yY][eE][sS]) && \ - exists(${CF_XORG}) + empty(CF_XORG:M__nonexistent__) . include "${BUILDLINK_PKGSRCDIR.xorg-libs}/version.mk" BUILTIN_PKG.xorg-libs= xorg-libs-${BUILTIN_X11_VERSION.xorg} .endif |