summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: f028a5b30fe90d0ad98c4c0afc216a7ad498b641 (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
# Maintainer: James An <james@jamesan.ca>
# Contributor: Edgar Hucek <gimli at dark-green dot com>

pkgname=macfanctld
pkgver=0.6
pkgrel=1
arch=(i686 x86_64)
pkgdesc="Fan control daemon for MacBook"
url="https://github.com/MikaelStrom/macfanctld"
license="GPL3"
makedepends=('gcc')
depends=('glibc')
backup=('etc/macfanctl.conf')
source=(
  "https://github.com/MikaelStrom/$pkgname/archive/master.tar.gz"
  "$pkgname.service"
)
md5sums=('d1a42fe34cbb4e830bed5547bef969df'
         '3ae082c7be885c8427eee8108393fc90')

prepare() {
  cd "$pkgname-master"

  gzip -9f macfanctld.1
}

build() {
  cd "$pkgname-master"

  make
}

package() {
  cd "$pkgname-master"

  install -Dm755 $pkgname "$pkgdir/usr/bin/$pkgname"
  install -Dm644 "${pkgname%d}.conf" "$pkgdir/etc/${pkgname%d}.conf"
  install -Dm644 "$pkgname.1.gz" "$pkgdir/usr/share/man/man1/$pkgname.1.gz"

  install -Dm644 "$srcdir/$pkgname.service" "$pkgdir/usr/lib/systemd/system/$pkgname.service"
}