summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 0a1354f6063303e74e2f03816e3f614a12851fed (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: Sefa Eyeoglu <contact@scrumplex.net>

_pkgname=libliftoff
pkgname=${_pkgname}-git
pkgver=r126.2b02f50
pkgrel=1
pkgdesc="Lightweight KMS plane library"
arch=(x86_64)
url="https://github.com/emersion/libliftoff"
license=("custom:MIT")
depends=("libdrm")
makedepends=("git" "meson" "ninja")
provides=($_pkgname)
conflicts=($_pkgname)
source=("git+https://github.com/emersion/libliftoff.git")
sha512sums=('SKIP')


pkgver() {
    cd "$srcdir/$_pkgname"

    printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

build() {

    meson --prefix /usr --buildtype=release "$srcdir/$_pkgname" build
    ninja -C build
}

check() {

    ninja -C build test
}

package() {
    DESTDIR="$pkgdir" ninja -C build install
    
    cd "$srcdir/$_pkgname"

    install -Dm644 "LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
    install -Dm644 "README.md" "${pkgdir}/usr/share/doc/${_pkgname}/README.md"
}