summaryrefslogtreecommitdiff
path: root/usr.bin/make/make.1
diff options
context:
space:
mode:
authorsjg <sjg@NetBSD.org>2006-02-26 21:43:00 +0000
committersjg <sjg@NetBSD.org>2006-02-26 21:43:00 +0000
commit2bc18a45e643a49fdcdaf21e683923a371bc0c44 (patch)
tree3ad001c3a0cf4b0436b6e08c6e0d22347261a227 /usr.bin/make/make.1
parent016de84c5ba7857dd70c285a9dcec8927bdb75ab (diff)
Update man page and add test case for specifying modifiers via variable.
Also allow said variable to appear anywhere in the modifier list.
Diffstat (limited to 'usr.bin/make/make.1')
-rw-r--r--usr.bin/make/make.119
1 files changed, 16 insertions, 3 deletions
diff --git a/usr.bin/make/make.1 b/usr.bin/make/make.1
index 17fde362554..b3ca1bb0202 100644
--- a/usr.bin/make/make.1
+++ b/usr.bin/make/make.1
@@ -1,4 +1,4 @@
-.\" $NetBSD: make.1,v 1.119 2006/01/22 19:54:55 dsl Exp $
+.\" $NetBSD: make.1,v 1.120 2006/02/26 21:43:00 sjg Exp $
.\"
.\" Copyright (c) 1990, 1993
.\" The Regents of the University of California. All rights reserved.
@@ -29,7 +29,7 @@
.\"
.\" from: @(#)make.1 8.4 (Berkeley) 3/19/94
.\"
-.Dd January 22, 2006
+.Dd Feburary 26, 2006
.Dt MAKE 1
.Os
.Sh NAME
@@ -694,11 +694,24 @@ Variable expansion may be modified to select or modify each word of the
variable (where a ``word'' is white-space delimited sequence of characters).
The general format of a variable expansion is as follows:
.Pp
-.Dl {variable[:modifier[:...]]}
+.Dl ${variable[:modifier[:...]]}
.Pp
Each modifier begins with a colon,
which may be escaped with a backslash
.Pq Ql \e .
+.Pp
+A set of modifiers can be specified via a variable, as follows:
+.Pp
+.Dl modifier_variable=modifier[:...]
+.Dl ${variable:${modifier_variable}[:...]}
+.Pp
+In this case the first modifier in the modifier_variable does not
+start with a colon, since that must appear in the referencing
+variable.
+If any of the modifiers in the modifier_variable contain a dollar sign
+.Pq Ql $ ,
+these must be doubled to avoid early expansion.
+.Pp
The supported modifiers are:
.Bl -tag -width EEE
.It Cm \&:E