summaryrefslogtreecommitdiff
path: root/core/util-linux/PKGBUILD
blob: 9d358759748e14c16b511a5309b3fa87d6af2833 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# $Id: PKGBUILD 138467 2011-09-24 11:28:45Z tomegun $
# Maintainer: Tom Gundersen <teg@jklm.no>
# Contributor: judd <jvinet@zeroflux.org>

pkgname=util-linux
pkgver=2.20
pkgrel=3
pkgdesc="Miscellaneous system utilities for Linux"
url="http://userweb.kernel.org/~kzak/util-linux-ng/"
arch=('i686' 'x86_64')
groups=('base')
depends=('filesystem')
replaces=('linux32' 'util-linux-ng')
conflicts=('linux32' 'util-linux-ng' 'e2fsprogs<1.41.8-2')
provides=('linux32' "util-linux-ng=${pkgver}")
license=('GPL2')
options=('!libtool')
source=(ftp://ftp.kernel.org/pub/linux/utils/${pkgname}/v${pkgver}/${pkgname}-${pkgver}.tar.bz2
	agetty-typo.patch
	write-freopen.patch
	dmesg-non-printk.patch
	dmesg-space.patch
	dont-close-0.patch
	fix-remount.patch)
optdepends=('perl: for chkdupexe support')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  # patches from master
  for patch in agetty-typo.patch write-freopen.patch dmesg-non-printk.patch dmesg-space.patch dont-close-0.patch fix-remount.patch; do
    patch -Np1 -i "${srcdir}/${patch}"
  done

  # hardware clock
  sed -e 's%etc/adjtime%var/lib/hwclock/adjtime%' -i include/pathnames.h

  ./configure --enable-arch\
              --enable-write\
              --enable-raw\
              --disable-wall\
              --enable-partx\
              --enable-libmount-mount

  make
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  install -dm755 "${pkgdir}/var/lib/hwclock"

  make DESTDIR="${pkgdir}" install
}
md5sums=('4dcacdbdafa116635e52b977d9d0e879'
         '13838c6dd8df686e0f01ad0f236d2690'
         '465817ff8f7c08411c8011ee91b50318'
         'f3ca75a1a22a2a739c5c22d92dc07ab0'
         'd9768f0b42d36d72c02ac7797b922ba1'
         '37eae52af90c214dda73874c701fa246'
         '344c780b9e08826dd8befe4271b41ed3')