summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 76cece93f86b458344384c6a753ab2a26475884c (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
44
45
46
47
48
49
50
51
# Maintainer: Fabio 'Lolix' Loli <fabio.loli@disroot.org> -> https://github.com/FabioLolix
# Contributor: Yevhenii Kolesnikov <sigexp.acc at gmail dot com>

pkgname=gfxreconstruct-git
pkgver=1.0.1.r1.gc988668d
pkgrel=3
pkgdesc="Graphics API capture and replay tools for reconstructing graphics application behavior"
arch=(x86_64)
url="https://github.com/LunarG/gfxreconstruct"
license=(Apache)
depends=(glibc gcc-libs python zlib lz4 zstd)
#depends=(python  xcb-util-keysyms  libxrandr zlib lz4 zstd)
makedepends=(git cmake libx11 libxcb wayland xcb-util-keysyms)
provides=(gfxreconstruct)
conflicts=(gfxreconstruct)
source=("git+https://github.com/LunarG/gfxreconstruct.git"
        "git+https://github.com/KhronosGroup/Vulkan-Headers.git")
sha256sums=('SKIP'
            'SKIP')

pkgver() {
  cd gfxreconstruct
  git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}

prepare() {
  cd gfxreconstruct
  git submodule init
  git config submodule.'external/Vulkan-Headers'.url "$srcdir/Vulkan-Headers"
  git -c protocol.file.allow=always submodule update
}

build() {
  cmake -B build -S "gfxreconstruct" -Wno-dev \
    -DCMAKE_BUILD_TYPE=None \
    -DCMAKE_INSTALL_PREFIX=/usr

  cmake --build build
}

package() {
  DESTDIR="${pkgdir}" cmake --install build

  cd gfxreconstruct
  #DESTDIR="$pkgdir" make -C build_$arch install

  # Remove .py file extension from files that are going to /usr/bin/
  for f in $pkgdir/usr/bin/*.py; do
    mv -v $f `echo $f | sed 's/\.py//'`
  done
}