GitPackaging » Historique » Version 18
Daniel Dehennin, 06/02/2012 09:32
Branche par défaut dans eolepack
1 | 6 | Daniel Dehennin | {{toc}} |
---|---|---|---|
2 | 6 | Daniel Dehennin | |
3 | 1 | Daniel Dehennin | h1. Gestion des paquets EOLE |
4 | 1 | Daniel Dehennin | |
5 | 17 | Daniel Dehennin | h2. Séparation du code et du packaging |
6 | 17 | Daniel Dehennin | |
7 | 17 | Daniel Dehennin | Cela facilite le travail de tout le monde, aussi bien des développeurs que des packageurs. |
8 | 17 | Daniel Dehennin | |
9 | 17 | Daniel Dehennin | De plus, il est ainsi plus facile de fournir le même code pour plusieurs distributions différentes, cela sera utile notamment lors du portage des applications sur "Precise Pangolin":http://fr.wikipedia.org/wiki/Liste_des_versions_d%27Ubuntu#Ubuntu_12.04_LTS_.28Precise_Pangolin.29 |
10 | 17 | Daniel Dehennin | |
11 | 17 | Daniel Dehennin | h3. Le développement dans @master@ |
12 | 17 | Daniel Dehennin | |
13 | 17 | Daniel Dehennin | Ainsi, les développeurs ne sont pas gênés par le packaging, en particulier les changements sur @debian/changelog@ à chaque compilation de paquet. |
14 | 17 | Daniel Dehennin | |
15 | 17 | Daniel Dehennin | |
16 | 17 | Daniel Dehennin | h3. Le packaging dans @dist/<VENDOR>/<DISTRIBUTION>/master@ |
17 | 17 | Daniel Dehennin | |
18 | 17 | Daniel Dehennin | Afin de faire un paquet, il faut intégrer la branche de développement souhaitée, par exemple: |
19 | 17 | Daniel Dehennin | |
20 | 17 | Daniel Dehennin | <pre> |
21 | 17 | Daniel Dehennin | buildd@build:~/src/eole-debsums(master)$ git checkout dist/ubuntu/lucid/master |
22 | 17 | Daniel Dehennin | buildd@build:~/src/eole-debsums(dist/ubuntu/lucid/master)$ git merge master |
23 | 1 | Daniel Dehennin | </pre> |
24 | 18 | Daniel Dehennin | |
25 | 18 | Daniel Dehennin | La branche par défaut dans eolepack est modifiée pour être @dist/ubuntu/lucid/master@. |
26 | 17 | Daniel Dehennin | |
27 | 2 | Daniel Dehennin | h2. Environnement de compilation personnel |
28 | 2 | Daniel Dehennin | |
29 | 2 | Daniel Dehennin | Il existe plusieurs outils afin de mettre en place des environnements de compilation personnels. |
30 | 15 | Daniel Dehennin | |
31 | 2 | Daniel Dehennin | L’outil utilisé dans le projet "Debian":http://www.debian.org se nomme "sbuild":http://wiki.debian.org/sbuild. |
32 | 1 | Daniel Dehennin | |
33 | 17 | Daniel Dehennin | Ce système peut se reposer sur un système de snapshot : on installe un système de base, propre, et la compilation se fait dans un snapshot temporaire de ce système. |
34 | 2 | Daniel Dehennin | |
35 | 1 | Daniel Dehennin | Cela permet de lancer des compilations en parallèles au besoin. |
36 | 2 | Daniel Dehennin | |
37 | 17 | Daniel Dehennin | Deux méthodes sont utilisables pour la mise en place des snapshots : |
38 | 14 | Daniel Dehennin | |
39 | 14 | Daniel Dehennin | * [[eole:GitPackagingSbuildLVM|avec LVM]] |
40 | 1 | Daniel Dehennin | * [[eole:GitPackagingSbuildBtrfs|avec le système de fichier btrfs]] |
41 | 14 | Daniel Dehennin | |
42 | 14 | Daniel Dehennin | |
43 | 17 | Daniel Dehennin | Lorsque les schroots sont en place et sbuild configuré, la compilation d’un paquet peut se dérouler comme suit : |
44 | 14 | Daniel Dehennin | |
45 | 14 | Daniel Dehennin | <pre> |
46 | 3 | Daniel Dehennin | buildd@build:~/src$ sudo apt-get install git-core git-buildpackage fakeroot build-essential debhelper cdbs |
47 | 16 | Daniel Dehennin | buildd@build:~/src$ git clone http://dev-eole.ac-dijon.fr/git/eole-debsums |
48 | 16 | Daniel Dehennin | buildd@build:~/src$ cd eole-debsums |
49 | 16 | Daniel Dehennin | buildd@build:~/src/eole-debsums$ git checkout -b dist/ubuntu/lucid/build origin/dist/ubuntu/lucid/master |
50 | 16 | Daniel Dehennin | buildd@build:~/src/eole-debsums$ git buildpackage --git-builder="sbuild -A -d eole-2.3-dev" --git-cleaner=/bin/true |
51 | 16 | Daniel Dehennin | </pre> |
52 | 16 | Daniel Dehennin | |
53 | 16 | Daniel Dehennin | Ou si on souhaite minimiser les paquets à installer: |
54 | 16 | Daniel Dehennin | |
55 | 16 | Daniel Dehennin | <pre> |
56 | 16 | Daniel Dehennin | buildd@build:~/src$ sudo apt-get install git-core git-buildpackage dpkg-dev |
57 | 16 | Daniel Dehennin | buildd@build:~/src$ git clone http://dev-eole.ac-dijon.fr/git/eole-debsums |
58 | 16 | Daniel Dehennin | buildd@build:~/src$ cd eole-debsums |
59 | 16 | Daniel Dehennin | buildd@build:~/src/eole-debsums$ git checkout -b dist/ubuntu/lucid/build origin/dist/ubuntu/lucid/master |
60 | 16 | Daniel Dehennin | buildd@build:~/src/eole-debsums$ git buildpackage --git-builder="dpkg-buildpackage -nc -d -S" --git-cleaner=/bin/true |
61 | 16 | Daniel Dehennin | buildd@build:~/src/eole-debsums$ sbuild -A -d eole-2.3-dev ../eole-debsums_20111207-eole1.dsc |
62 | 16 | Daniel Dehennin | </pre> |
63 | 16 | Daniel Dehennin | |
64 | 13 | Daniel Dehennin | h1. Webographie |
65 | 7 | Daniel Dehennin | |
66 | 11 | Daniel Dehennin | * "PackagingGuide/Python":https://wiki.ubuntu.com/PackagingGuide/Python |