summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e62840f1d4176ce6867b02e790d8c957a23bcdfe (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
# Maintainer: João Figueiredo <jf dot mundox at gmail dot com> 

pkgname=elf-dissector-git
pkgver=0.0.1_r776.g4113e8b
pkgrel=2
pkgdesc='Static analysis tool for ELF libraries and executables'
arch=($CARCH)
url='https://invent.kde.org/sdk/elf-dissector'
license=(GPL)
depends=(harfbuzz hicolor-icon-theme libdwarf qt5-base)
makedepends=(extra-cmake-modules-git git kitemmodels-git)
optdepends=('capstone: disassembler' 'gnuplot: performance plot')
source=("git+https://github.com/KDE/${pkgname%-git}.git")
sha256sums=('SKIP')

pkgver() {
  cd ${pkgname%-git}
  _ver="$(grep -m1 'project(elf-dissector VERSION' CMakeLists.txt | cut -d ' ' -f3 | tr - . | tr -d ')')"
  echo "${_ver}_r$(git rev-list --count HEAD).g$(git rev-parse --short HEAD)"
}

build() {
  cmake -B build -S ${pkgname%-git} \
    -DBUILD_TESTING=OFF
  cmake --build build
}

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