]>
All Packages Download or otherwise obtain the following packages: Dpkg (&dpkg-version;) - &dpkg-size;: Home page: Download: MD5 sum: &dpkg-md5; dpkg &dpkg-version;
&dpkg-url;
Dpkg-&dpkg-version; <para>This is my choice of package manager. Dpkg is the basic package manager of Debian. It can be complemented by deselect (in the same package), apt or aptitude. We use it in a very crude way.</para> <segmentedlist> <segtitle>&buildtime;</segtitle> <segtitle>&diskspace;</segtitle> <seglistitem> <seg>&dpkg-ch5-sbu;</seg> <seg>&dpkg-ch5-du;</seg> </seglistitem> </segmentedlist> </sect2> <sect2 role="installation"> <title>Installation of Dpkg Since Debian is shipping its own package, all patches have already been applied. Configure the package: ./configure --prefix=/tools \ --disable-nls --disable-dselect \ --disable-start-stop-daemon \ --disable-update-alternatives \ --without-zlib --with-liblzma=static --without-libselinux The meaning of the configure options: --disable-dselect Avoids building dselect, an awful thing! --disable-start-stop-daemon The utility start-stop-daemon is not needed here. --disable-update-alternatives Same for update-alternatives. --without-zlib Use gzip for compression of binary packages instead of the zlib library, which is not installed in chapter 5. --with-liblzma=static Use statically linked liblzma for compression of binary packages. --without-libselinux Disable building for selinux, which is not used with LFS/BLFS. Compile the package: (cd lib && make) (cd src && make) (cd dpkg-deb && make) (cd dpkg-split && make) This package does not come with a test suite. Install only the needed files: cp src/dpkg src/dpkg-* /tools/bin cp dpkg-deb/dpkg-deb /tools/bin cp dpkg-split/dpkg-split /tools/bin mkdir -pv /tools/etc/dpkg/{,dpkg.cfg.d} cp debian/dpkg.cfg /tools/etc/dpkg Add a line in dpkg.cfg to tell where to put administration files cat >> /tools/etc/dpkg/dpkg.cfg << EOF # admindir on LFS system admindir /var/lib/dpkg EOF On a Debian system, dpkg relies on two other files to be present. Since we do not install them, issue: cat >> /tools/etc/dpkg/dpkg.cfg << EOF # disable fatal error on path checking force-bad-path EOF
Adding Directories for package management Those directories should be added to the system. /var/lib/dpkg and subdirectories are adminitrative directories of dpkg. /var/log is the log directory for dpkg. /var/lib/packages will be used to store our packages.deb files. mkdir -pv /var/{log,lib/dpkg/{info,updates}} mkdir -pv /var/lib/packages Adding administrative files for Dpkg dpkg needs that some files exist to run for the first time. The log file must exist in order to be used. touch /var/lib/dpkg/{available,status} touch /var/log/dpkg.log dpkg &dpkg-version;
&dpkg-url;
Dpkg-&dpkg-version; <para>This is my choice of package manager. Dpkg is the basic package manager of Debian. It can be complemented by deselect (in the same package), apt or aptitude. We use it in a very crude way.</para> <segmentedlist> <segtitle>&buildtime;</segtitle> <segtitle>&diskspace;</segtitle> <seglistitem> <seg>&dpkg-ch6-sbu;</seg> <seg>&dpkg-ch6-du;</seg> </seglistitem> </segmentedlist> </sect2> <sect2 role="installation"> <title>Installation of Dpkg Since Debian is shipping its own package, all patches have already been applied. We do not need more in chapter 6. Configure it: ./configure --prefix=/usr \ --sysconfdir=/etc \ --localstatedir=/var \ --disable-dselect \ --disable-start-stop-daemon \ --disable-update-alternatives \ --without-libselinux The meaning of the configure options: --disable-dselect Avoids building dselect, an awful thing! --disable-start-stop-daemon The utility start-stop-daemon is not needed here. --disable-update-alternatives Same for update-alternatives. --without-libselinux Selinux is not used in LFS. Compile the package: make This package does not come with a test suite. Install the package: mkdir -pv $PKG_DEST make DESTDIR=$PKG_DEST install mkdir -pv $PKG_DEST/etc/dpkg/{,dpkg.cfg.d} cp debian/dpkg.cfg $PKG_DEST/etc/dpkg Add a line in dpkg.cfg to tell where to put administration files cat >> $PKG_DEST/etc/dpkg/dpkg.cfg << EOF # admindir on LFS system admindir /var/lib/dpkg EOF On a Debian system, dpkg relies on two other files (ldconfig and maybe update-rc.d) to be present. Since we do not install them, issue: cat >> /etc/dpkg/dpkg.cfg << EOF # disable fatal error on path checking force-bad-path EOF