% Copyright 2008,2009 Neil Williams <codehelp@debian.org>
%
% This document is free software; you can redistribute it and/or modify
% it under the terms of the GNU General Public License as published by
% the Free Software Foundation; either version 3 of the License, or
% (at your option) any later version.
%
% This program is distributed in the hope that it will be useful,
% but WITHOUT ANY WARRANTY; without even the implied warranty of
% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
% GNU General Public License for more details.
%
% You should have received a copy of the GNU General Public License
% along with this program.  If not, see http://www.gnu.org/licenses/

\documentclass{beamer}

\mode<presentation>
{
  \usetheme{Emdebian}
  \usecolortheme{emdebian}
}
\usepackage[english]{babel}

\usepackage[latin1]{inputenc}

\title{TDebs}
\subtitle{A guide to the Draft TDeb Specification.}
\author{Neil Williams}
\date{\today}

\begin{document}

\frame{\titlepage}

\section{Background}
\subsection{Introduction}
\frame
{
	\frametitle{Introduction}
	\par Translation packages contain all localisation data for one source
	package and are designed to help solve several problems in Debian:
	\begin{itemize}
	\item<2-> Translation updates should not require a source rebuild, either
	by the maintainer or as an NMU.
	\item<3-> Localisation data should not be distributed in architecture
	dependent packages.
	\item<4-> Translators should have a common interface for getting updates
	into Debian (possibly with automated TDeb generation after i18n team
	review).
	\end{itemize}
}

\section {Timescale}
\subsection{Work so far}
\frame
{
	\frametitle{Work so far}
	\par TDebs have been debated and discussed for several years with various
	methods proposed. The Draft TDeb Specification borrows from established
	methods from the embedded world.
	\begin{itemize}
	\item<2-> 2006 - Debian i18n meeting in Extremadura sets out the problem
	and initial ideas.
	\item<3-> DebConf7 - more ideas and discussion.
	\item<4-> DebConf8 - overview agreed between i18n and ftp-master.
	\item<5-> 2008 - Debian i18n/ftpmaster meeting in Extremadura prepares
	the Draft TDeb Specification.
	\item<6-> 2008 - Emdebian implements modified TDebs with
	extra features for embedded usage.
	\item<7-> 2009 - Lenny release allows work to start on preparing the
	Debian toolset to work with the Draft TDeb Specification.
	\end{itemize}
}

\section{Specification}
\subsection{Chapter 1}
\frame
{
	\frametitle{TDeb format}
	\begin{itemize}
	\item<1-> The binary package format is a variation of the deb binary package
	format. It has the same structure as deb, but the (single) data member is
	replaced by bzip2-compressed members for each LOCALE\_ROOT supported.
	\item<2-> The members following the control.tar.bz2 are named 
	t.\$\{LOCALE\_ROOT\}.tar.bz2
	\item<3-> LOCALE\_ROOT must match the regular expression [a-z]\{2,3\} 
	\item<4-> e.g. Locale: pt\_BR Locale Root: pt
	\item<5-> Emdebian currently implements 98 locale roots.
	\item<6-> Future development can support isolating individual locales
	from a set of packages without installing unsupported localisation data.
	\end{itemize}
}
\subsection{Chapter 2}
\frame
{
	\frametitle{Source format: +t1.diff.gz}
	\par TDebs will use a supplementary diff.gz for translation updates.
	\begin{itemize}
	\item<1-> Isolate changes to translations from the rest of the source package
	\item<2-> No changes will be allowed in the package binaries or 
	untranslated content.
	\item<3-> Uploads by Debian maintainers are assumed to be t0.
	\item<4-> During the transition to TDebs, +t1 uploads will be able to close
	[i18n] bugs assigned to the source package. After Squeeze, i18.debian.org
	will take over translation tracking.
	\end{itemize}
}
\subsection{Chapter 3}
\frame
{
	\frametitle{Contents}
	\par There is room for further discussion about whether and how much
	untranslated content can or should be in a TDeb. Generally, a TDeb will
	(eventually) contain:
	\begin{itemize}
	\item<1-> Translations from upstream - /usr/share/locale/*/LC\_MESSAGES/*.mo
	\item<2-> Other localisation files from upstream - /usr/share/locale/*/LC\_*/*
	\item<3-> Debconf templates file
	\item<4-> Translated content, including translated manpages, translated 
	documentation
	\item<5-> Packages with large amounts of translated documentation and 
	debconf templates would create two tdebs, one minimal tdeb for debconf and 
	one for the rest.
	\item<6-> Not the config or other related scripts. The regular deb will 
	need to contain a untranslated copy of the templates file, too.
	\end{itemize}
}
\subsection{Chapter 6}
\frame
{
	\frametitle{TDebs and package source}
	\begin{itemize}
	\item<1-> LINGUAS is an upstream file (often implemented as a variable
	within configure.ac or configure.in). Changes lead to a source rebuild.
	\item<2-> TDeb generation avoids LINGUAS and processes all
	.po files in all po-?*/ directories. Packages will no longer be able to have
	unactivated or unused translations.
	\item<3-> Current code for generating TDebs needs to be extended to cope with
	non-gettext translations, where possible.
	\item<4-> Translated packages do not need to make changes to generate TDebs
	until after the release of Squeeze but splitting l10n data into separate
	Arch: all .deb packages can be done beforehand.
	\end{itemize}
}

