EoleDebianPackaging » Historique » Version 4
Version 3 (Daniel Dehennin, 28/06/2012 17:42) → Version 4/7 (Daniel Dehennin, 24/07/2012 15:52)
{{toc}}
h1. Introduction
Nous ne décrirons pas ici comment créer un paquet debian, mais
quelques règles utiles lors de la création d’un paquet debian pour
EOLE.
La principale cible de cette documentation est le packaging pour Ubuntu Precise Pangolin, mais des informations sont données pour Ubuntu Lucid Lynx lorsque cela est pertinant
h1. Considérations minimales pour un paquet Debian
h2. debian/control
h3. Source
h4. Version de packaging
https://launchpad.net/debian-policy
* Lucid : 3.8.4
* Precise : 3.9.3
h4. Dépendance de build minimale
h5. debhelper
https://launchpad.net/debhelper
* Lucid : 7.4
* Precise : 9
h4. URLs
* @Homepage: http://eole.orion.education.fr/diff/@
* @Vcs-Git: http://dev-eole.ac-dijon.fr/git/<PROJECT>@
* @Vcs-Browser: http://dev-eole.ac-dijon.fr/projects/<PROJECT>/repository@
h3. Binaire
h4. Architecture
* @all@ : Si un paquet ne contient aucun binaire compilé
* @any@ : Si un paquet contient au moins un fichier dépendant de l’architecture
h4. Dépendance minimal
Toujours ajouter @${misc:Depends}@ pour les outils debhelper.
h2. debian/compat
* Lucid : 7
* Precise : 9
h2. debian/rules
Depuis la version 7 des outils debhelper, le fichier debian/rules peut
être réduit, dans sa plus simple expression, à moins d’une dixaine de
lignes :
<pre>
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
# export DH_VERBOSE=1
%:
dh $@
</pre>
La commande dh appel tour à tour tous les debhelper, il n’est donc
plus nécessaire de les lister dans le debian/rules.
h2. debian/copyright
h3. Pour precise
<pre>
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Source: http://dev-eole.ac-dijon.fr/projects/<PROJET>
Files: *
Copyright: <COPYRIGHT YEARS> <COPYRIGHT HOLDER>
License: GPL-3+
License: GPL-3+
This program 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 package 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/>.
.
On Debian systems, the complete text of the GNU General
Public License version 3 can be found in "/usr/share/common-licenses/GPL-3".
</pre>
h1. Paquet python
h2. debian/control
h3. Source
Ajout de @python-all-dev@ en @Build-Depends@ :
* Lucid : >= 2.6.5-0ubuntu1
* Precise : >= 2.6.6-3
h3. Binaire
Ajout de @${python:Depends}@ en @Depends@
h2. debian/rules
h3. Pas de code twisted Precise
Ajouter le module python-support @dh_python2@ à la séquence debhelper : @debhelper@ pour du code
python2 et @dh_python3@ pour du code python3 :
<pre>
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
# export DH_VERBOSE=1
%:
dh $@ --with python-support python2
</pre>
h3. Lucid
h3. h4. Distribution d’un module zephir-client
Ajouter le module @python-central@ à la séquence de @build@ et forcer
l’utilisation de @dh_pycentral@ à cause de @twisted@ :
<pre>
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
# export DH_VERBOSE=1
%:
dh $@
# Force python-central for use with twisted
build:
dh build --with python-central
override_dh_pysupport:
dh_pycentral
.PHONY: build override_dh_pysupport
</pre>
h4. Pas de code twisted
Ajouter le module python-support à la séquence debhelper :
<pre>
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
# export DH_VERBOSE=1
%:
dh $@ --with python-support
</pre>
h1. Introduction
Nous ne décrirons pas ici comment créer un paquet debian, mais
quelques règles utiles lors de la création d’un paquet debian pour
EOLE.
La principale cible de cette documentation est le packaging pour Ubuntu Precise Pangolin, mais des informations sont données pour Ubuntu Lucid Lynx lorsque cela est pertinant
h1. Considérations minimales pour un paquet Debian
h2. debian/control
h3. Source
h4. Version de packaging
https://launchpad.net/debian-policy
* Lucid : 3.8.4
* Precise : 3.9.3
h4. Dépendance de build minimale
h5. debhelper
https://launchpad.net/debhelper
* Lucid : 7.4
* Precise : 9
h4. URLs
* @Homepage: http://eole.orion.education.fr/diff/@
* @Vcs-Git: http://dev-eole.ac-dijon.fr/git/<PROJECT>@
* @Vcs-Browser: http://dev-eole.ac-dijon.fr/projects/<PROJECT>/repository@
h3. Binaire
h4. Architecture
* @all@ : Si un paquet ne contient aucun binaire compilé
* @any@ : Si un paquet contient au moins un fichier dépendant de l’architecture
h4. Dépendance minimal
Toujours ajouter @${misc:Depends}@ pour les outils debhelper.
h2. debian/compat
* Lucid : 7
* Precise : 9
h2. debian/rules
Depuis la version 7 des outils debhelper, le fichier debian/rules peut
être réduit, dans sa plus simple expression, à moins d’une dixaine de
lignes :
<pre>
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
# export DH_VERBOSE=1
%:
dh $@
</pre>
La commande dh appel tour à tour tous les debhelper, il n’est donc
plus nécessaire de les lister dans le debian/rules.
h2. debian/copyright
h3. Pour precise
<pre>
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Source: http://dev-eole.ac-dijon.fr/projects/<PROJET>
Files: *
Copyright: <COPYRIGHT YEARS> <COPYRIGHT HOLDER>
License: GPL-3+
License: GPL-3+
This program 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 package 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/>.
.
On Debian systems, the complete text of the GNU General
Public License version 3 can be found in "/usr/share/common-licenses/GPL-3".
</pre>
h1. Paquet python
h2. debian/control
h3. Source
Ajout de @python-all-dev@ en @Build-Depends@ :
* Lucid : >= 2.6.5-0ubuntu1
* Precise : >= 2.6.6-3
h3. Binaire
Ajout de @${python:Depends}@ en @Depends@
h2. debian/rules
h3. Pas de code twisted Precise
Ajouter le module python-support @dh_python2@ à la séquence debhelper : @debhelper@ pour du code
python2 et @dh_python3@ pour du code python3 :
<pre>
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
# export DH_VERBOSE=1
%:
dh $@ --with python-support python2
</pre>
h3. Lucid
h3. h4. Distribution d’un module zephir-client
Ajouter le module @python-central@ à la séquence de @build@ et forcer
l’utilisation de @dh_pycentral@ à cause de @twisted@ :
<pre>
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
# export DH_VERBOSE=1
%:
dh $@
# Force python-central for use with twisted
build:
dh build --with python-central
override_dh_pysupport:
dh_pycentral
.PHONY: build override_dh_pysupport
</pre>
h4. Pas de code twisted
Ajouter le module python-support à la séquence debhelper :
<pre>
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
# export DH_VERBOSE=1
%:
dh $@ --with python-support
</pre>