diff options
author | Igor Pashev <pashev.igor@gmail.com> | 2015-03-24 21:29:00 +0300 |
---|---|---|
committer | Igor Pashev <pashev.igor@gmail.com> | 2015-03-24 21:34:59 +0300 |
commit | 036ccd8efa9ca16734b8baf4cc022eacb5d78576 (patch) | |
tree | 9338084f941380ef56eda8e52042652d5690656d /tests/scripts/features | |
parent | 87e2dd5c98e7bdd770914c2404efd8194778fc93 (diff) | |
download | gunmake-036ccd8efa9ca16734b8baf4cc022eacb5d78576.tar.gz |
Support SunOS make target-specific variables
Diffstat (limited to 'tests/scripts/features')
-rw-r--r-- | tests/scripts/features/sun-targetvars | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/scripts/features/sun-targetvars b/tests/scripts/features/sun-targetvars new file mode 100644 index 0000000..157973b --- /dev/null +++ b/tests/scripts/features/sun-targetvars @@ -0,0 +1,23 @@ +# -*-perl-*- +$description = "Check SunOS make target-specific assignment."; + +$details = "In SunOS make mode ':=' is used for target-specific variable, instead of ':' +Thus, ':=' cannot be used as variable assignment at all."; + +# SunOS make mode, $(other) is undefined: +run_make_test(' +FOO = true +all: other + @echo $(FOO) +other := FOO = false +other: + @echo $(FOO) $(other) +', +'--sun', +"false\ntrue\n"); + +# Same file, but in normal mode, $(other) is "FOO = false": +run_make_test(undef, '', "true FOO = false\ntrue\n"); + +# This tells the test driver that the perl test script executed properly. +1; |