summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 6dc475aa911fcddd3bccf4c9eaa85bed05b719c8 (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
pkgname=i8kutils
pkgver=1.43
pkgrel=0
pkgdesc="Fan control for Dell laptops"
arch=('i686' 'x86_64')
url="https://launchpad.net/i8kutils"
license=('GPL v2')
depends=('bash')
optdepends=('tcl: for i8kmon daemon' 'acpi: for i8kmon daemon')
backup=('etc/i8kutils/i8kmon.conf')
source=(https://launchpad.net/i8kutils/trunk/${pkgver}/+download/i8kutils_${pkgver}.tar.xz
        i8kmon.service)

sha1sums=('46204f9a567bbbc2267d67269c5bbbfad4187799'
          '5c20f5241de7e60b46117269f4e867b08734cdc8')

prepare() {
  cd $pkgname
  # conform to Arch Linux guidelines
  sed -i 's|/etc/i8kmon.conf|/etc/i8kutils/i8kmon.conf|g' i8kmon.1
  sed -i 's|/etc/i8kmon.conf|/etc/i8kutils/i8kmon.conf|g' i8kmon.conf
  sed -i 's|/etc/i8kmon.conf|/etc/i8kutils/i8kmon.conf|g' i8kmon
  make clean
}

build() {
  cd $pkgname
  make
}

package() {
  cd $pkgname
  install -d "$pkgdir"/usr/{bin,share/man/man1}
  install -D -m644 i8kctl.1 i8kmon.1 "$pkgdir/usr/share/man/man1"
  install -D -m755 i8kctl i8kfan i8kmon "$pkgdir/usr/bin"

  install -D -m644 i8kmon.conf "$pkgdir/etc/i8kutils/i8kmon.conf"
  install -D -m644 debian/i8kmon.service "$pkgdir/usr/lib/systemd/system/i8kmon.service"
}