mirror of
https://git.savannah.gnu.org/git/make.git
synced 2025-01-01 09:50:31 +00:00
a2232470c2
- Resolve support request #103195 (rationalize wordlist fn arguments)
39 lines
876 B
Perl
39 lines
876 B
Perl
# -*-perl-*-
|
|
|
|
$description = "Test make -B (always remake) option.\n";
|
|
|
|
$details = "\
|
|
Construct a simple makefile that builds a target.
|
|
Invoke make once, so it builds everything. Invoke it again and verify
|
|
that nothing is built. Then invoke it with -B and verify that everything
|
|
is built again.";
|
|
|
|
&touch('bar.x');
|
|
|
|
run_make_test('
|
|
.SUFFIXES:
|
|
|
|
.PHONY: all
|
|
all: foo
|
|
|
|
foo: bar.x
|
|
@echo cp $< $@
|
|
@echo "" > $@
|
|
',
|
|
'', 'cp bar.x foo');
|
|
|
|
run_make_test(undef, '', "#MAKE#: Nothing to be done for `all'.");
|
|
run_make_test(undef, '-B', 'cp bar.x foo');
|
|
|
|
# Put the timestamp for foo into the future; it should still be remade.
|
|
|
|
utouch(1000, 'foo');
|
|
run_make_test(undef, '', "#MAKE#: Nothing to be done for `all'.");
|
|
run_make_test(undef, '-B', 'cp bar.x foo');
|
|
|
|
|
|
# Clean up
|
|
|
|
rmfiles('bar.x', 'foo');
|
|
|
|
1;
|