/
niceSOFT
/
make
Обзор
Документация
Войти
/
niceSOFT
/
make
Код
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
3.78.91
tests/scripts/features/vpathgpath
64 строки
1 KB
Paul Smith
* Added the test suite to the main distribution.
14 сен 1999, 06:03
14 сен 1999, 06:03
0d366b6
Код
Авторство
О чём код?
# -*-perl-*- $description = "Tests VPATH+/GPATH functionality."; $details = ""; $VP = "$workdir$pathsep"; open(MAKEFILE,"> $makefile"); # The Contents of the MAKEFILE ... print MAKEFILE "VPATH = $VP\n"; print MAKEFILE <<'EOMAKE'; GPATH = $(VPATH) .SUFFIXES: .a .b .c .d .PHONY: general rename notarget intermediate %.a: %.b: %.c: %.d: %.a : %.b ; cat $^ > $@ %.b : %.c ; cat $^ > $@ %.c :: %.d ; cat $^ > $@ # General testing info: general: foo.b foo.b: foo.c bar.c EOMAKE close(MAKEFILE); @touchedfiles = (); sub touchfiles { foreach (@_) { ($f = $_) =~ s,VP/,$VP,g; &touch($f); push(@touchedfiles, $f); sleep(1); } } # Run the general-case test &touchfiles("VP/foo.d", "VP/bar.d", "VP/foo.c", "VP/bar.c", "foo.b", "bar.d"); &run_make_with_options($makefile,"general",&get_logfile()); push(@touchedfiles, "bar.c"); $answer = "$make_name: Nothing to be done for `general'.\n"; &compare_output($answer,&get_logfile(1)); unlink(@touchedfiles) unless $keep; 1;