Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/make Adapt to changed Var_Subst()
details: https://anonhg.NetBSD.org/src/rev/99c687e64cda
branches: trunk
changeset: 343646:99c687e64cda
user: sjg <sjg%NetBSD.org@localhost>
date: Thu Feb 18 20:33:40 2016 +0000
description:
Adapt to changed Var_Subst()
diffstat:
usr.bin/make/Makefile | 5 ++---
usr.bin/make/meta.c | 16 ++++++++--------
2 files changed, 10 insertions(+), 11 deletions(-)
diffs (91 lines):
diff -r e1c6197cdf45 -r 99c687e64cda usr.bin/make/Makefile
--- a/usr.bin/make/Makefile Thu Feb 18 20:25:08 2016 +0000
+++ b/usr.bin/make/Makefile Thu Feb 18 20:33:40 2016 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.58 2015/06/17 17:43:23 christos Exp $
+# $NetBSD: Makefile,v 1.59 2016/02/18 20:33:40 sjg Exp $
# @(#)Makefile 5.2 (Berkeley) 12/28/90
PROG= make
@@ -13,8 +13,7 @@
lstMember.c lstNext.c lstOpen.c lstRemove.c lstReplace.c lstSucc.c
SRCS += lstPrev.c
-# let people experiment for a bit
-USE_META ?= no
+USE_META ?= yes
.if ${USE_META:tl} != "no"
SRCS+= meta.c
CPPFLAGS+= -DUSE_META
diff -r e1c6197cdf45 -r 99c687e64cda usr.bin/make/meta.c
--- a/usr.bin/make/meta.c Thu Feb 18 20:25:08 2016 +0000
+++ b/usr.bin/make/meta.c Thu Feb 18 20:33:40 2016 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: meta.c,v 1.46 2016/02/18 05:40:50 sjg Exp $ */
+/* $NetBSD: meta.c,v 1.47 2016/02/18 20:33:40 sjg Exp $ */
/*
* Implement 'meta' mode.
@@ -322,7 +322,7 @@
}
cp = strchr(cmd, '$');
if ((cp)) {
- mp = Var_Subst(NULL, cmd, gn, FALSE, TRUE, FALSE);
+ mp = Var_Subst(NULL, cmd, gn, VARF_WANTRES);
cmd = mp;
}
cp2 = strstr(cmd, p_make);
@@ -364,7 +364,7 @@
char *cp = NULL;
if (strchr(cmd, '$')) {
- cmd = cp = Var_Subst(NULL, cmd, mfp->gn, FALSE, TRUE, FALSE);
+ cmd = cp = Var_Subst(NULL, cmd, mfp->gn, VARF_WANTRES);
}
fprintf(mfp->fp, "CMD %s\n", cmd);
free(cp);
@@ -458,7 +458,7 @@
char *mp;
/* Describe the target we are building */
- mp = Var_Subst(NULL, "${" MAKE_META_PREFIX "}", gn, FALSE, TRUE, FALSE);
+ mp = Var_Subst(NULL, "${" MAKE_META_PREFIX "}", gn, VARF_WANTRES);
if (*mp)
fprintf(stdout, "%s\n", mp);
free(mp);
@@ -601,7 +601,7 @@
*/
metaBailiwick = Lst_Init(FALSE);
cp = Var_Subst(NULL, "${.MAKE.META.BAILIWICK:O:u:tA}", VAR_GLOBAL,
- FALSE, TRUE, FALSE);
+ VARF_WANTRES);
if (cp) {
str2Lst_Append(metaBailiwick, cp, NULL);
}
@@ -613,7 +613,7 @@
"/dev /etc /proc /tmp /var/run /var/tmp ${TMPDIR}", VAR_GLOBAL);
cp = Var_Subst(NULL,
"${" MAKE_META_IGNORE_PATHS ":O:u:tA}", VAR_GLOBAL,
- FALSE, TRUE, FALSE);
+ VARF_WANTRES);
if (cp) {
str2Lst_Append(metaIgnorePaths, cp, NULL);
}
@@ -725,7 +725,7 @@
char *cp2;
meta_prefix = Var_Subst(NULL, "${" MAKE_META_PREFIX "}",
- VAR_GLOBAL, FALSE, TRUE, FALSE);
+ VAR_GLOBAL, VARF_WANTRES);
if ((cp2 = strchr(meta_prefix, '$')))
meta_prefix_len = cp2 - meta_prefix;
else
@@ -1309,7 +1309,7 @@
if (DEBUG(META))
fprintf(debug_file, "%s: %d: cannot compare command using .OODATE\n", fname, lineno);
}
- cmd = Var_Subst(NULL, cmd, gn, TRUE, TRUE, FALSE);
+ cmd = Var_Subst(NULL, cmd, gn, VARF_WANTRES|VARF_UNDEFERR);
if ((cp = strchr(cmd, '\n'))) {
int n;
Home |
Main Index |
Thread Index |
Old Index