mirror of
https://git.savannah.gnu.org/git/make.git
synced 2024-12-29 08:09:02 +00:00
08c8105c54
- OS/2 Patches - OpenVMS updates - Sanitize the handling of -include/sinclude with and without -k - Fix the setting of $< for order-only rules.
54 lines
893 B
Perl
54 lines
893 B
Perl
# -*-perl-*-
|
|
|
|
$description = "Test special GNU make variables.";
|
|
|
|
$details = "";
|
|
|
|
&run_make_test('
|
|
|
|
X1 := $(sort $(filter FOO BAR,$(.VARIABLES)))
|
|
|
|
FOO := foo
|
|
|
|
X2 := $(sort $(filter FOO BAR,$(.VARIABLES)))
|
|
|
|
BAR := bar
|
|
|
|
all:
|
|
@echo X1 = $(X1)
|
|
@echo X2 = $(X2)
|
|
@echo LAST = $(sort $(filter FOO BAR,$(.VARIABLES)))
|
|
',
|
|
'', "X1 =\nX2 = FOO\nLAST = BAR FOO\n");
|
|
|
|
|
|
|
|
# $makefile2 = &get_tmpfile;
|
|
# open(MAKEFILE, "> $makefile2");
|
|
|
|
# print MAKEFILE <<'EOF';
|
|
|
|
# X1 := $(sort $(.TARGETS))
|
|
|
|
# all: foo
|
|
# @echo X1 = $(X1)
|
|
# @echo X2 = $(X2)
|
|
# @echo LAST = $(sort $(.TARGETS))
|
|
|
|
# X2 := $(sort $(.TARGETS))
|
|
|
|
# foo:
|
|
|
|
# EOF
|
|
|
|
# close(MAKEFILE);
|
|
|
|
# # TEST #2
|
|
# # -------
|
|
|
|
# &run_make_with_options($makefile2, "", &get_logfile);
|
|
# $answer = "X1 =\nX2 = all\nLAST = all foo\n";
|
|
# &compare_output($answer, &get_logfile(1));
|
|
|
|
|
|
1;
|