aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/make
diff options
context:
space:
mode:
authorHartmut Brandt <harti@FreeBSD.org>2004-07-19 14:42:57 +0000
committerHartmut Brandt <harti@FreeBSD.org>2004-07-19 14:42:57 +0000
commite9345b8636dd8b9b2c579f38476538199f85d52c (patch)
treec4f7ba9da712cd9c0733c4aa2c47610ebb4661f4 /usr.bin/make
parentbe1e385e24d1b4fee27a18e6f422fb3878d21099 (diff)
Notes
Diffstat (limited to 'usr.bin/make')
-rw-r--r--usr.bin/make/make.117
1 files changed, 12 insertions, 5 deletions
diff --git a/usr.bin/make/make.1 b/usr.bin/make/make.1
index f08fb76102a4..a55c5bca1471 100644
--- a/usr.bin/make/make.1
+++ b/usr.bin/make/make.1
@@ -1270,19 +1270,26 @@ in a test is very simple-minded.
Currently, the only form that works is
.Ql .if ${VAR} op something
For instance, you should write tests as
-.Ql .if ${VAR} = "string"
-not the other way around, which doesn't work.
+.Ql .if ${VAR} == "string"
+not the other way around, which would give you an error.
.Pp
For loops are expanded before tests, so a fragment such as:
.Bd -literal -offset indent
-\&.for TMACHINE in ${SHARED_ARCHS}
-\&.if ${TMACHINE} = ${MACHINE}
+\&.for ARCH in ${SHARED_ARCHS}
+\&.if ${ARCH} == ${MACHINE}
...
\&.endif
\&.endfor
.Ed
.Pp
-won't work, and should be rewritten the other way around.
+won't work, and should be rewritten as:
+.Bd -literal -offset indent
+\&.for ARCH in ${SHARED_ARCHS}
+\&.if ${MACHINE} == ${ARCH}
+ ...
+\&.endif
+\&.endfor
+.Ed
.Pp
The parsing code is broken with respect to handling a semicolon
after a colon, so a fragment like this will fail: