summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 3eed2a84b689fc1ff558e2898e753b5c17e87260 (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
# Maintainer: justforlxz <justforlxz@gmail.com>

pkgname=dtkcommon-git
pkgver=5.6.3.r1.g3781d33
pkgrel=1
pkgdesc='DTK common modules'
arch=('x86_64' 'aarch64')
url="https://github.com/linuxdeepin/dtkcommon"
license=('LGPL3')
depends=()
makedepends=('git' 'qt5-tools' 'gtest' 'gmock' 'cmake' 'ninja')
conflicts=('dtkcommon')
providers=('dtkcommon')
groups=('deepin-git')
source=("$pkgname::git+https://github.com/linuxdeepin/dtkcommon")
sha512sums=('SKIP')

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

build() {
  cd $pkgname
  cmake -B build -GNinja \
    -DCMAKE_INSTALL_LIBDIR=/usr/lib \
    -DLINUXNAME="archlinux" \
    -DCMAKE_INSTALL_PREFIX=/usr
  cmake --build build
}

package() {
  cd $pkgname/build
  DESTDIR="$pkgdir" ninja install
}