summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 8e73a45d318ee22bad0ff3eb1ed1ab56f8969542 (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
# Maintainer: krepa098 <krepa098@gmail.com>

_pkgname=stl2thumbnail
pkgname=stl2thumbnail-git
pkgver=v0.1.r1.ge58f3f3
pkgrel=1
pkgdesc="Enables file managers to generate thumbnails for STL files"
arch=("i686" "x86_64")
url="https://github.com/krepa098/stl2thumbnail"
license=("GPL")
groups=()
depends=("libpng")
makedepends=("git" "cmake" "glm")
source=("$_pkgname::git+$url.git#branch=master")
md5sums=("SKIP")

_gitname="stl2thumbnail"
_gitbranch="master"

pkgver() {
  cd "${_pkgname}"
  git describe --long | sed "s/\([^-]*-g\)/r\1/;s/-/./g"
}

build() {
  cd "${_pkgname}/build"
  cmake .. -DCMAKE_INSTALL_PREFIX="/usr"
  cmake --build . --config Release
}

prepare() {
  cd "${_pkgname}"
  mkdir -p build
}

package() {
  cd "${_pkgname}/build"
  make DESTDIR="${pkgdir}/" install
}