\section{ToDo list}
\subsection{What needs to be done and when}
\frame
{
	\frametitle{During Squeeze}
	\begin{itemize}
	\item<1-> Archive and tools support
	\item<2-> tdeb binary file definition - (ratification and review)
	\item<3-> tdeb source file definition - (development and testing)
	incorporate the tdiff and improve dpkg-source building support.
	\item<4-> debhelper support for both tdebs explicitly, and also
	marking files into classes in general (partially implemented via
	dh\_gentdeb in git)
	\item<5-> provide a patch to cdbs for running dh\_gentdeb in the right
	place. (Done - only remains for the patch to be filed and applied, after Lenny).
	\item<6-> apt and aptitude support for pulling in and removing tdebs
	(ensure TDeb is accessible to apt-extracttemplates).
	\item<7-> debdiff and other devscripts support (debc)
	\item<8-> dak support (run away, run away) run faster
	\item<9-> lintian support
	\end{itemize}
}
\frame
{
	\frametitle{After Squeeze}
	\begin{itemize}
	\item<1-> Convert debconf translation into the first TDebs (Squeeze + 1)
	\item<2-> dpkg class support - (make it easier to selectively install
	translations for specific locale roots).
	\item<3-> Support packages using non-gettext translations. Packages 
	using non-gettext mechanisms include OOo, mozilla, Qt or Java properties, 
	menus, desktop.)
	\item<4-> Convert native packages with program translations
	to using TDebs (Squeeze + 1 or possibly later)
	\item<5-> Convert non-native packages with Debian maintainers who are
	also the upstream.
	\item<6-> Convert non-gettext packages and non-native packages where
	the Debian maintainer is not part of the upstream. (Squeeze +2?)
	\end{itemize}
}

\section{Changes in packages}
\subsection{Modifications}
\frame
{
	\frametitle{Modifications}
	\par Maintainers will need to make a variety of changes to support TDebs:
	\begin{itemize}
	\item<1-> Replaces - Add the recommended \$src-tdeb package name with
	Replaces: \$binaries ($<<$ \$srcversion) where \$srcversion is a fixed
	string for the version prior to TDebs
	\item<1-> e.g. Replaces: apt ($<<$ 0.7.19), apt-utils ($<<$ 0.7.19)
	\item<2-> Remove translated content from all *.install files in debian/
	\item<3-> Remove any lines in debian/rules that handle translated content
	\item<4-> Ensure that dh\_gentdeb is called in debian/rules (CDBS will be
	patched to implement this support automatically).
	\end{itemize}
}

\section{People}
\subsection{Thanks}
\frame
{
	\frametitle{Thanks}
	\par http://www.emdebian.org/
	\par Many individuals :
	Joerg Jaspert, Thomas Viehmann, Mark Hymers, Frank Lichtenheld,
	Christian Perrier, Stephen Gran, Luk Claes, EddyPetrisor,
	Steve McIntyre, Jonathan McDowell, Moray Allan, Aurelien Jarno 
	\par and anyone I might have forgotten.
}

\end{document}
