diff options
author | jlam <jlam> | 2006-03-30 18:06:17 +0000 |
---|---|---|
committer | jlam <jlam> | 2006-03-30 18:06:17 +0000 |
commit | 4a5a7cfee21adb0d8f6bc50d3e58d70a59e041a5 (patch) | |
tree | a4e8c404ab7153a9727f5d7f913a25bdd6b97971 /graphics | |
parent | b884195160fd50c9a83ede73dc5ebcb668e9ea8b (diff) | |
download | pkgsrc-4a5a7cfee21adb0d8f6bc50d3e58d70a59e041a5.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 'graphics')
-rw-r--r-- | graphics/MesaLib/builtin.mk | 6 | ||||
-rw-r--r-- | graphics/freetype2/builtin.mk | 6 | ||||
-rw-r--r-- | graphics/glu/builtin.mk | 6 | ||||
-rw-r--r-- | graphics/xpm/builtin.mk | 6 |
4 files changed, 12 insertions, 12 deletions
diff --git a/graphics/MesaLib/builtin.mk b/graphics/MesaLib/builtin.mk index c557282c39f..dac3b0dc577 100644 --- a/graphics/MesaLib/builtin.mk +++ b/graphics/MesaLib/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.12 2006/01/19 12:53:17 adam Exp $ +# $NetBSD: builtin.mk,v 1.13 2006/03/30 18:06:17 jlam Exp $ BUILTIN_PKG:= MesaLib @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.H_MESALIB= ${X11BASE}/include/GL/glx.h ### .if !defined(IS_BUILTIN.MesaLib) IS_BUILTIN.MesaLib= no -. if exists(${H_MESALIB}) +. if empty(H_MESALIB:M__nonexistent__) BUILTIN_IMAKE_CHECK:= MesaLib:BuildGLXLibrary . include "../../mk/buildlink3/imake-check.mk" IS_BUILTIN.MesaLib= ${BUILTIN_IMAKE_CHECK.MesaLib} @@ -27,7 +27,7 @@ MAKEVARS+= IS_BUILTIN.MesaLib ### .if !defined(BUILTIN_PKG.MesaLib) && \ !empty(IS_BUILTIN.MesaLib:M[yY][eE][sS]) && \ - exists(${H_MESALIB}) + empty(H_MESALIB:M__nonexistent__) . include "../../graphics/Mesa/version.mk" BUILTIN_PKG.MesaLib= MesaLib-${BUILTIN_VERSION.Mesa} .endif diff --git a/graphics/freetype2/builtin.mk b/graphics/freetype2/builtin.mk index d6c21b54c28..8afcae8d44c 100644 --- a/graphics/freetype2/builtin.mk +++ b/graphics/freetype2/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.7 2005/06/03 19:12:49 jlam Exp $ +# $NetBSD: builtin.mk,v 1.8 2006/03/30 18:06:17 jlam Exp $ BUILTIN_PKG:= freetype2 @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.H_FREETYPE2= ${X11BASE}/include/freetype2/freetype/freetype.h ### .if !defined(IS_BUILTIN.freetype2) IS_BUILTIN.freetype2= no -. if exists(${H_FREETYPE2}) +. if empty(H_FREETYPE2:M__nonexistent__) BUILTIN_IMAKE_CHECK:= freetype2:BuildFreetype2Library . include "../../mk/buildlink3/imake-check.mk" IS_BUILTIN.freetype2= ${BUILTIN_IMAKE_CHECK.freetype2} @@ -27,7 +27,7 @@ MAKEVARS+= IS_BUILTIN.freetype2 ### .if !defined(BUILTIN_PKG.freetype2) && \ !empty(IS_BUILTIN.freetype2:M[yY][eE][sS]) && \ - exists(${H_FREETYPE2}) + empty(H_FREETYPE2:M__nonexistent__) BUILTIN_VERSION.freetype2!= \ ${AWK} 'BEGIN { p = ".0" } \ /\#define[ ]*FREETYPE_MAJOR/ { M = $$3 } \ diff --git a/graphics/glu/builtin.mk b/graphics/glu/builtin.mk index 3d15449dde3..474b0050a0b 100644 --- a/graphics/glu/builtin.mk +++ b/graphics/glu/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.9 2006/01/19 12:53:17 adam Exp $ +# $NetBSD: builtin.mk,v 1.10 2006/03/30 18:06:17 jlam Exp $ BUILTIN_PKG:= glu @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.H_GLU= ${X11BASE}/include/GL/glu.h ### .if !defined(IS_BUILTIN.glu) IS_BUILTIN.glu= no -. if exists(${H_GLU}) +. if empty(H_GLU:M__nonexistent__) BUILTIN_IMAKE_CHECK:= glu:BuildGLULibrary . include "../../mk/buildlink3/imake-check.mk" IS_BUILTIN.glu= ${BUILTIN_IMAKE_CHECK.glu} @@ -27,7 +27,7 @@ MAKEVARS+= IS_BUILTIN.glu ### .if !defined(BUILTIN_PKG.glu) && \ !empty(IS_BUILTIN.glu:M[yY][eE][sS]) && \ - exists(${H_GLU}) + empty(H_GLU:M__nonexistent__) . include "../../graphics/Mesa/version.mk" BUILTIN_PKG.glu= glu-${BUILTIN_VERSION.Mesa} .endif diff --git a/graphics/xpm/builtin.mk b/graphics/xpm/builtin.mk index 277e9727234..eceebda0e4d 100644 --- a/graphics/xpm/builtin.mk +++ b/graphics/xpm/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.10 2005/06/03 19:12:49 jlam Exp $ +# $NetBSD: builtin.mk,v 1.11 2006/03/30 18:06:18 jlam Exp $ BUILTIN_PKG:= xpm @@ -13,7 +13,7 @@ BUILTIN_FIND_FILES.H_XPM= ${X11BASE}/include/X11/xpm.h ### .if !defined(IS_BUILTIN.xpm) IS_BUILTIN.xpm= no -. if exists(${H_XPM}) +. if empty(H_XPM:M__nonexistent__) . if !empty(X11BASE:M*openwin) && exists(/usr/sbin/pkgchk) IS_BUILTIN.xpm!= \ if /usr/sbin/pkgchk -l SUNWxwinc | ${GREP} -q xpm.h; then \ @@ -38,7 +38,7 @@ MAKEVARS+= IS_BUILTIN.xpm ### .if !defined(BUILTIN_PKG.xpm) && \ !empty(IS_BUILTIN.xpm:M[yY][eE][sS]) && \ - exists(${H_XPM}) + empty(H_XPM:M__nonexistent__) BUILTIN_VERSION.xpm!= \ ${AWK} 'BEGIN { split("abcdefghijklmnopqrstuvwxyz", alpha, ""); \ p = ".0" } \ |