Finito con {{{tee}}}, spostati un po' di TODO, messo il placeholder
[gapil.git] / gapil.tex
1 %% gapil.tex
2 %%
3 %% Copyright (C) 2000-2007 Simone Piccardi.  Permission is granted to
4 %% copy, distribute and/or modify this document under the terms of the GNU Free
5 %% Documentation License, Version 1.1 or any later version published by the
6 %% Free Software Foundation; with the Invariant Sections being "Un preambolo",
7 %% with no Front-Cover Texts, and with no Back-Cover Texts.  A copy of the
8 %% license is included in the section entitled "GNU Free Documentation
9 %% License".
10 %%
11 %% GaPiL : Guida alla Programmazione in Linux
12 %%
13 %% S. Piccardi Oct. 2000
14 %% 
15 %% gapil.tex: file principale, gli altri vanno inclusi da questo.
16 %%
17 \documentclass[a4paper,11pt,twoside]{book}
18 \usepackage{ae,aecompl}
19 \usepackage[T1]{fontenc}
20 \usepackage[latin1]{inputenc}
21 %\usepackage[tex4ht, bookmarks=true]{hyperref}
22 \usepackage[bookmarks=true,plainpages=false,pdfpagelabels,hyperfootnotes=false]{hyperref}
23 \usepackage{makeidx}
24 %\usepackage{booktabs}
25 %\usepackage{pstcol}
26 %\usepackage{pslatex}
27 \usepackage{pst-node}
28 \usepackage{graphicx}
29 \usepackage[italian]{babel}
30 \newcommand{\includecodesnip}[1]{\lstinputlisting[stepnumber=0,frame=]{#1}}{}
31 \newcommand{\includestruct}[1]{\lstinputlisting[stepnumber=0]{#1}}{}
32 \newcommand{\includecodesample}[1]{\lstinputlisting{#1}}{}
33 \usepackage{cite}
34 \usepackage{amsmath}
35 \usepackage{amsfonts}
36 \usepackage[hang,bf,footnotesize,it]{caption}
37 \usepackage{listings}
38 \lstloadlanguages{C++}
39 \usepackage{color} 
40 \usepackage{mdwlist}              % scommentare per la stampa (PS e PDF)
41 \usepackage{boxedminipage}        % scommentare per la stampa (PS e PDF)
42 \usepackage{multirow}
43 %\usepackage{footnote} 
44 %\usepackage{mdwtab} 
45 \usepackage{geometry}
46 \usepackage{fancyvrb}
47
48 \def\tild{\char'176}
49
50 %
51 % Setting page layout
52 %
53 %\oddsidemargin=0.5cm
54 %\evensidemargin=-0.5cm
55 %\textwidth=16cm
56 %\textheight=24.2cm
57 %\topmargin=-1.cm
58 \geometry{textheight=24.2cm,textwidth=16cm}
59
60
61 %\setcaptionmargin{2cm} 
62 %\renewcommand{\chaptername}{Capitolo}
63 %\renewcommand{\contentsname}{Indice}
64 %\renewcommand{\bibname}{Bibliografia}
65 \pagestyle{headings}
66
67 \frenchspacing
68
69 %\includeonly{macro,pref,intro,fdl}
70
71 \title{\Huge \textbf{\textsl{G}a\textsl{P}i\textsl{L}}\\
72 \huge Guida alla Programmazione in Linux} 
73
74 \author{Simone Piccardi}
75
76 \makeindex
77
78 % Solo prima parte, scommentare 
79 %\includeonly{macro,preambolo,pref,intro,process,prochand,fileintro,filedir,
80 %  fileunix,filestd,system,system,signal,session,fileadv,ipc,errors,
81 %  ringraziamenti,fdl}
82
83 % Solo seconda parte e appendici, scommentare
84 %\includeonly{macro,preambolo,network,socket,tcpsock,sockctrl,othersock,
85 %  sockadv,netlayer,trasplayer,errors,ringraziamenti,fdl}
86
87 \begin{document}
88
89 \frontmatter
90
91 \maketitle
92
93 \newcommand{\clearemptydoublepage}{\newpage{\pagestyle{empty}
94 \cleardoublepage}}
95
96 \begin{quote}
97   
98   Copyright \copyright\ 2000-2007 Simone Piccardi.  Permission is granted to
99   copy, distribute and/or modify this document under the terms of the GNU Free
100   Documentation License, Version 1.1 or any later version published by the
101   Free Software Foundation; with the Invariant Sections being ``Un preambolo''
102   in ``Prefazione'',
103   with no Front-Cover Texts, and with no Back-Cover Texts.  A copy of the
104   license is included in the section entitled ``GNU Free Documentation
105   License''.
106
107 \end{quote}
108 \clearemptydoublepage
109
110 %\ifx\hcode\undefined\else
111 \tableofcontents
112 %\fi
113
114 \clearemptydoublepage
115 \include{macro}
116 \include{preambolo}
117 \include{pref}
118 \clearemptydoublepage
119 \mainmatter
120
121 \lstset{language=C++} 
122
123 \lstset{basicstyle=\small,
124   numbers=left,
125   numberstyle=\tiny,
126   stepnumber=1,
127   numbersep=2pt, 
128   frame=TB,
129   framesep=5pt,
130 %  xleftmargin=0.3cm,
131   basicstyle=\ttfamily,
132   keywordstyle=\color{blue}\ttfamily,
133   ndkeywordstyle=\color{yellow}\ttfamily,
134 %  rdkeywordstyle=\ttfamily,
135   identifierstyle=\ttfamily,
136   commentstyle=\color{red}\ttfamily,
137   stringstyle=\color{green}\ttfamily,
138 %  texcsststyle=\ttfamily,
139   directivestyle=\color{magenta}\ttfamily
140
141
142 % distance from margins for boxedminipage
143 %\fboxsep=6pt
144
145 \part{Programmazione di sistema}
146 \label{part:progr-di-sist}
147 \include{intro}
148 \include{process}
149 \include{prochand}
150 \include{fileintro}
151 \include{filedir}
152 \include{fileunix}
153 \include{filestd}
154 \include{system}
155 \include{signal}
156 \include{session}
157 \include{fileadv}
158 \include{ipc}
159 \include{thread}
160
161 % Commentare sotto se si genera la prima parte
162 \part{Programmazione di rete}
163 \label{part:progr-di-rete}
164
165 \include{network}
166 \include{socket}
167 \include{tcpsock}
168 \include{sockctrl}
169 \include{othersock}
170 \include{sockadv}
171 \appendix
172
173 \part{Appendici}
174 \label{part:appendici}
175 \include{netlayer}
176 \include{trasplayer}
177 \include{errors}
178 \include{build}
179 \include{ringraziamenti}
180 \include{fdl}
181
182 % at the end put the bibliography
183 \backmatter
184
185 %\bibliographystyle{phaip}
186 %\bibliography{biblio}
187 \printindex
188
189 \bibliographystyle{ieeetr}
190 \bibliography{biblio}
191
192 \end{document}