pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc Only check for the existence of the first word of ${IM...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/7a3ccb826fd5
branches:  trunk
changeset: 495168:7a3ccb826fd5
user:      jlam <jlam%pkgsrc.org@localhost>
date:      Fri Jun 03 17:02:36 2005 +0000

description:
Only check for the existence of the first word of ${IMAKE} since it may
contain a command plus arguments.  We use the standard idiom to extract
the first word of a list stored in a make variable:

        VAR_CMD=        ${VAR:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}

XXX This can be replaced with a more succinct use of variable modifiers
XXX when we update the bootstrap bmake to match the latest NetBSD make
XXX sources, i.e.:
XXX
XXX     VAR_CMD=        ${VAR:[1]}

diffstat:

 fonts/Xft2/builtin.mk           |  5 +++--
 fonts/fontconfig/builtin.mk     |  5 +++--
 graphics/MesaLib/builtin.mk     |  5 +++--
 graphics/freetype2/builtin.mk   |  5 +++--
 graphics/glu/builtin.mk         |  5 +++--
 graphics/xpm/builtin.mk         |  5 +++--
 textproc/expat/builtin.mk       |  5 +++--
 x11/Xcomposite/builtin.mk       |  5 +++--
 x11/Xfixes/builtin.mk           |  5 +++--
 x11/Xrandr-mixedcase/builtin.mk |  5 +++--
 x11/Xrender/builtin.mk          |  6 ++++--
 x11/xcursor/builtin.mk          |  5 +++--
 12 files changed, 37 insertions(+), 24 deletions(-)

diffs (234 lines):

diff -r d87ecf0c1c35 -r 7a3ccb826fd5 fonts/Xft2/builtin.mk
--- a/fonts/Xft2/builtin.mk     Fri Jun 03 16:09:11 2005 +0000
+++ b/fonts/Xft2/builtin.mk     Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.9 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.10 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  Xft2
 
@@ -16,7 +16,8 @@
 .  if exists(${H_XFT2})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.Xft2!=                                                      \
        dir=`cd ${BUILDLINK_PKGSRCDIR.Xft2} && ${PWD_CMD}`;             \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 fonts/fontconfig/builtin.mk
--- a/fonts/fontconfig/builtin.mk       Fri Jun 03 16:09:11 2005 +0000
+++ b/fonts/fontconfig/builtin.mk       Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.5 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.6 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  fontconfig
 
@@ -17,7 +17,8 @@
 .  if exists(${H_FONTCONFIG})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.fontconfig!=                                                        \
        dir=`cd ${BUILDLINK_PKGSRCDIR.fontconfig} && ${PWD_CMD}`;       \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 graphics/MesaLib/builtin.mk
--- a/graphics/MesaLib/builtin.mk       Fri Jun 03 16:09:11 2005 +0000
+++ b/graphics/MesaLib/builtin.mk       Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.7 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.8 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  MesaLib
 
@@ -16,7 +16,8 @@
 .  if exists(${H_MESALIB})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.MesaLib!=                                                   \
        dir=`cd ${BUILDLINK_PKGSRCDIR.MesaLib} && ${PWD_CMD}`;          \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 graphics/freetype2/builtin.mk
--- a/graphics/freetype2/builtin.mk     Fri Jun 03 16:09:11 2005 +0000
+++ b/graphics/freetype2/builtin.mk     Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.5 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.6 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  freetype2
 
@@ -16,7 +16,8 @@
 .  if exists(${H_FREETYPE2})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.freetype2!=                                                 \
        dir=`cd ${BUILDLINK_PKGSRCDIR.freetype2} && ${PWD_CMD}`;        \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 graphics/glu/builtin.mk
--- a/graphics/glu/builtin.mk   Fri Jun 03 16:09:11 2005 +0000
+++ b/graphics/glu/builtin.mk   Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.6 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.7 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  glu
 
@@ -16,7 +16,8 @@
 .  if exists(${H_GLU})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.glu!=                                                       \
        dir=`cd ${BUILDLINK_PKGSRCDIR.glu} && ${PWD_CMD}`;              \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 graphics/xpm/builtin.mk
--- a/graphics/xpm/builtin.mk   Fri Jun 03 16:09:11 2005 +0000
+++ b/graphics/xpm/builtin.mk   Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.8 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.9 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  xpm
 
@@ -26,7 +26,8 @@
 .    else
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.      if defined(IMAKE) && exists(${IMAKE:C/ .*//})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.      if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.xpm!=                                                       \
        dir=`cd ${BUILDLINK_PKGSRCDIR.xpm} && ${PWD_CMD}`;              \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 textproc/expat/builtin.mk
--- a/textproc/expat/builtin.mk Fri Jun 03 16:09:11 2005 +0000
+++ b/textproc/expat/builtin.mk Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.5 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.6 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  expat
 
@@ -16,7 +16,8 @@
 .  if exists(${H_EXPAT})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.expat!=                                                     \
        dir=`cd ${BUILDLINK_PKGSRCDIR.expat} && ${PWD_CMD}`;            \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 x11/Xcomposite/builtin.mk
--- a/x11/Xcomposite/builtin.mk Fri Jun 03 16:09:11 2005 +0000
+++ b/x11/Xcomposite/builtin.mk Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.7 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.8 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  Xcomposite
 
@@ -17,7 +17,8 @@
 .  if exists(${H_XCOMPOSITE})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.Xcomposite!=                                                        \
        dir=`cd ${BUILDLINK_PKGSRCDIR.Xcomposite} && ${PWD_CMD}`;       \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 x11/Xfixes/builtin.mk
--- a/x11/Xfixes/builtin.mk     Fri Jun 03 16:09:11 2005 +0000
+++ b/x11/Xfixes/builtin.mk     Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.6 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.7 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  Xfixes
 
@@ -16,7 +16,8 @@
 .  if exists(${H_XFIXES})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.Xfixes!=                                                    \
        dir=`cd ${BUILDLINK_PKGSRCDIR.Xfixes} && ${PWD_CMD}`;           \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 x11/Xrandr-mixedcase/builtin.mk
--- a/x11/Xrandr-mixedcase/builtin.mk   Fri Jun 03 16:09:11 2005 +0000
+++ b/x11/Xrandr-mixedcase/builtin.mk   Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.10 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.11 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  Xrandr
 
@@ -16,7 +16,8 @@
 .  if exists(${H_XRANDR})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.Xrandr!=                                                    \
        dir=`cd ${BUILDLINK_PKGSRCDIR.Xrandr} && ${PWD_CMD}`;           \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 x11/Xrender/builtin.mk
--- a/x11/Xrender/builtin.mk    Fri Jun 03 16:09:11 2005 +0000
+++ b/x11/Xrender/builtin.mk    Fri Jun 03 17:02:36 2005 +0000
@@ -1,9 +1,10 @@
-# $NetBSD: builtin.mk,v 1.9 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.10 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  Xrender
 
 BUILTIN_FIND_FILES_VAR:=       H_XRENDER
 BUILTIN_FIND_FILES.H_XRENDER=  ${X11BASE}/include/X11/extensions/Xrender.h
+
 .include "../../mk/buildlink3/bsd.builtin.mk"
 
 ###
@@ -15,7 +16,8 @@
 .  if exists(${H_XRENDER})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.Xrender!=                                                   \
        dir=`cd ${BUILDLINK_PKGSRCDIR.Xrender} && ${PWD_CMD}`;          \
        cd ${TMPDIR:U/tmp:Q} &&                                         \
diff -r d87ecf0c1c35 -r 7a3ccb826fd5 x11/xcursor/builtin.mk
--- a/x11/xcursor/builtin.mk    Fri Jun 03 16:09:11 2005 +0000
+++ b/x11/xcursor/builtin.mk    Fri Jun 03 17:02:36 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.7 2005/06/03 16:03:09 jlam Exp $
+# $NetBSD: builtin.mk,v 1.8 2005/06/03 17:02:36 jlam Exp $
 
 BUILTIN_PKG:=  xcursor
 
@@ -16,7 +16,8 @@
 .  if exists(${H_XCURSOR})
 PKGSRC_USE_TOOLS+=     imake                   # XXX
 IMAKE?=                        ${X11BASE}/bin/imake    # XXX
-.    if defined(IMAKE) && exists(${IMAKE})
+_BUILTIN_IMAKE_CMD=    ${IMAKE:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
+.    if exists(${_BUILTIN_IMAKE_CMD})
 IS_BUILTIN.xcursor!=                                                   \
        dir=`cd ${BUILDLINK_PKGSRCDIR.xcursor} && ${PWD_CMD}`;          \
        cd ${TMPDIR:U/tmp:Q} &&                                         \



Home | Main Index | Thread Index | Old Index