diff --git a/Makefile.in b/Makefile.in index 42272b19cb9..3949067bc7b 100644 --- a/Makefile.in +++ b/Makefile.in @@ -69,7 +69,7 @@ R: Makefile svnonly $(ECHO) "you should 'make docs' now ..." docs: R FORCE - -@(cd doc && $(MAKE) $@) + @(cd doc && $(MAKE) $@) -@(cd src/library && $(MAKE) $@) FORCE: diff --git a/doc/Makefile.in b/doc/Makefile.in index 786bc1a4afc..4cf06bb7419 100644 --- a/doc/Makefile.in +++ b/doc/Makefile.in @@ -57,14 +57,14 @@ Rscript.1: NEWS.rds: $(srcdir)/NEWS.Rd @$(ECHO) "options(warn=1);saveRDS(tools:::prepare_Rd(tools::parse_Rd(\"$(srcdir)/NEWS.Rd\", \ macros = \"../share/Rd/macros/system.Rd\"), stages = 'install', warningCalls = FALSE), \ - 'NEWS.rds')" | $(R_EXE) + 'NEWS.rds')" | $(R_EXE) || rm $^ NEWS: NEWS.rds @$(ECHO) "creating doc/NEWS" - @$(ECHO) 'options(warn=1);tools:::Rd2txt_NEWS_in_Rd("NEWS.rds", "NEWS")' | $(R_EXE) + @$(ECHO) 'options(warn=1);tools:::Rd2txt_NEWS_in_Rd("NEWS.rds", "NEWS")' | $(R_EXE) || rm $^ html/NEWS.html: NEWS.rds - @$(ECHO) 'options(warn=1);tools:::Rd2HTML_NEWS_in_Rd("NEWS.rds", "html/NEWS.html")' | $(R_EXE) + @$(ECHO) 'options(warn=1);tools:::Rd2HTML_NEWS_in_Rd("NEWS.rds", "html/NEWS.html")' | $(R_EXE) || rm $^ PDFLATEX = @PDFLATEX@ ## needs pdflatex (and more) @@ -74,7 +74,7 @@ NEWS.pdf: NEWS.rds else \ $(ECHO) "creating doc/NEWS.pdf"; \ $(ECHO) 'options(warn=1);tools:::Rd2pdf_NEWS_in_Rd("NEWS.rds", "NEWS.pdf")' | \ - TEXINPUTS="$(top_srcdir)/share/texmf/tex/latex:$$TEXINPUTS" $(R_EXE); \ + TEXINPUTS="$(top_srcdir)/share/texmf/tex/latex:$$TEXINPUTS" $(R_EXE) || rm $^; \ fi docs3: NEWS.3.rds NEWS.3.html NEWS.3.pdf @@ -82,15 +82,15 @@ docs3: NEWS.3.rds NEWS.3.html NEWS.3.pdf NEWS.3.rds: $(srcdir)/NEWS.3.Rd @$(ECHO) "options(warn=1);saveRDS(tools:::prepare_Rd(tools::parse_Rd(\"$(srcdir)/NEWS.3.Rd\", \ macros = \"../share/Rd/macros/system.Rd\"), stages = 'install', warningCalls = FALSE), \ - 'NEWS.3.rds')" | $(R_EXE) + 'NEWS.3.rds')" | $(R_EXE) || rm $^ NEWS.3: NEWS.3.rds @$(ECHO) "creating NEWS.3" - @$(ECHO) 'options(warn=1);tools:::Rd2txt_NEWS_in_Rd("NEWS.3.rds", "NEWS.3")' | $(R_EXE) + @$(ECHO) 'options(warn=1);tools:::Rd2txt_NEWS_in_Rd("NEWS.3.rds", "NEWS.3")' | $(R_EXE) || rm $^ NEWS.3.html: NEWS.3.rds @$(ECHO) "creating NEWS.3.html" - @$(ECHO) 'options(warn=1);tools:::Rd2HTML_NEWS_in_Rd("NEWS.3.rds", "NEWS.3.html")' | $(R_EXE) + @$(ECHO) 'options(warn=1);tools:::Rd2HTML_NEWS_in_Rd("NEWS.3.rds", "NEWS.3.html")' | $(R_EXE) || rm $^ NEWS.3.pdf: NEWS.3.rds @if test -z "$(PDFLATEX)"; then \ @@ -98,7 +98,7 @@ NEWS.3.pdf: NEWS.3.rds else \ $(ECHO) "creating NEWS.3.pdf"; \ $(ECHO) 'options(warn=1);tools:::Rd2pdf_NEWS_in_Rd("NEWS.3.rds", "NEWS.3.pdf")' | \ - TEXINPUTS="$(top_srcdir)/share/texmf/tex/latex:$$TEXINPUTS" $(R_EXE); \ + TEXINPUTS="$(top_srcdir)/share/texmf/tex/latex:$$TEXINPUTS" $(R_EXE) || rm $^; \ fi ## NEWS.2.html ships as doc/html/NEWS.2.html in the sources. @@ -107,16 +107,16 @@ docs2: NEWS.2.rds NEWS.2.html NEWS.2.pdf NEWS.2.rds: $(srcdir)/NEWS.2.Rd @$(ECHO) "options(warn=1);saveRDS(tools:::prepare_Rd(tools::parse_Rd(\"$(srcdir)/NEWS.2.Rd\", \ macros = \"../share/Rd/macros/system.Rd\"), stages = 'install', warningCalls = FALSE), \ - 'NEWS.2.rds')" | $(R_EXE) + 'NEWS.2.rds')" | $(R_EXE) || rm $^ ## NB: this is only the top part of NEWS.2 in the sources. NEWS.2: NEWS.2.rds @$(ECHO) "creating NEWS.2" - @$(ECHO) 'options(warn=1);tools:::Rd2txt_NEWS_in_Rd("NEWS.2.rds", "NEWS.2")' | $(R_EXE) + @$(ECHO) 'options(warn=1);tools:::Rd2txt_NEWS_in_Rd("NEWS.2.rds", "NEWS.2")' | $(R_EXE) || rm $^ NEWS.2.html: NEWS.2.rds @$(ECHO) "creating NEWS.2.html" - @$(ECHO) 'options(warn=1);tools:::Rd2HTML_NEWS_in_Rd("NEWS.2.rds", "NEWS.2.html")' | $(R_EXE) + @$(ECHO) 'options(warn=1);tools:::Rd2HTML_NEWS_in_Rd("NEWS.2.rds", "NEWS.2.html")' | $(R_EXE) || rm $^ NEWS.2.pdf: NEWS.2.rds @if test -z "$(PDFLATEX)"; then \ @@ -124,7 +124,7 @@ NEWS.2.pdf: NEWS.2.rds else \ $(ECHO) "creating NEWS.2.pdf"; \ $(ECHO) 'options(warn=1);tools:::Rd2pdf_NEWS_in_Rd("NEWS.2.rds", "NEWS.2.pdf")' | \ - TEXINPUTS="$(top_srcdir)/share/texmf/tex/latex:$$TEXINPUTS" $(R_EXE); \ + TEXINPUTS="$(top_srcdir)/share/texmf/tex/latex:$$TEXINPUTS" $(R_EXE) || rm $^; \ fi diff --git a/doc/Makefile.win b/doc/Makefile.win index bdb68df8eda..545177a08c4 100644 --- a/doc/Makefile.win +++ b/doc/Makefile.win @@ -14,28 +14,28 @@ all: NEWS.rds html/NEWS.html NEWS NEWS.pdf NEWS.2.rds NEWS.3.rds \ NEWS.rds: NEWS.Rd @$(ECHO) "options(warn=1);saveRDS(tools:::prepare_Rd(tools::parse_Rd(\"$<\", \ macros = \"../share/Rd/macros/system.Rd\"), stages = \"install\", \ - warningCalls = FALSE), \"$@\")" | $(R_EXE) + warningCalls = FALSE), \"$@\")" | $(R_EXE) || rm $^ NEWS.2.rds: NEWS.2.Rd @$(ECHO) "options(warn=1);saveRDS(tools:::prepare_Rd(tools::parse_Rd(\"$<\", \ macros = \"../share/Rd/macros/system.Rd\"), stages = \"install\", \ - warningCalls = FALSE), \"$@\")" | $(R_EXE) + warningCalls = FALSE), \"$@\")" | $(R_EXE) || rm $^ NEWS.3.rds: NEWS.3.Rd @$(ECHO) "options(warn=1);saveRDS(tools:::prepare_Rd(tools::parse_Rd(\"$<\", \ macros = \"../share/Rd/macros/system.Rd\"), stages = \"install\", \ - warningCalls = FALSE), \"$@\")" | $(R_EXE) + warningCalls = FALSE), \"$@\")" | $(R_EXE) || rm $^ CHANGES.rds: ../src/gnuwin32/CHANGES.Rd @$(ECHO) "options(warn=1);saveRDS(tools:::prepare_Rd(tools::parse_Rd(\"$<\", \ macros = \"../share/Rd/macros/system.Rd\"), stages = \"install\", \ - warningCalls = FALSE), \"$@\")" | $(R_EXE) + warningCalls = FALSE), \"$@\")" | $(R_EXE) || rm $^ ## Force ASCII output, for portability on Windows NEWS: NEWS.rds @$(ECHO) "creating doc/NEWS" @$(ECHO) "options(warn=1);tools:::Rd2txt_NEWS_in_Rd(\"$<\", \"$@\", \ - outputEncoding = \"ASCII//TRANSLIT\")" | $(R_EXE) + outputEncoding = \"ASCII//TRANSLIT\")" | $(R_EXE) || rm $^ ## Should be allowed to fail if pdflatex is not available NEWS.pdf: NEWS.rds @@ -45,15 +45,15 @@ NEWS.pdf: NEWS.rds CHANGES: CHANGES.rds @$(ECHO) "options(warn=1);tools:::Rd2txt_NEWS_in_Rd(\"$<\", \"$@\", \ - outputEncoding = \"ASCII//TRANSLIT\")" | $(R_EXE) + outputEncoding = \"ASCII//TRANSLIT\")" | $(R_EXE) || rm $^ html/NEWS.html: NEWS.rds @$(ECHO) "options(warn=1);tools:::Rd2HTML_NEWS_in_Rd(\"$<\", \"$@\")" | \ - $(R_EXE) + $(R_EXE) || rm $^ html/CHANGES.html: CHANGES.rds @$(ECHO) "options(warn=1);tools:::Rd2HTML_NEWS_in_Rd(\"$<\", \"$@\")" | \ - $(R_EXE) + $(R_EXE) || rm $^ clean: @rm -f NEWS.rds html/NEWS.html NEWS NEWS.pdf \ diff --git a/doc/NEWS.Rd b/doc/NEWS.Rd index e36f305cf2c..ff99a074b81 100644 --- a/doc/NEWS.Rd +++ b/doc/NEWS.Rd @@ -97,6 +97,9 @@ \item Building the HTML (and Info) versions of the R manuals now requires \command{texi2any} from \I{Texinfo} 6.1 or later. + + \item Failures in building the manuals under \file{doc} now abort + the installation, removing sny file which caused the failure. } } diff --git a/doc/manual/Makefile.in b/doc/manual/Makefile.in index ac9504a27e6..dba42f38406 100644 --- a/doc/manual/Makefile.in +++ b/doc/manual/Makefile.in @@ -191,7 +191,7 @@ $(texinputs_BASE): FORCE "tools:::.Rdnewer(\"$(top_srcdir)/src/library/$${pkg}\", \"$@\")"; then \ $(ECHO) "collecting LaTeX docs for package '$${pkg}' ..."; \ $(ECHO) "tools:::.pkg2tex(\"$(top_builddir)/library/$${pkg}\")" \ - | LC_ALL=C $(R_EXE) ; \ + | LC_ALL=C $(R_EXE) || rm $^ ; \ fi) FORCE: @@ -201,7 +201,7 @@ $(texinputs_RECOMMENDED): FORCE -print 2> /dev/null | grep $@ > /dev/null; then :; else \ $(ECHO) "collecting LaTeX docs for package '$${pkg}' ..."; \ $(ECHO) "tools:::.pkg2tex(\"$(top_builddir)/library/$${pkg}\")" \ - | LC_ALL=C $(R_EXE) ; \ + | LC_ALL=C $(R_EXE) || rm $^ ; \ fi) version.texi: Makefile $(top_srcdir)/VERSION $(SVN_REV) diff --git a/doc/manual/Makefile.win b/doc/manual/Makefile.win index da1caef6ed9..bccf08a0532 100644 --- a/doc/manual/Makefile.win +++ b/doc/manual/Makefile.win @@ -161,7 +161,7 @@ compact-pdf: %-pkg.tex: FORCE @$(ECHO) "collecting LaTeX docs for package \`$*' ..." @$(ECHO) "tools:::.pkg2tex(\"$(top_srcdir)/library/$*\")" \ - | LC_ALL=C $(R_EXE) --vanilla --no-echo + | LC_ALL=C $(R_EXE) --vanilla --no-echo || rm $^ FORCE: version.texi: Makefile.win $(top_srcdir)/VERSION $(SVN_REV)