aboutsummaryrefslogtreecommitdiffstats
path: root/community/glslang/APKBUILD
blob: a37f023aedb645b8260c8f936c0ceda8a6520f9f (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
# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer: Leo <thinkabit.ukim@gmail.com>
pkgname=glslang
pkgver=7.11.3214
pkgrel=0
pkgdesc="Khronos reference front-end for GLSL, ESSL, and sample SPIR-V generator"
options="!check" # Requires git checkout of gmock
url="https://github.com/KhronosGroup/glslang"
arch="all"
license="BSD-3-Clause"
depends_dev="$pkgname"
makedepends="cmake python3 bison"
subpackages="$pkgname-static $pkgname-dev"
source="$pkgname-$pkgver.tar.gz::https://github.com/KhronosGroup/glslang/archive/${pkgver}.tar.gz"

build() {
	if [ "$CBUILD" != "$CHOST" ]; then
		CMAKE_CROSSOPTS="-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux"
	fi
	cmake \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib \
		-DBUILD_SHARED_LIBS=True \
		-DCMAKE_BUILD_TYPE=Release \
		-DCMAKE_CXX_FLAGS="$CXXFLAGS" \
		-DCMAKE_C_FLAGS="$CFLAGS" \
		-DBUILD_SHARED_LIBS=ON \
		${CMAKE_CROSSOPTS} .
	make
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="5e7f8c063b30fc5edf65898b2371f4128aead05008865d065de9d3a94354de787035067ec908651c7e88bf294251d1410929d2b1c19e03d9b51476ea8a7eae96  glslang-7.11.3214.tar.gz"