3 $description = "This script tests to make sure that Make looks for
4 default makefiles in the correct order (GNUmakefile,makefile,Makefile)";
6 # Create a makefile called "GNUmakefile"
7 $makefile = "GNUmakefile";
9 open(MAKEFILE,"> $makefile");
10 print MAKEFILE "FIRST: ; \@echo It chose GNUmakefile\n";
13 # DOS/WIN32 platforms preserve case, but Makefile is the same file as makefile.
14 # Just test what we can here (avoid Makefile versus makefile test).
16 if ($port_type eq 'UNIX') {
17 # Create another makefile called "makefile"
18 open(MAKEFILE,"> makefile");
19 print MAKEFILE "SECOND: ; \@echo It chose makefile\n";
23 # Create another makefile called "Makefile"
24 open(MAKEFILE,"> Makefile");
25 print MAKEFILE "THIRD: ; \@echo It chose Makefile\n";
29 &run_make_with_options("","",&get_logfile);
30 &compare_output("It chose GNUmakefile\n",&get_logfile(1));
33 if ($port_type eq 'UNIX') {
34 &run_make_with_options("","",&get_logfile);
35 &compare_output("It chose makefile\n",&get_logfile(1));
39 &run_make_with_options("","",&get_logfile);
40 &compare_output("It chose Makefile\n",&get_logfile(1));