source: pkgmngt/packageManager.xml.dpkg@ d607ac3

2.4 ablfs-more legacy new_features trunk
Last change on this file since d607ac3 was bd00951, checked in by Pierre Labastie <pierre@…>, 10 years ago

Add pacman as package manager.

  • Property mode set to 100644
File size: 10.7 KB
RevLine 
[7072e1f]1<?xml version="1.0" encoding="UTF-8"?>
[4c6f54f]2<!-- $Id$ -->
[7072e1f]3<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
4 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
5<!ENTITY buildtime "Approximate build time">
6<!ENTITY diskspace "Required disk space">
7<!ENTITY dependencies "Installation depends on">
8<!ENTITY testsuites "Test suite depends on">
9<!ENTITY before "Must be installed before">
10<!ENTITY external "Optional dependencies">
11<!ENTITY debian-pool "http://ftp2.fr.debian.org/debian/pool/main/">
[b9c3497]12<!ENTITY dpkg-version "1.17.22">
13<!ENTITY dpkg-size "4,259 KB">
14<!ENTITY dpkg-url "&debian-pool;d/dpkg/dpkg_&dpkg-version;.tar.xz">
15<!ENTITY dpkg-md5 "c9c46c5318c98c9162fbd03d24f2f95b">
[7072e1f]16<!ENTITY dpkg-home "http://wiki.debian.org/Teams/Dpkg">
[b9c3497]17<!ENTITY dpkg-ch5-du "54 MB">
18<!ENTITY dpkg-ch5-sbu "0.3 SBU">
19<!ENTITY dpkg-ch6-du "63 MB">
20<!ENTITY dpkg-ch6-sbu "0.5 SBU">
[7072e1f]21]>
22<article>
23
24<sect1 id="package">
25 <?dbhtml filename="packages.html"?>
26
27 <title>All Packages</title>
28
29 <para>Download or otherwise obtain the following packages:</para>
30
31 <variablelist role="materials">
32
33 <varlistentry>
34 <term>Dpkg (&dpkg-version;) - <token>&dpkg-size;</token>:</term>
35 <listitem>
36 <para>Home page: <ulink url="&dpkg-home;"/></para>
37 <para>Download: <ulink url="&dpkg-url;"/></para>
38 <para>MD5 sum: <literal>&dpkg-md5;</literal></para>
39 </listitem>
40 </varlistentry>
41
42 </variablelist>
43
44</sect1>
45<!-- If needed, uncomment and edit this:
46<sect1 id="patches">
47 <?dbhtml filename="patches.html"?>
48
49 <title>Needed Patches</title>
50
51 <para>In addition to the package(s), zero or more patches are also required.
52 These patches correct any mistakes in the packages that should be
53 fixed by the maintainer. The patches also make small modifications to
54 make the packages easier to work with. The following patches will be
55 needed to build an LFS system:</para>
56
57 <variablelist role="materials">
58
59 <varlistentry>
60 <term>Dpkg Some Patch - <token>&dpkg-somepatche-size;</token>:</term>
61 <listitem>
62 <para>Download: <ulink url="&somepatch-url;"/></para>
63 <para>MD5 sum: <literal>&somepatch-md5;</literal></para>
64 </listitem>
65 </varlistentry>
66
67 </variablelist>
68
69</sect1>
70-->
71
72<sect1 id="ch-tools-pkgmngt" role="wrap">
73 <?dbhtml filename="dpkg.html"?>
74
75 <sect1info condition="script">
76 <productname>dpkg</productname>
77 <productnumber>&dpkg-version;</productnumber>
78 <address>&dpkg-url;</address>
79 </sect1info>
80
81 <title>Dpkg-&dpkg-version;</title>
82
83 <sect2 role="package">
84 <title/>
85
86 <para>This is my choice of package manager. Dpkg is the basic package
87 manager of Debian. It can be complemented by deselect (in the same
88 package), apt or aptitude. We use it in a very crude way.</para>
[bd00951]89
[7072e1f]90 <segmentedlist>
91 <segtitle>&buildtime;</segtitle>
92 <segtitle>&diskspace;</segtitle>
93
94 <seglistitem>
95 <seg>&dpkg-ch5-sbu;</seg>
96 <seg>&dpkg-ch5-du;</seg>
97 </seglistitem>
98 </segmentedlist>
99
100 </sect2>
101
102 <sect2 role="installation">
103 <title>Installation of Dpkg</title>
104
105 <para>Since Debian is shipping its own package, all patches have already
[b9c3497]106 been applied. Nevertheless there is either a bug or something
107 I do not understand... Apply this:</para>
[7072e1f]108
[b9c3497]109 <screen><userinput remap="pre">sed -i '/compress_filter(s/,/va_start/s/^$/compressor_fixup_params(params);\n/' lib/dpkg/compress.c</userinput></screen>
[7072e1f]110
111 <para> Configure the package:</para>
112
113 <screen><userinput remap="configure">./configure --prefix=/tools \
[b9c3497]114 --disable-nls --disable-dselect \
115 --disable-start-stop-daemon \
116 --disable-update-alternatives \
117 --without-zlib --with-liblzma=static --without-selinux</userinput></screen>
[7072e1f]118
119 <variablelist>
120 <title>The meaning of the configure options:</title>
121
122 <varlistentry>
[b9c3497]123 <term><parameter>--disable-dselect</parameter></term>
[7072e1f]124 <listitem>
125 <para>Avoids building <command>dselect</command>, an
126 awful thing!</para>
127 </listitem>
128 </varlistentry>
129
130 <varlistentry>
[b9c3497]131 <term><parameter>--disable-start-stop-daemon</parameter></term>
[7072e1f]132 <listitem>
133 <para>The utility <command>start-stop-daemon</command>
134 is not needed here.</para>
135 </listitem>
136 </varlistentry>
137
138 <varlistentry>
[b9c3497]139 <term><parameter>--disable-update-alternatives</parameter></term>
[7072e1f]140 <listitem>
141 <para>Same for <command>update-alternatives</command>.</para>
142 </listitem>
143 </varlistentry>
144
145 <varlistentry>
[b9c3497]146 <term><parameter>--without-zlib</parameter></term>
[7072e1f]147 <listitem>
[b9c3497]148 <para>Use <command>gzip</command> for compression of binary
149 packages instead of the zlib library, which is not installed
150 in chapter 5.</para>
151 </listitem>
152 </varlistentry>
153
154 <varlistentry>
155 <term><parameter>--with-liblzma=static</parameter></term>
156 <listitem>
157 <para>Use statically linked <command>liblzma</command> for compression
158 of binary packages.</para>
159 </listitem>
160 </varlistentry>
161
162 <varlistentry>
163 <term><parameter>--without-selinux</parameter></term>
164 <listitem>
165 <para>Disable building for <application>selinux</application>, which
166 is not used woth LFS/BLFS.</para>
[7072e1f]167 </listitem>
168 </varlistentry>
169
170 </variablelist>
171
172 <para>Compile the package:</para>
173
174 <screen><userinput remap="make">(cd lib &amp;&amp; make)
175(cd src &amp;&amp; make)
176(cd dpkg-deb &amp;&amp; make)
177(cd dpkg-split &amp;&amp; make)</userinput></screen>
178
179 <para>This package does not come with a test suite.</para>
180
181 <para>Install only the needed files:</para>
182
183 <screen><userinput remap="install">cp src/dpkg src/dpkg-* /tools/bin
184cp dpkg-deb/dpkg-deb /tools/bin
185cp dpkg-split/dpkg-split /tools/bin
186mkdir -pv /tools/etc/dpkg/{,dpkg.cfg.d}
187cp debian/dpkg.cfg /tools/etc/dpkg</userinput></screen>
188
189 <para>Add a line in <filename>dpkg.cfg</filename> to
190 tell where to put administration files</para>
191
192 <screen><userinput>cat &gt;&gt; /tools/etc/dpkg/dpkg.cfg &lt;&lt; EOF
193# admindir on LFS system
194admindir /var/lib/dpkg
195EOF</userinput></screen>
196
197 <para>On a Debian system, <command>dpkg</command> relies on two other
198 files to be present. Since we do not install them, issue:</para>
199
200 <screen><userinput>cat &gt;&gt; /tools/etc/dpkg/dpkg.cfg &lt;&lt; EOF
201# disable fatal error on path checking
202force-bad-path
203EOF</userinput></screen>
204
205 </sect2>
206
207</sect1>
208
[575bcf3]209<sect1 id="ch-pkgmngt-creatingdirs">
[7072e1f]210 <?dbhtml filename="creatingdirs.html"?>
211
212 <title>Adding Directories for package management</title>
213
214 <para>Those directories should be added to the system.
215 <filename>/var/lib/dpkg</filename> and subdirectories are
216 adminitrative directories of <command>dpkg</command>.
217 <filename>/var/log</filename> is the log directory for
218 <command>dpkg</command>. <filename>/var/lib/packages</filename>
219 will be used to store our packages.deb files.</para>
220
221 <screen><userinput>mkdir -pv /var/{log,lib/dpkg/{info,updates}}
222mkdir -pv /var/lib/packages</userinput></screen>
223
224</sect1>
225
[575bcf3]226<sect1 id="ch-pkgmngt-createfiles">
[7072e1f]227 <?dbhtml filename="createfiles.html"?>
228
229 <title>Adding administrative files for Dpkg</title>
230 <para><command>dpkg</command> needs that some files exist to run
231 for the first time. The log file must exist in order to be
232 used.</para>
233
234 <screen><userinput>touch /var/lib/dpkg/{available,status}
235touch /var/log/dpkg.log</userinput></screen>
236
237</sect1>
238
239<sect1 id="ch-system-pkgmngt" role="wrap">
240 <?dbhtml filename="dpkg.html"?>
241
242 <sect1info condition="script">
243 <productname>dpkg</productname>
244 <productnumber>&dpkg-version;</productnumber>
245 <address>&dpkg-url;</address>
246 </sect1info>
247
248 <title>Dpkg-&dpkg-version;</title>
249
250 <sect2 role="package">
251 <title/>
252
253 <para>This is my choice of package manager. Dpkg is the basic package
254 manager of Debian. It can be complemented by deselect (in the same
255 package), apt or aptitude. We use it in a very crude way.</para>
[bd00951]256
[7072e1f]257 <segmentedlist>
258 <segtitle>&buildtime;</segtitle>
259 <segtitle>&diskspace;</segtitle>
260
261 <seglistitem>
262 <seg>&dpkg-ch6-sbu;</seg>
263 <seg>&dpkg-ch6-du;</seg>
264 </seglistitem>
265 </segmentedlist>
266
267 </sect2>
268
269 <sect2 role="installation">
270 <title>Installation of Dpkg</title>
271
272 <para>Since Debian is shipping its own package, all patches have already
[b9c3497]273 been applied. We do not need more in chapter 6. Configure it:</para>
[7072e1f]274
275 <screen><userinput remap="configure">./configure --prefix=/usr \
276 --sysconfdir=/etc \
277 --localstatedir=/var \
[b9c3497]278 --disable-dselect \
279 --disable-start-stop-daemon \
280 --disable-update-alternatives \
[7072e1f]281 --without-selinux</userinput></screen>
282
283 <variablelist>
284 <title>The meaning of the configure options:</title>
285
286 <varlistentry>
[b9c3497]287 <term><parameter>--disable-dselect</parameter></term>
[7072e1f]288 <listitem>
289 <para>Avoids building <command>dselect</command>, an
290 awful thing!</para>
291 </listitem>
292 </varlistentry>
293
294 <varlistentry>
[b9c3497]295 <term><parameter>--disable-start-stop-daemon</parameter></term>
[7072e1f]296 <listitem>
297 <para>The utility <command>start-stop-daemon</command>
298 is not needed here.</para>
299 </listitem>
300 </varlistentry>
301
302 <varlistentry>
[b9c3497]303 <term><parameter>--disable-update-alternatives</parameter></term>
[7072e1f]304 <listitem>
305 <para>Same for <command>update-alternatives</command>.</para>
306 </listitem>
307 </varlistentry>
308
309 <varlistentry>
[b9c3497]310 <term><parameter>--without-selinux</parameter></term>
[7072e1f]311 <listitem>
[b9c3497]312 <para>Selinux is not used in LFS.</para>
[7072e1f]313 </listitem>
314 </varlistentry>
315
316 </variablelist>
317
318 <para>Compile the package:</para>
319
320<screen><userinput remap="make">make</userinput></screen>
321
322 <para>This package does not come with a test suite.</para>
323
324 <para>Install the package:</para>
325
326<screen><userinput remap="install">mkdir -pv $PKG_DEST
327make DESTDIR=$PKG_DEST install
328mkdir -pv $PKG_DEST/etc/dpkg/{,dpkg.cfg.d}
329cp debian/dpkg.cfg $PKG_DEST/etc/dpkg</userinput></screen>
330
331 <para>Add a line in <filename>dpkg.cfg</filename> to
332 tell where to put administration files</para>
333
334<screen><userinput remap="install">cat &gt;&gt; $PKG_DEST/etc/dpkg/dpkg.cfg &lt;&lt; EOF
335# admindir on LFS system
336admindir /var/lib/dpkg
337EOF</userinput></screen>
338
339<!-- Is this needed in chapter 06 -->
340 <para>On a Debian system, <command>dpkg</command> relies on two other
341 files (<command>ldconfig</command> and maybe <command>update-rc.d</command>)
342 to be present. Since we do not install them, issue:</para>
343
344<screen><userinput>cat &gt;&gt; /etc/dpkg/dpkg.cfg &lt;&lt; EOF
345# disable fatal error on path checking
346force-bad-path
347EOF</userinput></screen>
348
349 </sect2>
350
351</sect1>
352</article>
Note: See TracBrowser for help on using the repository browser.