about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--.gitignore1
-rw-r--r--mk/docs.mk23
-rw-r--r--src/doc/footer.inc7
-rw-r--r--src/doc/footer.tex7
-rw-r--r--src/doc/rust.css10
5 files changed, 40 insertions, 8 deletions
diff --git a/.gitignore b/.gitignore
index 73edf3bdfce..2fa5de27495 100644
--- a/.gitignore
+++ b/.gitignore
@@ -75,7 +75,6 @@ src/.DS_Store
 /nd/
 /llvm/
 version.md
-*.tex
 keywords.md
 x86_64-apple-darwin/
 x86_64-unknown-linux-gnu/
diff --git a/mk/docs.mk b/mk/docs.mk
index a95163d0979..08bbee9edca 100644
--- a/mk/docs.mk
+++ b/mk/docs.mk
@@ -19,8 +19,10 @@ HTML_DEPS := doc/
 
 BASE_DOC_OPTS := --standalone --toc --number-sections
 HTML_OPTS = $(BASE_DOC_OPTS) --to=html5 --section-divs --css=rust.css \
-    --include-before-body=doc/version_info.html --include-in-header=doc/favicon.inc
-TEX_OPTS = $(BASE_DOC_OPTS) --include-before-body=doc/version.md --to=latex
+    --include-before-body=doc/version_info.html \
+    --include-in-header=doc/favicon.inc --include-after-body=doc/footer.inc
+TEX_OPTS = $(BASE_DOC_OPTS) --include-before-body=doc/version.md \
+    --from=markdown --include-before-body=doc/footer.tex --to=latex
 EPUB_OPTS = $(BASE_DOC_OPTS) --to=epub
 
 D := $(S)src/doc
@@ -55,12 +57,21 @@ doc/rust.css: $(D)/rust.css | doc/
 	@$(call E, cp: $@)
 	$(Q)cp -a $< $@ 2> /dev/null
 
+HTML_DEPS += doc/favicon.inc
+doc/favicon.inc: $(D)/favicon.inc | doc/
+	@$(call E, cp: $@)
+	$(Q)cp -a $< $@ 2> /dev/null
+
 doc/full-toc.inc: $(D)/full-toc.inc | doc/
 	@$(call E, cp: $@)
 	$(Q)cp -a $< $@ 2> /dev/null
 
-HTML_DEPS += doc/favicon.inc
-doc/favicon.inc: $(D)/favicon.inc | doc/
+HTML_DEPS += doc/footer.inc
+doc/footer.inc: $(D)/footer.inc | doc/
+	@$(call E, cp: $@)
+	$(Q)cp -a $< $@ 2> /dev/null
+
+doc/footer.tex: $(D)/footer.tex | doc/
 	@$(call E, cp: $@)
 	$(Q)cp -a $< $@ 2> /dev/null
 
@@ -83,7 +94,7 @@ doc/rust.html: $(D)/rust.md doc/full-toc.inc $(HTML_DEPS) | doc/
 	$(CFG_PANDOC) $(HTML_OPTS) --include-in-header=doc/full-toc.inc --output=$@
 
 DOCS += doc/rust.tex
-doc/rust.tex: $(D)/rust.md doc/version.md | doc/
+doc/rust.tex: $(D)/rust.md doc/footer.tex doc/version.md | doc/
 	@$(call E, pandoc: $@)
 	$(Q)$(CFG_NODE) $(D)/prep.js $< | \
 	$(CFG_PANDOC) $(TEX_OPTS) --output=$@
@@ -107,7 +118,7 @@ doc/tutorial.html: $(D)/tutorial.md $(HTML_DEPS)
 	$(CFG_PANDOC) $(HTML_OPTS) --output=$@
 
 DOCS += doc/tutorial.tex
-doc/tutorial.tex: $(D)/tutorial.md doc/version.md
+doc/tutorial.tex: $(D)/tutorial.md doc/footer.tex doc/version.md
 	@$(call E, pandoc: $@)
 	$(Q)$(CFG_NODE) $(D)/prep.js $< | \
 	$(CFG_PANDOC) $(TEX_OPTS) --output=$@
diff --git a/src/doc/footer.inc b/src/doc/footer.inc
new file mode 100644
index 00000000000..a103a4908f6
--- /dev/null
+++ b/src/doc/footer.inc
@@ -0,0 +1,7 @@
+<footer><p>
+Copyright &copy; 2011-2014 The Rust Project Developers. Licensed under the
+<a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>
+or the <a href="http://opensource.org/licenses/MIT">MIT license</a>, at your option.
+</p><p>
+This file may not be copied, modified, or distributed except according to those terms.
+</p></footer>
diff --git a/src/doc/footer.tex b/src/doc/footer.tex
new file mode 100644
index 00000000000..9f9ceb6ba9a
--- /dev/null
+++ b/src/doc/footer.tex
@@ -0,0 +1,7 @@
+Copyright © 2011-2014 The Rust Project Developers. Licensed under the
+\href{http://www.apache.org/licenses/LICENSE-2.0}{Apache License,
+Version 2.0} or the \href{http://opensource.org/licenses/MIT}{MIT
+license}, at your option.
+
+This file may not be copied, modified, or distributed except according
+to those terms.
diff --git a/src/doc/rust.css b/src/doc/rust.css
index 194a401395f..976c62beb03 100644
--- a/src/doc/rust.css
+++ b/src/doc/rust.css
@@ -15,7 +15,6 @@
 body {
     margin: 0 auto;
     padding: 0 15px;
-    margin-bottom: 4em;
     font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
     font-size: 14px;
     color: #333;
@@ -76,6 +75,15 @@ p {
     margin: 0 0 10px;
 }
 
+footer {
+    border-top: 1px solid #ddd;
+    font-size: 12px;
+    font-style: italic;
+    padding-top: 4px;
+    margin-top: 4em;
+    margin-bottom: 1em;
+}
+
 /* Links layout
    ========================================================================== */
 a {