aboutsummaryrefslogtreecommitdiffstats
path: root/buch
diff options
context:
space:
mode:
authorAndreas Müller <andreas.mueller@ost.ch>2022-01-24 19:24:16 +0100
committerAndreas Müller <andreas.mueller@ost.ch>2022-01-24 19:24:16 +0100
commit8632a871313f198296bd0c707661a24711c70b9f (patch)
tree877539ff9b9622288124cef76bb35313fec4fd28 /buch
parentconditional file inclusion (diff)
downloadSeminarSpezielleFunktionen-8632a871313f198296bd0c707661a24711c70b9f.tar.gz
SeminarSpezielleFunktionen-8632a871313f198296bd0c707661a24711c70b9f.zip
build two different files for printer and students
Diffstat (limited to 'buch')
-rwxr-xr-xbuch/Makefile5
-rw-r--r--buch/buch.tex64
-rwxr-xr-xbuch/common/Makefile.inc1
-rw-r--r--buch/common/content.tex67
-rw-r--r--buch/common/packages.tex4
5 files changed, 79 insertions, 62 deletions
diff --git a/buch/Makefile b/buch/Makefile
index 3f2515f..7014b97 100755
--- a/buch/Makefile
+++ b/buch/Makefile
@@ -34,6 +34,11 @@ speziellefunktionen.pdf:
buch.pdf 1-20 \
../cover/back.pdf {},1
+SeminarSpezielleFunktionen.pdf: SeminarSpezielleFunktionen.tex $(TEXFILES) \
+ buch.ind $(BLXFILES)
+ pdflatex buch.tex
+ bibtex buch
+
#
# This Makefile can also construct the short tests
#
diff --git a/buch/buch.tex b/buch/buch.tex
index cbbf339..4afc374 100644
--- a/buch/buch.tex
+++ b/buch/buch.tex
@@ -3,65 +3,5 @@
%
% (c) 2022 Prof. Dr. Andreas Mueller, OST Ostschweizer Fachhochschule
%
-\documentclass{book}
-\input{common/packages.tex}
-
-% additional packages used by the individual papers, add a line for
-% each paper
-\input{papers/common/addpackages.tex}
-
-% PDF info
-\hypersetup{
-pdftitle={Mathematisches Seminar Spezielle Funktionen},
-pdfauthor={Andreas Müller}
-}
-
-% workaround for biblatex bug
-\makeatletter
-\def\blx@maxline{77}
-\makeatother
-\addbibresource{chapters/references.bib}
-
-% Bibresources for each article
-\input{papers/common/addbibresources.tex}
-
-% make sure the last index starts on an odd page
-\AtEndDocument{\clearpage\ifodd\value{page}\else\null\clearpage\fi}
-\makeindex
-
-%\pgfplotsset{compat=1.12}
-\setlength{\headheight}{15pt} % fix headheight warning
-\DeclareGraphicsRule{*}{mps}{*}{}
-\begin{document}
-
-% cover page
-\ifthenelse{\boolean{includecover}}{
-\incgraph[documentpaper][width=\paperwidth,height=\paperheight]{../cover/buchcover.jpg}
-\newpage\null\thispagestyle{empty}\newpage
-}{}
-
-\input{common/titlepage.tex}
-
-% add common macros
-\input{common/macros.tex}
-
-\mainmatter
-\input{chapters/part1.tex}
-
-\input{papers/part2.tex}
-
-\vfill
-\pagebreak
-\ifodd\value{page}\else\null\clearpage\fi
-\lhead{Index}
-\rhead{}
-\addcontentsline{toc}{chapter}{\indexname}
-\InputIfFileExists{buch.ind}{}{}
-
-% cover page
-\ifthenelse{\boolean{includecover}}{
-\newpage\null\thispagestyle{empty}\newpage
-\incgraph[documentpaper][width=\paperwidth,height=\paperheight]{../cover/backcover.jpg}
-}{}
-
-\end{document}
+\def\IncludeBookCover{0}
+\input{common/content.tex}
diff --git a/buch/common/Makefile.inc b/buch/common/Makefile.inc
index fec5a33..c8b0f6e 100755
--- a/buch/common/Makefile.inc
+++ b/buch/common/Makefile.inc
@@ -16,6 +16,7 @@ images:
done
BUCHFILES = \
+ common/content.tex \
common/macros.tex \
common/lststyles.tex \
common/packages.tex \
diff --git a/buch/common/content.tex b/buch/common/content.tex
new file mode 100644
index 0000000..cbbf339
--- /dev/null
+++ b/buch/common/content.tex
@@ -0,0 +1,67 @@
+%
+% buch.tex -- Buch zum mathematischen Seminar Spezielle Funktionen
+%
+% (c) 2022 Prof. Dr. Andreas Mueller, OST Ostschweizer Fachhochschule
+%
+\documentclass{book}
+\input{common/packages.tex}
+
+% additional packages used by the individual papers, add a line for
+% each paper
+\input{papers/common/addpackages.tex}
+
+% PDF info
+\hypersetup{
+pdftitle={Mathematisches Seminar Spezielle Funktionen},
+pdfauthor={Andreas Müller}
+}
+
+% workaround for biblatex bug
+\makeatletter
+\def\blx@maxline{77}
+\makeatother
+\addbibresource{chapters/references.bib}
+
+% Bibresources for each article
+\input{papers/common/addbibresources.tex}
+
+% make sure the last index starts on an odd page
+\AtEndDocument{\clearpage\ifodd\value{page}\else\null\clearpage\fi}
+\makeindex
+
+%\pgfplotsset{compat=1.12}
+\setlength{\headheight}{15pt} % fix headheight warning
+\DeclareGraphicsRule{*}{mps}{*}{}
+\begin{document}
+
+% cover page
+\ifthenelse{\boolean{includecover}}{
+\incgraph[documentpaper][width=\paperwidth,height=\paperheight]{../cover/buchcover.jpg}
+\newpage\null\thispagestyle{empty}\newpage
+}{}
+
+\input{common/titlepage.tex}
+
+% add common macros
+\input{common/macros.tex}
+
+\mainmatter
+\input{chapters/part1.tex}
+
+\input{papers/part2.tex}
+
+\vfill
+\pagebreak
+\ifodd\value{page}\else\null\clearpage\fi
+\lhead{Index}
+\rhead{}
+\addcontentsline{toc}{chapter}{\indexname}
+\InputIfFileExists{buch.ind}{}{}
+
+% cover page
+\ifthenelse{\boolean{includecover}}{
+\newpage\null\thispagestyle{empty}\newpage
+\incgraph[documentpaper][width=\paperwidth,height=\paperheight]{../cover/backcover.jpg}
+}{}
+
+\end{document}
diff --git a/buch/common/packages.tex b/buch/common/packages.tex
index 2051093..d35a306 100644
--- a/buch/common/packages.tex
+++ b/buch/common/packages.tex
@@ -78,4 +78,8 @@
% set this variable to false when preparing the PDF for the printer
\newboolean{includecover}
+\if0\IncludeBookCover
+\setboolean{includecover}{false}
+\else
\setboolean{includecover}{true}
+\fi