archrelease: copy trunk to extra-x86_64
[arch-packages.git] / glslang / trunk / PKGBUILD
blob7f83b0fb6c8d687bb39c4ad42eaf10f7cdba35bf
1 # Maintainer: Sven-Hendrik Haase <svenstaro@archlinux.org>
3 # Careful when upgrading this package! It usually breaks ABI without bumping soname.
4 pkgname=glslang
5 pkgver=11.10.0
6 pkgrel=1
7 pkgdesc='OpenGL and OpenGL ES shader front end and validator'
8 arch=('x86_64')
9 url='https://github.com/KhronosGroup/glslang'
10 license=('BSD')
11 depends=('gcc-libs')
12 makedepends=('cmake' 'ninja' 'git' 'python' 'spirv-tools' 'spirv-headers')
13 options=('staticlibs')
14 # Get the commits from known_good.json for every release
15 source=(${pkgname}-${pkgver}.tar.gz::https://github.com/KhronosGroup/glslang/archive/${pkgver}.tar.gz)
16 sha256sums=('8ffc19c435232d09299dd2c91e247292b3508c1b826a3497c60682e4bbf2d602')
18 build() {
19   cd ${pkgname}-${pkgver}
20   export CXXFLAGS+=" -ffat-lto-objects"
21   cmake \
22     -Bbuild-shared \
23     -GNinja \
24     -DCMAKE_INSTALL_PREFIX=/usr \
25     -DCMAKE_BUILD_TYPE=Release \
26     -DBUILD_SHARED_LIBS=ON
27   ninja -Cbuild-shared
28   cmake \
29     -Bbuild-static \
30     -GNinja \
31     -DCMAKE_INSTALL_PREFIX=/usr \
32     -DCMAKE_BUILD_TYPE=Release \
33     -DBUILD_SHARED_LIBS=OFF
34   ninja -Cbuild-static
37 package() {
38   cd ${pkgname}-${pkgver}
39   DESTDIR="${pkgdir}" ninja -C build-shared install
40   DESTDIR="${pkgdir}" ninja -C build-static install
42   install -Dm644 LICENSE.txt "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
44   cd "${pkgdir}"/usr/lib
45   for lib in *.so; do
46     ln -sf "${lib}" "${lib}.0"
47   done
50 # vim: ts=2 sw=2 et: