Skip to content

Commit 39a8318

Browse files
committed
Add a bare bones book building structure
This just creates some bare bones files to give us a starting point for generating content. This assumes you have the TeX Live and make available. Just run "make" to generate the book pdf. Reviewed-by: Tim Hudson <[email protected]> (Merged from #1)
1 parent 7e597bc commit 39a8318

File tree

4 files changed

+84
-0
lines changed

4 files changed

+84
-0
lines changed

Diff for: .gitignore

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#PDF, aux and log files
2+
*.pdf
3+
*.log
4+
*.aux
5+
6+
#Top level auto-generated files
7+
openssl-book.out
8+
openssl-book.toc

Diff for: Makefile

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# Copyright 2017 The OpenSSL Project Authors. All Rights Reserved.
2+
#
3+
#Location of the openssl version we are using. May not be the same as the system
4+
#version
5+
OSSLDIR= /usr/local/ssl
6+
CC= gcc
7+
CFLAGS= -I$(OSSLDIR)/include -L$(OSSLDIR)/lib -g -lcrypto -lssl
8+
9+
#No exe's to build yet
10+
EXE=
11+
12+
BOOKELEMS= openssl-book.tex
13+
14+
all: openssl-book.pdf
15+
16+
$(EXE): %: %.c
17+
$(CC) -o $@ $< $(CFLAGS)
18+
19+
#We run this twice to ensure that any references etc are updated
20+
openssl-book.pdf: $(BOOKELEMS) $(EXE)
21+
pdflatex openssl-book
22+
pdflatex openssl-book
23+
24+
code: $(EXE)
25+
26+
clean-code:
27+
rm $(EXE)
28+
29+
clean-book:
30+
rm openssl-book.pdf openssl-book.log openssl-book.aux openssl-book.out
31+
32+
#Add clean-code here when we actually have code to clean
33+
clean: clean-book

Diff for: introduction/about/about.tex

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
\chapter{About OpenSSL}
2+
3+
\todo{Add some text here.}

Diff for: openssl-book.tex

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
\documentclass[oneside]{book}
2+
\author{The OpenSSL Project}
3+
\title{The OpenSSL Guide}
4+
5+
\usepackage{color}
6+
\usepackage{colortbl}
7+
\usepackage{graphicx}
8+
\usepackage[hidelinks]{hyperref}
9+
\usepackage{listings}
10+
\usepackage{xcolor}
11+
\newcommand\todo[1]{\textcolor{red}{[TODO:#1]}}
12+
\definecolor{LightGray}{gray}{0.9}
13+
\lstdefinestyle{osslc}{
14+
breaklines=true,
15+
frame=single,
16+
xleftmargin=\parindent,
17+
language=C,
18+
showstringspaces=false,
19+
basicstyle=\footnotesize\ttfamily,
20+
numbers=left,
21+
numberstyle=\tiny,
22+
captionpos=b
23+
}
24+
25+
\begin{document}
26+
\lstset{style=osslc}
27+
\maketitle
28+
\tableofcontents
29+
30+
\part{Introduction}
31+
32+
\include{introduction/about/about}
33+
34+
\part{OpenSSL on the Command Line}
35+
36+
\part{SSL/TLS/DTLS Application Programming}
37+
38+
\part{Cryptography Application Programming}
39+
40+
\end{document}

0 commit comments

Comments
 (0)