summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e97732897f25ed06b6886b34ffed40658ba9abed (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
# Maintainer: Alex Agura <agura@tfwno.gf>
pkgname=asus-fan-control
pkgver=3.3.0
pkgrel=1
pkgdesc="Fan control for ASUS devices running Linux."
arch=('any')
url="https://github.com/dominiksalvet/asus-fan-control"
license=('MIT')
depends=(acpi_call dmidecode)
makedepends=(git)
optdepends=('acpi_call-lts: for the linux-lts kernel'
            'acpi_call-dkms: for other non-standard kernels')
install=$pkgname.install
source=("https://github.com/dominiksalvet/$pkgname/archive/$pkgver.tar.gz")
#_commit=5f8413164a65c590dad8bac31399d0908275de0a
#source=("$pkgname::git+https://github.com/dominiksalvet/asus-fan-control.git#commit=$_commit")
md5sums=('d1d8ac85aa4c6fe7717f5e5e8e150803')

#pkgver() {
#    cd $pkgname
#    git describe --tags | sed 's/-/+/g;s/^v//'
#}

prepare(){
    cd "$pkgname-$pkgver"

    # Our asus-fan-control executable is installed to /usr/bin
    sed -ie '/^ExecStart/s:/local::' .gitpack/data/asus-fan-control.service
}

package() {
    cd "$pkgname-$pkgver"

    for dir in usr/{bin,lib/systemd/system,share/{bash-completion/completions,asus-fan-control}} etc/asus-fan-control; do
        mkdir -p $pkgdir/$dir
    done

    install -m644 data/models $pkgdir/usr/share/asus-fan-control
    install -m755 src/asus-fan-control $pkgdir/usr/bin
    install -m644 src/asus-fan-control-completion.bash $pkgdir/usr/share/bash-completion/completions/asus-fan-control
    install -m644 .gitpack/data/asus-fan-control.service $pkgdir/usr/lib/systemd/system

}