PKGBUILDs/core/util-linux-ng/PKGBUILD

46 lines
1.7 KiB
Bash

# Maintainer: Mike Staszel <mikestaszel@openpogo.com>
pkgname=util-linux-ng
pkgver=2.16
_loop_date=20090725
pkgrel=1
pkgdesc="Miscellaneous system utilities for Linux"
url="http://userweb.kernel.org/~kzak/util-linux-ng/"
arch=(i686 x86_64 arm)
groups=('base')
depends=('bash' 'ncurses>=5.7' 'zlib')
replaces=('linux32' 'util-linux')
conflicts=('linux32' 'util-linux')
provides=('linux32' 'util-linux')
license=('GPL2')
options=('!libtool')
source=(ftp://ftp.kernel.org/pub/linux/utils/${pkgname}/v2.16/${pkgname}-${pkgver}.tar.bz2
http://loop-aes.sourceforge.net/updates/${pkgname}-${pkgver}-${_loop_date}.diff.bz2
fsck-static.patch)
install=util-linux-ng.install
md5sums=('9623380641b0c2e0449f5b1ecc567663'
'1752b93df05410a8df8e84d07d41f048'
'35c3ba312782f042b594399b50b8de62')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
# Provide static fsck
patch -Np1 -i "${srcdir}/fsck-static.patch" || return 1
# cryptoloop support
patch -Np1 -i "${srcdir}/${pkgname}-${pkgver}-${_loop_date}.diff" || return 1
# hardware clock
sed -e 's%etc/adjtime%var/lib/hwclock/adjtime%' -i hwclock/hwclock.c || return 1
mkdir -p "${pkgdir}/var/lib/hwclock" || return 1
autoconf || return 1
automake || return 1
./configure --enable-arch --enable-write --enable-raw --disable-wall --enable-rdev || return 1
make HAVE_SLN=yes ADD_RAW=yes || return 1
make HAVE_SLN=yes ADD_RAW=yes DESTDIR="${pkgdir}" install || return 1
# remove files
rm -f "${pkgdir}/bin/kill"
rm -f "${pkgdir}/usr/share/man/man1/kill.1"
rm -f "${pkgdir}/usr/share/man/man5/nfs.5"
rm -f "${pkgdir}/usr/share/info/dir"
gzip -9 "${pkgdir}/usr/share/info/ipc.info" || return 1
}