mirror of
https://git.savannah.gnu.org/git/make.git
synced 2024-12-29 08:09:02 +00:00
81f3e4babd
- Fix Savannah bug #24655. - Fix Savannah bug #24588. - Fix Savannah bug #24277. - Fix Savannah bug #25697. - Fix Savannah bug #25694. - Fix Savannah bug #25460. - Fix Savannah bug #26207. - Fix Savannah bug #25712. - Fix Savannah bug #26593. - Fix various doc issues.
76 lines
1.1 KiB
Perl
76 lines
1.1 KiB
Perl
# -*-perl-*-
|
|
|
|
$description = "Test various flavors of make variable setting.";
|
|
|
|
$details = "";
|
|
|
|
# TEST 0: Recursive
|
|
|
|
run_make_test('
|
|
ugh = Goodbye
|
|
foo = $(bar)
|
|
bar = ${ugh}
|
|
ugh = Hello
|
|
all: ; @echo $(foo)
|
|
',
|
|
'', "Hello\n");
|
|
|
|
# TEST 1: Simple
|
|
|
|
run_make_test('
|
|
bar = Goodbye
|
|
foo := $(bar)
|
|
bar = ${ugh}
|
|
ugh = Hello
|
|
all: ; @echo $(foo)
|
|
',
|
|
'', "Goodbye\n");
|
|
|
|
# TEST 2: Append to recursive
|
|
|
|
run_make_test('
|
|
foo = Hello
|
|
ugh = Goodbye
|
|
foo += $(bar)
|
|
bar = ${ugh}
|
|
ugh = Hello
|
|
all: ; @echo $(foo)
|
|
',
|
|
'', "Hello Hello\n");
|
|
|
|
# TEST 3: Append to simple
|
|
|
|
run_make_test('
|
|
foo := Hello
|
|
ugh = Goodbye
|
|
bar = ${ugh}
|
|
foo += $(bar)
|
|
ugh = Hello
|
|
all: ; @echo $(foo)
|
|
',
|
|
'', "Hello Goodbye\n");
|
|
|
|
# TEST 4: Conditional pre-set
|
|
|
|
run_make_test('
|
|
foo = Hello
|
|
ugh = Goodbye
|
|
bar = ${ugh}
|
|
foo ?= $(bar)
|
|
ugh = Hello
|
|
all: ; @echo $(foo)
|
|
',
|
|
'', "Hello\n");
|
|
|
|
# TEST 5: Conditional unset
|
|
|
|
run_make_test('
|
|
ugh = Goodbye
|
|
bar = ${ugh}
|
|
foo ?= $(bar)
|
|
ugh = Hello
|
|
all: ; @echo $(foo)
|
|
',
|
|
'', "Hello\n");
|
|
|
|
1;
|