summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: c9237406df2b6af7f19444dd7744e0d02e9a53af (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
# Maintainer: Eric Berquist <eric DOT berquist AT gmail DOT com>

_pkgname=molequeue
pkgname="${_pkgname}-git"
pkgver=0.9.0.r817.0511c9a
pkgrel=2
pkgdesc="Desktop integration of high performance computing resources"
url="http://www.openchemistry.org/projects/molequeue"
arch=("x86_64")
license=("Kitware")
depends=("qt5-base")
makedepends=("git" "cmake")
conflicts=("${_pkgname}")
provides=("${_pkgname}")
source=("git+https://github.com/OpenChemistry/${_pkgname}.git")
sha256sums=("SKIP")

pkgver() {
  cd "${srcdir}/${_pkgname}"
  printf "%s.r%s.%s" \
         "$(git describe --tags --abbrev=0)" \
         "$(git rev-list --count HEAD)" \
         "$(git rev-parse --short HEAD)"
}

build() {
  cd "${srcdir}"
  cmake \
      -DCMAKE_BUILD_TYPE:STRING=Release \
      -DCMAKE_INSTALL_PREFIX:PATH=/usr \
      -DCMAKE_INSTALL_LIBDIR:PATH=lib \
      -DENABLE_TESTING:BOOL=ON \
      -DBUILD_SHARED_LIBS:BOOL=ON \
      -Bbuild \
      "${srcdir}/${_pkgname}"
  cd build
  make
}

check() {
  cd "${srcdir}/build"
  make test
}

package() {
  cd "${srcdir}/build"
  make DESTDIR="${pkgdir}" install
  install -D -m 644 "${srcdir}/${_pkgname}"/LICENSE "${pkgdir}/usr/share/licenses/${_pkgname}/LICENSE"
}