6ba4a3369c2c983347bb183b9ef1e1b475fe4971
[packaging-tutorial.git] / packaging-tutorial.tex
1 \documentclass[10pt,final]{beamer}
2 \mode<presentation>
3 \usetheme{lucasdeb}
4 \usepackage{paralist}
5 \usepackage{wasysym}
6 \definecolor{darkgreen}{rgb}{0,.7,0}
7 \definecolor{darkred}{rgb}{.7,0,0}
8 \newcommand{\Smiley}{{\color{darkgreen}\smiley}}
9 \newcommand{\Frownie}{{\color{darkred}\frownie}}
10 \usepackage[french]{babel}
11 \usepackage[utf8]{inputenc}
12 \usepackage{helvet}
13 \usepackage[OT1]{fontenc}
14 \usepackage{xspace}
15 \usepackage{verbatim}
16 \usepackage{comment}
17 \usepackage{tabularx}
18 \usepackage{listings}
19 \lstset{basicstyle=\ttfamily}
20 \beamertemplatetransparentcovereddynamic
21 \setbeamercovered{invisible}
22 \newcommand{\br}{\vskip 1em}
23 \newcommand{\hbr}{\vskip 0.5em}
24 \newcommand{\hhbr}{\vskip 0.25em}
25 \newcommand{\Arr}{\textbf{$\Rightarrow$}\xspace}
26 \newcommand{\arr}{\textbf{$\rightarrow$}\xspace}
27 \newcommand{\fixme}[1]{ {\color{red}\footnotesize\bf #1}}
28 \usepackage{listings}
29
30 \renewcommand{\ttdefault}{aett}
31 \usepackage{aecompl}
32
33 \newcommand{\pedp}{\NoAutoSpaceBeforeFDP}
34
35 \usebackgroundtemplate{\includegraphics[width=\paperwidth]{figs/dslide8.pdf}}
36 \logo{\includegraphics[viewport=274 335 360 440,width=0.5cm]{figs/openlogo-nd.pdf}}
37 \hypersetup{pdftitle={An Introduction to Debian Packaging},bookmarks}
38 \title{An Introduction to Debian Packaging}
39 \author[]{Lucas Nussbaum\\{\small\texttt{lucas@debian.org}}}
40 \institute{\includegraphics[viewport=274 335 360 440,width=1cm]{figs/openlogo-nd.pdf}}
41 \date{}
42
43 \newcommand{\nospace}[1]{{\NoAutoSpaceBeforeFDP{}#1}}%
44
45 \begin{document}
46
47 \frame{\titlepage}
48
49 \section{Introduction}
50 \subsection{About this document}
51 \begin{frame}
52 \frametitle{About this document}
53
54 Copyright \copyright 2011 Lucas Nussbaum -- lucas@debian.org
55 \br
56
57 {\small 
58 This document is free software: you can redistribute it and/or modify
59 it under either (at your option):
60 \begin{itemize}
61 \item the terms of the GNU General Public License as published by
62     the Free Software Foundation, either version 3 of the License, or
63     (at your option) any later version.\\
64     \url{http://www.gnu.org/licenses/gpl.html}
65     \hbr
66 \item the terms of the Creative Commons Attribution-ShareAlike 3.0 Unported License.\\
67         \url{http://creativecommons.org/licenses/by-sa/3.0/}
68 \end{itemize}
69 }
70
71 \br
72 \fixme{Add pointer to website / git repo}
73 \end{frame}
74
75 \subsection{The Deb package format}
76 \begin{frame}[fragile]
77         \frametitle{Introduction: the Deb package format}
78 \begin{itemize}
79         \item One of the two most common packages format (with RPM)
80         \item Used by Debian and its derivatives (including Ubuntu)
81         \item A very powerful and convenient way to distribute software to users
82                 \pause
83         \item \texttt{.deb} file: an \texttt{ar} archive
84 \begin{lstlisting}[basicstyle=\ttfamily\footnotesize]
85 $ ar tv wget_1.12-2.1_i386.deb
86 rw-r--r-- 0/0      4 Sep  5 15:43 2010 debian-binary
87 rw-r--r-- 0/0   2403 Sep  5 15:43 2010 control.tar.gz
88 rw-r--r-- 0/0 751613 Sep  5 15:43 2010 data.tar.gz
89 \end{lstlisting}
90 \begin{itemize}
91         \item \texttt{debian-binary}: version of the deb file format, \texttt{"2.0\textbackslash{}n"}
92         \item \texttt{control.tar.gz}: metadata about the package\\
93                 {\small \texttt{\textbf{control}, md5sums, (pre|post)(rm|inst), triggers, shlibs}, \ldots}
94         \item \texttt{data.tar.gz}: data files of the package
95 \end{itemize}
96                 \pause
97 \item You could create your \texttt{.deb} files manually\\
98         {\footnotesize \url{http://tldp.org/HOWTO/html\_single/Debian-Binary-Package-Building-HOWTO/}}
99 \item But most people don't do it that way
100 \end{itemize}
101 \hbr
102 \centerline{\textbf{This tutorial: create Debian packages, the Debian way}}
103 \end{frame}
104
105 \begin{frame}
106         \frametitle{Ideas dump}
107 \begin{itemize}
108 \item Tools you will need
109 \item General packaging workflow / source package - binary packages
110
111 \item Downloading the source
112 \item Creating a basic Debian source package
113 \item Debian source package -- files in debian/
114 \item Example: removing IPv6 support from wget
115 \item Debhelper7
116 \item CDBS
117 \item New source formats
118 \item Modifying the upstream source Patch systems
119 \item Per-language policies and packaging helpers
120 \item Maintainer scripts
121 \item Building packages -- dpkg-buildpackage pbuilder sbuild
122 \item Packaging with VCSes debcheckout debcommit debrelease git-buildpackage svn-buildpackage
123 \item Uploading debsign / dput -- private archive -- reprepro
124 \item Contributing the package to Debian and Ubuntu
125
126 \item Contributing new stuff vs adopting (WNPP, etc) vs co-maintaining
127 \end{itemize}
128 \end{frame}
129
130 \section{Links}
131 \begin{frame}{Links}
132
133 http://wiki.debian.org/IntroDebianPackaging
134 http://www.debian.org/devel/
135 http://www.debian.org/doc/debian-policy/
136 http://www.debian.org/doc/developers-reference/
137 http://www.debian.org/doc/maint-guide/
138 https://wiki.ubuntu.com/PackagingGuide
139 lp:ubuntu-packaging-guide
140 debian-mentors
141 mentors.debian.net
142 library packaging guide
143 debhelper 7 slides
144 \end{frame}
145
146 \end{document}