VirtualBox

source: kBuild/vendor/gnumake/current/tests/scripts/variables/MAKEFILES@ 2596

最後變更 在這個檔案從2596是 2596,由 bird 提交於 13 年 前

gnumake/current -> 3.82-cvs.

  • 屬性 svn:eol-style 設為 LF
檔案大小: 1.1 KB
 
1# -*-perl-*-
2
3$description = "Test the MAKEFILES variable.";
4
5$makefile2 = &get_tmpfile;
6$makefile3 = &get_tmpfile;
7
8open(MAKEFILE,"> $makefile");
9print MAKEFILE 'all: ; @echo DEFAULT RULE: M2=$(M2) M3=$(M3)', "\n";
10close(MAKEFILE);
11
12
13open(MAKEFILE,"> $makefile2");
14print MAKEFILE <<EOF;
15M2 = m2
16NDEF: ; \@echo RULE FROM MAKEFILE 2
17EOF
18close(MAKEFILE);
19
20
21open(MAKEFILE,"> $makefile3");
22print MAKEFILE <<EOF;
23M3 = m3
24NDEF3: ; \@echo RULE FROM MAKEFILE 3
25EOF
26close(MAKEFILE);
27
28
29&run_make_with_options($makefile, "MAKEFILES='$makefile2 $makefile3'",
30 &get_logfile);
31$answer = "DEFAULT RULE: M2=m2 M3=m3\n";
32&compare_output($answer,&get_logfile(1));
33
34# TEST 2: Verify that included makefiles don't set the default goal.
35# See Savannah bug #13401.
36
37create_file('xx-inc.mk', '
38include_goal: ; @echo $@
39include xx-ind.mk
40');
41
42create_file('xx-ind.mk', '
43indirect_goal: ; @echo $@
44');
45
46run_make_test(q!
47top: ; @echo $@
48!,
49 'MAKEFILES=xx-inc.mk', "top\n");
50
51unlink(qw(xx-inc.mk xx-ind.mk));
52
531;
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette