APKBUILD 1.15 KB
Newer Older
Carlo Landmeter's avatar
Carlo Landmeter committed
1
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
Natanael Copa's avatar
Natanael Copa committed
2
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
Carlo Landmeter's avatar
Carlo Landmeter committed
3
pkgname=libva
Leo's avatar
Leo committed
4
pkgver=2.4.1
5
pkgrel=0
Carlo Landmeter's avatar
Carlo Landmeter committed
6
pkgdesc="Video Acceleration (VA) API for Linux"
7
url="https://freedesktop.org/wiki/Software/vaapi"
Carlo Landmeter's avatar
Carlo Landmeter committed
8
arch="all"
9
options="!check"  # No test suite.
Carlo Landmeter's avatar
Carlo Landmeter committed
10
license="MIT"
11
depends_dev="libx11-dev libxext-dev libxfixes-dev libdrm-dev"
Leo's avatar
Leo committed
12
makedepends="$depends_dev meson wayland-dev"
Carlo Landmeter's avatar
Carlo Landmeter committed
13
subpackages="$pkgname-dev"
Leo's avatar
Leo committed
14
source="$pkgname-$pkgver.tar.gz::https://github.com/intel/libva/archive/${pkgver}.tar.gz"
15
builddir="$srcdir"/$pkgname-$pkgver
Carlo Landmeter's avatar
Carlo Landmeter committed
16
17

prepare() {
18
19
20
21
22
23
24
	( if [ -f "$startdir"/../libva-glx/APKBUILD ]; then
		_v=$pkgver
		. "$startdir"/../libva-glx/APKBUILD
		if [ "$_v" != "$pkgver" ]; then
			die "libva and libva-glx needs to be same version"
		fi
	fi )
25
26
	cd "$builddir"
	default_prepare
Carlo Landmeter's avatar
Carlo Landmeter committed
27
28
29
}

build() {
30
	cd "$builddir"
Leo's avatar
Leo committed
31
	meson builddir \
32
		--prefix=/usr \
Leo's avatar
Leo committed
33
34
35
		-Dwith_glx=no \
		-Dwith_wayland=yes
	ninja -C builddir
Carlo Landmeter's avatar
Carlo Landmeter committed
36
37
38
}

package() {
39
	cd "$builddir"
Leo's avatar
Leo committed
40
	DESTDIR="$pkgdir" ninja -C builddir install
Carlo Landmeter's avatar
Carlo Landmeter committed
41
42
}

Leo's avatar
Leo committed
43
sha512sums="6ad2255aebcc62b3a7f67f03585f8046742a8a9b33c0feaee7dc0a713ab2117b13f154c3574f98aa2fb07fd2336635df3ea2675ec4d1c25ae3b2834aeab8692e  libva-2.4.1.tar.gz"