1comment testing start
2this is foo
3This is how a comment looks: # comment
4comment testing done
5make: "cond1" line 75: warning: extra else
6make: "cond1" line 85: warning: extra else
72 is  prime
8A='other' B='unknown' C='clever' o='no,no'
9Passed:
10 var
11 ("var")
12 (var != var)
13 var != var
14 !((var != var) && defined(name))
15 var == quoted
16
171 is not prime
182 is  prime
193 is  prime
204 is not prime
215 is  prime
22
23make: warning: String comparison operator should be either == or !=
24make: Bad conditional expression `"0" > 0' in "0" > 0?OK:No
25
26OK
27make: "error" line 3: just FYI
28make: "error" line 4: warning: this could be serious
29make: "error" line 5: this is fatal
30UT_DOLLAR=This is $UT_FU
31UT_FOO=foobar is fubar
32UT_FU=fubar
33UT_TEST=export
34UT_ZOO=hoopie
35UT_ALL=even this gets exported
36UT_BADDIR=unit-tests
37UT_DOLLAR=This is $UT_FU
38UT_F=fine
39UT_FOO=foobar is fubar
40UT_FU=fubar
41UT_NO=all
42UT_OK=good
43UT_OKDIR=unit-tests
44UT_TEST=export-all
45UT_ZOO=hoopie
46make:
47UT_TEST=export-env
48UT_ENV=not-exported
49UT_EXP=not-exported
50env:
51UT_TEST=export-env
52UT_ENV=exported
53UT_EXP=exported
54At first, I am
55happy
56and now: sad
57.ERROR: Looks like 'sad' is upset.
58*** Error code 1
59
60Stop.
61make: stopped in unit-tests
62simple.1
63simple.1
64simple.2
65simple.2
66recursive.1.1.*
67recursive.1.1.*
68recursive.1.1.*
69recursive.1.1.*
70recursive.1.99
71recursive.1.99
72recursive.2.1.*
73recursive.2.1.*
74recursive.2.1.*
75recursive.2.1.*
76recursive.2.99
77recursive.2.99
78shared.0
79shared.0
80shared.1.99
81shared.1.99
82shared.2.1
83shared.2.1
84shared.2.99
85shared.2.99
86make: Graph cycles through `cycle.2.99'
87make: Graph cycles through `cycle.2.98'
88make: Graph cycles through `cycle.2.97'
89cycle.1.99
90cycle.1.99
91x=one
92x="two and three"
93x=four
94x="five"
95x=-I/this
96x=-I"This or that"
97x=-Ithat
98x="-DTHIS=\"this and that\""
99cfl=-I/this -I"This or that" -Ithat "-DTHIS=\"this and that\""
100a=one b="two and three"
101a=four b="five"
102a=ONE b="TWO AND THREE"
103a=FOUR b="FIVE"
104We expect an error next:
105make: "forloop" line 38: Wrong number of words (9) in .for substitution list with 2 vars
106make: Fatal errors encountered -- cannot continue
107make: stopped in unit-tests
108OK
109.for with :S;... OK
110b2af338b
1113360ac65
1127747f046
1139ca87054
114880fe816
115208fcbd3
116d5d376eb
117de41416c
118Expect: Unknown modifier 'Z'
119make: Unknown modifier 'Z'
120VAR:Z=
121Expect: Unknown modifier 'Z'
122make: Unknown modifier 'Z'
123VAR:Z=
124Expect: Unclosed variable specification for VAR
125make: Unclosed variable specification (expecting '}') for "VAR" (value "Thevariable") modifier S
126VAR:S,V,v,=Thevariable
127Expect: Unclosed variable specification for VAR
128make: Unclosed variable specification after complex modifier (expecting '}') for VAR
129VAR:S,V,v,=Thevariable
130Expect: Unclosed substitution for VAR (, missing)
131make: Unclosed substitution for VAR (, missing)
132VAR:S,V,v=
133LIB=a X_LIBS:M${LIB${LIB:tu}} is "/tmp/liba.a"
134LIB=a X_LIBS:M*/lib${LIB}.a is "/tmp/liba.a"
135LIB=a X_LIBS:M*/lib${LIB}.a:tu is "/TMP/LIBA.A"
136LIB=b X_LIBS:M${LIB${LIB:tu}} is ""
137LIB=b X_LIBS:M*/lib${LIB}.a is ""
138LIB=b X_LIBS:M*/lib${LIB}.a:tu is ""
139LIB=c X_LIBS:M${LIB${LIB:tu}} is ""
140LIB=c X_LIBS:M*/lib${LIB}.a is ""
141LIB=c X_LIBS:M*/lib${LIB}.a:tu is ""
142LIB=d X_LIBS:M${LIB${LIB:tu}} is "/tmp/libd.a"
143LIB=d X_LIBS:M*/lib${LIB}.a is "/tmp/libd.a"
144LIB=d X_LIBS:M*/lib${LIB}.a:tu is "/TMP/LIBD.A"
145LIB=e X_LIBS:M${LIB${LIB:tu}} is "/tmp/libe.a"
146LIB=e X_LIBS:M*/lib${LIB}.a is "/tmp/libe.a"
147LIB=e X_LIBS:M*/lib${LIB}.a:tu is "/TMP/LIBE.A"
148Mscanner=OK
149path=':/bin:/tmp::/:.:/no/such/dir:.'
150path='/bin:/tmp:/:/no/such/dir'
151path='/bin:/tmp:/:/no/such/dir'
152path='/bin':'/tmp':'/':'/no/such/dir'
153path='/bin':'/tmp':'/':'/no/such/dir'
154path_/usr/xbin=/opt/xbin/
155paths=/bin /tmp / /no/such/dir /opt/xbin
156PATHS=/BIN /TMP / /NO/SUCH/DIR /OPT/XBIN
157The answer is 42
158LIST      = one two three four five six seven eight nine ten
159LIST:O    = eight five four nine one seven six ten three two
160LIST:Ox   = Ok
161LIST:O:Ox = Ok
162LISTX     = Ok
163LISTSX    = Ok
164make: Bad modifier `:OX' for LIST
165BADMOD 1  = }
166make: Bad modifier `:OxXX' for LIST
167BADMOD 2  = XX}
168LIST="one two three four five six"
169LIST:ts,="one,two,three,four,five,six"
170LIST:ts/:tu="ONE/TWO/THREE/FOUR/FIVE/SIX"
171LIST:ts::tu="ONE:TWO:THREE:FOUR:FIVE:SIX"
172LIST:ts:tu="ONETWOTHREEFOURFIVESIX"
173LIST:tu:ts/="ONE/TWO/THREE/FOUR/FIVE/SIX"
174LIST:ts:="one:two:three:four:five:six"
175LIST:ts="onetwothreefourfivesix"
176LIST:ts:S/two/2/="one2threefourfivesix"
177LIST:S/two/2/:ts="one2threefourfivesix"
178LIST:ts/:S/two/2/="one/2/three/four/five/six"
179Pretend the '/' in '/n' etc. below are back-slashes.
180LIST:ts/n="one
181two
182three
183four
184five
185six"
186LIST:ts/t="one	two	three	four	five	six"
187LIST:ts/012:tu="ONE
188TWO
189THREE
190FOUR
191FIVE
192SIX"
193make: Bad modifier `:tx' for LIST
194LIST:tx="}"
195make: Bad modifier `:ts\x' for LIST
196LIST:ts/x:tu="\x:tu}"
197FU_mod-ts="a/b/cool"
198FU_mod-ts:ts:T="cool" == cool?
199B.${AAA:ts}="Baaa" == Baaa?
200make: Bad modifier `:[]' for LIST
201LIST:[]="" is an error
202LIST:[0]="one two three four five six"
203LIST:[0x0]="one two three four five six"
204LIST:[000]="one two three four five six"
205LIST:[*]="one two three four five six"
206LIST:[@]="one two three four five six"
207LIST:[0]:C/ /,/="one,two three four five six"
208LIST:[0]:C/ /,/g="one,two,three,four,five,six"
209LIST:[0]:C/ /,/1g="one,two,three,four,five,six"
210LIST:[*]:C/ /,/="one,two three four five six"
211LIST:[*]:C/ /,/g="one,two,three,four,five,six"
212LIST:[*]:C/ /,/1g="one,two,three,four,five,six"
213LIST:[@]:C/ /,/="one two three four five six"
214LIST:[@]:C/ /,/g="one two three four five six"
215LIST:[@]:C/ /,/1g="one two three four five six"
216LIST:[@]:[0]:C/ /,/="one,two three four five six"
217LIST:[0]:[@]:C/ /,/="one two three four five six"
218LIST:[@]:[*]:C/ /,/="one,two three four five six"
219LIST:[*]:[@]:C/ /,/="one two three four five six"
220EMPTY=""
221EMPTY:[#]="1" == 1 ?
222ESCAPEDSPACE="\ "
223ESCAPEDSPACE:[#]="1" == 1 ?
224REALLYSPACE=" "
225REALLYSPACE:[#]="1" == 1 ?
226LIST:[#]="6"
227LIST:[0]:[#]="1" == 1 ?
228LIST:[*]:[#]="1" == 1 ?
229LIST:[@]:[#]="6"
230LIST:[1]:[#]="1"
231LIST:[1..3]:[#]="3"
232EMPTY:[1]=""
233ESCAPEDSPACE="\ "
234ESCAPEDSPACE:[1]="\ "
235REALLYSPACE=" "
236REALLYSPACE:[1]="" == "" ?
237REALLYSPACE:[*]:[1]=" " == " " ?
238LIST:[1]="one"
239make: Bad modifier `:[1.]' for LIST
240LIST:[1.]="" is an error
241make: Bad modifier `:[1].' for LIST
242LIST:[1].="}" is an error
243LIST:[2]="two"
244LIST:[6]="six"
245LIST:[7]=""
246LIST:[999]=""
247make: Bad modifier `:[-]' for LIST
248LIST:[-]="" is an error
249make: Bad modifier `:[--]' for LIST
250LIST:[--]="" is an error
251LIST:[-1]="six"
252LIST:[-2]="five"
253LIST:[-6]="one"
254LIST:[-7]=""
255LIST:[-999]=""
256LONGLIST:[17]="17"
257LONGLIST:[0x11]="17"
258LONGLIST:[021]="17"
259LIST:[0]:[1]="one two three four five six"
260LIST:[*]:[1]="one two three four five six"
261LIST:[@]:[1]="one"
262LIST:[0]:[2]=""
263LIST:[*]:[2]=""
264LIST:[@]:[2]="two"
265LIST:[*]:C/ /,/:[2]=""
266LIST:[*]:C/ /,/:[*]:[2]=""
267LIST:[*]:C/ /,/:[@]:[2]="three"
268make: Bad modifier `:[1.]' for LIST
269LIST:[1.]="" is an error
270make: Bad modifier `:[1..]' for LIST
271LIST:[1..]="" is an error
272LIST:[1..1]="one"
273make: Bad modifier `:[1..1.]' for LIST
274LIST:[1..1.]="" is an error
275LIST:[1..2]="one two"
276LIST:[2..1]="two one"
277LIST:[3..-2]="three four five"
278LIST:[-4..4]="three four"
279make: Bad modifier `:[0..1]' for LIST
280LIST:[0..1]="" is an error
281make: Bad modifier `:[-1..0]' for LIST
282LIST:[-1..0]="" is an error
283LIST:[-1..1]="six five four three two one"
284LIST:[0..0]="one two three four five six"
285LIST:[3..99]="three four five six"
286LIST:[-3..-99]="four three two one"
287LIST:[-99..-3]="one two three four"
288HASH="#" == "#" ?
289LIST:[${HASH}]="6"
290LIST:[${ZERO}]="one two three four five six"
291LIST:[${ZERO}x${ONE}]="one"
292LIST:[${ONE}]="one"
293LIST:[${MINUSONE}]="six"
294LIST:[${STAR}]="one two three four five six"
295LIST:[${AT}]="one two three four five six"
296make: Bad modifier `:[${EMPTY' for LIST
297LIST:[${EMPTY}]="" is an error
298LIST:[${LONGLIST:[21]:S/2//}]="one"
299LIST:[${LIST:[#]}]="six"
300LIST:[${LIST:[${HASH}]}]="six"
301LIST:S/ /,/="one two three four five six"
302LIST:S/ /,/W="one,two three four five six"
303LIST:S/ /,/gW="one,two,three,four,five,six"
304EMPTY:S/^/,/=","
305EMPTY:S/^/,/W=","
306LIST:C/ /,/="one two three four five six"
307LIST:C/ /,/W="one,two three four five six"
308LIST:C/ /,/gW="one,two,three,four,five,six"
309EMPTY:C/^/,/=","
310EMPTY:C/^/,/W=","
311LIST:tW="one two three four five six"
312LIST:tw="one two three four five six"
313LIST:tW:C/ /,/="one,two three four five six"
314LIST:tW:C/ /,/g="one,two,three,four,five,six"
315LIST:tW:C/ /,/1g="one,two,three,four,five,six"
316LIST:tw:C/ /,/="one two three four five six"
317LIST:tw:C/ /,/g="one two three four five six"
318LIST:tw:C/ /,/1g="one two three four five six"
319LIST:tw:tW:C/ /,/="one,two three four five six"
320LIST:tW:tw:C/ /,/="one two three four five six"
321Making the.c
322Making the.h
323Making the.o from the.h the.c
324.TARGET="phony" .PREFIX="phony" .IMPSRC=""
325.TARGET="all" .PREFIX="all" .IMPSRC=""
326.TARGET="ok" .PREFIX="ok" .IMPSRC=""
327.TARGET="also.ok" .PREFIX="also.ok" .IMPSRC=""
328.TARGET="bug" .PREFIX="bug" .IMPSRC=""
329Posix says we should execute the command as if run by system(3)
330Expect 'Hello,' and 'World!'
331Hello,
332World!
333a command
334a command prefixed by '+' executes even with -n
335another command
336make -n
337echo a command
338echo "a command prefixed by '+' executes even with -n"
339a command prefixed by '+' executes even with -n
340echo another command
341make -n -j1
342{ echo a command
343} || exit $?
344echo "a command prefixed by '+' executes even with -n"
345a command prefixed by '+' executes even with -n
346{ echo another command
347} || exit $?
348Now we expect an error...
349*** Error code 1 (continuing)
350`all' not remade because of errors.
351V.i386 ?= OK
352TEST1=hello
353TEST2=bye
354TEST3=later
355FOOBAR =
356FOOBAR = foobar fubar
357fun
358fun
359fun
360In the Sun
361The answer is unknown
362The answer is unknown
363The answer is empty
364The answer is known
365The answer is
366The answer is empty
367The answer is known
368The answer is 42
369The answer is 42
370UT_DOLLAR=This is $UT_FU
371UT_FU=fubar
372UT_TEST=unexport
373UT_TEST=unexport-env
374default FU=<v>fu</v> FOO=<v>foo</v> VAR=<v></v>
375two FU=<v>bar</v> FOO=<v>goo</v> VAR=<v></v>
376three FU=<v>bar</v> FOO=<v>goo</v> VAR=<v></v>
377four FU=<v>bar</v> FOO=<v>goo</v> VAR=<v>Internal</v>
378five FU=<v>bar</v> FOO=<v>goo</v> VAR=<v>Internal</v>
379five v=is x k=is x
380six v=is y k=is y
381show-v v=override k=override
382*** Error code 1 (ignored)
383*** Error code 1 (ignored)
384