1
Это мой Makefile:Ошибка в Makefile
.SILENT:
latexargs = -output-directory=temp -interaction=batchmode -file-line-error-style
thesis: mktemp
latex $(latexargs) thesis || make errors
bibtex -terse temp/A || make errors
bibtex -terse temp/B || make errors
latex $(latexargs) thesis || make errors
pdflatex $(latexargs) thesis || make errors
cat temp/thesis.pdf > thesis.pdf
diff: mktemp
latex $(latexargs) thesis-diff || make errors
bibtex temp/A || make errors
bibtex temp/B || make errors
latex $(latexargs) thesis-diff || make errors
pdflatex $(latexargs) thesis-diff || make errors
rm thesis-diff.tex
clean:
test -e temp
rm -f temp/*
mktemp:
mkdir -p temp
errors:
grep ":[^:]*:" temp/thesis.log
false
Есть ли лучший способ запустить что-то, если команда выходит с не нулевым кодом?
Я просмотрел manual, но не смог найти никаких специальных целей для этой цели.
правда Даты. Таким образом, я не вызываю подоболочку. Благодарю. Я не соглашусь с этим, но мне трудно полагать, что такая мощная система не имеет возможности сделать процедуру try-catch-finally. – andsens