source: pkgmngt/packageManager.xml.template@ 5a965ad

ablfs-more legacy trunk
Last change on this file since 5a965ad was 49f8b03, checked in by Pierre Labastie <pierre@…>, 4 years ago

Fix package management for new book, and add a patch for porg

  • Property mode set to 100644
File size: 8.9 KB
RevLine 
[4c6f54f]1<!-- $Id$ -->
[7072e1f]2<!-- Mandatory header for xml files change encoding to the one
3you use on your computer -->
4<?xml version="1.0" encoding="UTF-8"?>
5<!-- Mandatory DOCTYPE declaration. Fill free to add entities,
6but no external entities in local files, since they would not
7be accessible from JHALFSDIR. Change the document type `article' to
8book if you prefer. That slightly changes the aspect if you render
9it in html -->
10<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
11 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" >
12
13<!-- The first markup should be the one defined in the DOCTYPE DECLARATION -->
14<article>
15
16<!-- First section for the tarball download address.
17Only the next four lines are mandatory, but you can add anything
18to make the text look more like the LFS book.
[49f8b03]19You can add several packages (see packageManager.xml.pacman)
[7072e1f]20Do not change anything, except the url and the md5 checksum. -->
21<sect1 id="package">
22 <para>Download: <ulink url="http://your/package-manager/url"/></para>
23 <para>MD5 sum: <literal>package-md5-checksum</literal></para>
24</sect1>
25
26<!-- If needed, uncomment and edit this:
27<sect1 id="patches">
28 <para>Download: <ulink url="somepatch-url"/></para>
29 <para>MD5 sum: <literal>somepatch-md5</literal></para>
30</sect1>
31-->
32
[49f8b03]33<!-- We have three groups of sections with installation instructions:
34 - the one with id ch-tools-xxx is for old book, where
35 the package manager (and its needed deps) is built as user
36 lfs in /tools
37 - the one with id ch-chroot-xxx is for new book, where the
38 package manager (and its needed deps) is built temporarily
39 in chroot
40 - the one with id ch-system-xxx is for both book, when the
41 package manager (and its deps) is rebuilt with instructions
42 to make a package of it.
43
44 Do not change the next line, except the -pkgmngt part.
45 The name of the scriptlet will be taken from the dbhtml instruction:
46 it is the name of the file less .html, with xxx-x-added before
47 (x, digits). -->
[7072e1f]48<sect1 id="ch-tools-pkgmngt" role="wrap">
[49f8b03]49 <?dbhtml filename="pkgmngt.html"?>
50<!-- the next lines are now mandatory for unpacking the tarball at the
51 beginning of the scriptlet -->
52 <sect1info condition="script">
53 <productname>dpkg</productname>
54 <productnumber>x.y.z</productnumber><!-- version -->
55 <address>http://where/is/your/package</address><!-- url -->
56 </sect1info>
57<!-- next line mandatory without change, but feel free to add any title,
58other sect2 (with different role), sectinfo and so on -->
59 <sect2 role="installation">
60<!-- You can use any number of remap="pre", "configure", "make", "test", "install"
61<screen><userinput remap="something">Instructions</userinput></screen>.
62They are executed in that order. "pre" can be used for patching for example.
63In case testing is enabled, the instructions flagged test are logged to a different
64file (test-log). If testing is not enabled, they are not executed at all. Do not
65put line breaks before and after your instructions. <userinput> without
66remap attribute are considered configuration instructions and executed last. You
67can also use remap="adjust" for the same purpose. -->
68<screen><userinput remap="configure">./configure --prefix=/tools \
69 --disable-nls --without-dselect \
70 --without-start-stop-daemon \
71 --without-update-alternatives \
72 --without-install-info \
73 --without-zlib --with-bz2=static --without-selinux</userinput></screen>
74
75<screen><userinput remap="make">(cd lib &amp;&amp; make)
76(cd src &amp;&amp; make)
77(cd dpkg-deb &amp;&amp; make)
78(cd dpkg-split &amp;&amp; make)</userinput></screen>
79
80<screen><userinput remap="install">cp src/dpkg src/dpkg-* /tools/bin
81cp dpkg-deb/dpkg-deb /tools/bin
82cp dpkg-split/dpkg-split /tools/bin
83mkdir -pv /tools/etc/dpkg/{,dpkg.cfg.d}
84cp debian/dpkg.cfg /tools/etc/dpkg</userinput></screen>
85
86<screen><userinput>cat &gt;&gt; /tools/etc/dpkg/dpkg.cfg &lt;&lt; EOF
87# admindir on LFS system
88admindir /var/lib/dpkg
89EOF</userinput></screen>
90
91<screen><userinput>cat &gt;&gt; /tools/etc/dpkg/dpkg.cfg &lt;&lt; EOF
92# disable fatal error on path checking
93force-bad-path
94EOF</userinput></screen>
95
96 </sect2>
97
98</sect1>
99
100<!-- for new book, at the end of chapter 7 -->
101<sect1 id="ch-chroot-pkgmngt" role="wrap">
102 <?dbhtml filename="pkgmngt.html"?>
[2758d94]103<!-- the next lines are now mandatory for unpacking the tarball at the
104 beginning of the scriptlet -->
105 <sect1info condition="script">
106 <productname>dpkg</productname>
107 <productnumber>x.y.z</productnumber><!-- version -->
108 <address>http://where/is/your/package</address><!-- url -->
109 </sect1info>
[7072e1f]110<!-- next line mandatory without change, but feel free to add any title,
111other sect2 (with different role), sectinfo and so on -->
112 <sect2 role="installation">
113<!-- You can use any number of remap="pre", "configure", "make", "test", "install"
114<screen><userinput remap="something">Instructions</userinput></screen>.
115They are executed in that order. "pre" can be used for patching for example.
116In case testing is enabled, the instructions flagged test are logged to a different
117file (test-log). If testing is not enabled, they are not executed at all. Do not
118put line breaks before and after your instructions. <userinput> without
119remap attribute are considered configuration instructions and executed last. You
120can also use remap="adjust" for the same purpose. -->
121<screen><userinput remap="configure">./configure --prefix=/tools \
122 --disable-nls --without-dselect \
123 --without-start-stop-daemon \
124 --without-update-alternatives \
125 --without-install-info \
126 --without-zlib --with-bz2=static --without-selinux</userinput></screen>
127
128<screen><userinput remap="make">(cd lib &amp;&amp; make)
129(cd src &amp;&amp; make)
130(cd dpkg-deb &amp;&amp; make)
131(cd dpkg-split &amp;&amp; make)</userinput></screen>
132
133<screen><userinput remap="install">cp src/dpkg src/dpkg-* /tools/bin
134cp dpkg-deb/dpkg-deb /tools/bin
135cp dpkg-split/dpkg-split /tools/bin
136mkdir -pv /tools/etc/dpkg/{,dpkg.cfg.d}
137cp debian/dpkg.cfg /tools/etc/dpkg</userinput></screen>
138
139<screen><userinput>cat &gt;&gt; /tools/etc/dpkg/dpkg.cfg &lt;&lt; EOF
140# admindir on LFS system
141admindir /var/lib/dpkg
142EOF</userinput></screen>
143
144<screen><userinput>cat &gt;&gt; /tools/etc/dpkg/dpkg.cfg &lt;&lt; EOF
145# disable fatal error on path checking
146force-bad-path
147EOF</userinput></screen>
148
149 </sect2>
150
151</sect1>
152
153<!-- Mandatory section for creating dirs. These instructions are added at the
154end of the creating dirs instructions of the book. Do not change the
155following line -->
[575bcf3]156<sect1 id="ch-pkgmngt-creatingdirs">
[7072e1f]157
[575bcf3]158<!-- Put the create dir intructions there. feel free to add
[7072e1f]159any explaining <title>Title</title> and <para>explanations</para> -->
160<screen><userinput>mkdir -pv /var/{log,lib/dpkg/{info,updates}}
161mkdir -pv /var/lib/packages</userinput></screen>
162
163</sect1>
[49f8b03]164<!-- Same for files. Do not change the following line.
165 Those instructions are not executed for the new book.
166 If needed create files at the end of the temp install. -->
[575bcf3]167<sect1 id="ch-pkgmngt-createfiles">
[7072e1f]168
169<screen><userinput>touch /var/lib/dpkg/{available,status}
170touch /var/log/dpkg.log</userinput></screen>
171
172</sect1>
173
174<!-- Last but not least : Final instructions for installing the
175package manager at the end of chapter 6. Again, the scriptlet file name is
[2758d94]176taken from the dbhtml instruction, with digits added before and .html cut.
[49f8b03]177There can be any number of sections for dependencies, all with id
178ch-system-xxx (all the id's must be different).
[7072e1f]179-->
180<sect1 id="ch-system-pkgmngt" role="wrap">
181 <?dbhtml filename="dpkg.html"?>
182
[2758d94]183<!-- the next lines are now mandatory for unpacking the tarball at the
184 beginning of the scriptlet -->
185 <sect1info condition="script">
186 <productname>dpkg</productname><!-- for example -->
187 <productnumber>x.y.z</productnumber><!-- version -->
188 <address>http://where/is/your/package</address><!-- url -->
189 </sect1info>
190
[7072e1f]191 <sect2 role="installation">
192
193<screen><userinput remap="configure">./configure --prefix=/usr \
194 --without-dselect \
195 --without-start-stop-daemon \
196 --without-update-alternatives \
197 --without-install-info \
198 --without-selinux</userinput></screen>
199
200<screen><userinput remap="make">make</userinput></screen>
201
202<!-- Those instructions are executed with PKG_DEST set. They are not processed
203in any way to add $PKG_DEST at some place, and the PKG_DEST directory is not
204populated before, so it is basically empty. You have thus to create any directory
205needed in $PKG_DEST and not otherwise created by the make install command. -->
206<screen><userinput remap="install">mkdir -pv $PKG_DEST
207make DESTDIR=$PKG_DEST install
208mkdir -pv $PKG_DEST/etc/dpkg/{,dpkg.cfg.d}
209cp debian/dpkg.cfg $PKG_DEST/etc/dpkg</userinput></screen>
210
211<screen><userinput remap="install">cat &gt;&gt; $PKG_DEST/etc/dpkg/dpkg.cfg &lt;&lt; EOF
212# admindir on LFS system
213admindir /var/lib/dpkg
214EOF</userinput></screen>
215
216<screen><userinput>cat &gt;&gt; $PKG_DEST/etc/dpkg/dpkg.cfg &lt;&lt; EOF
217# disable fatal error on path checking
218force-bad-path
219EOF</userinput></screen>
220
221 </sect2>
222
223</sect1>
224</article>
Note: See TracBrowser for help on using the repository browser.