summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: ffd651d73b85a0f25d9e6720cc893f77bb78cff7 (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
# Maintainer: Josip Ponjavic <josipponjavic at gmail dot com>

pkgname=qt5ct-svn
pkgver=0.35.r449
pkgrel=1
pkgdesc="Qt5 Configuration Tool - svn version."
arch=('i686' 'x86_64')
url="https://sourceforge.net/projects/qt5ct/"
license=('BSD')
depends=('qt5-svg')
makedepends=('qt5-tools' 'subversion')
conflicts=("${pkgname%-*}")
provides=("${pkgname%-*}")
install=${pkgname%-*}.install
source=('qt5ct::svn://svn.code.sf.net/p/qt5ct/code/trunk/qt5ct')
md5sums=('SKIP')

pkgver() {
  cd "${pkgname%-*}"
  major=$(grep 'define QT5CT_VERSION_MAJOR' src/qt5ct/qt5ct.h | awk '{print $3}')
  minor=$(grep 'define QT5CT_VERSION_MINOR' src/qt5ct/qt5ct.h | awk '{print $3}')
  local ver="$(svnversion)"
  printf "%s.r%s" "$major"."$minor" "${ver//[[:alpha:]]}"
}

build() {
  cd "${pkgname%-*}"
  qmake-qt5 qt5ct.pro
  make
}

package() {
  cd "${pkgname%-*}"
  make INSTALL_ROOT="$pkgdir" install
  install -d "$pkgdir/usr/share/qt5ct"
  cp -r {colors,qss} "$pkgdir/usr/share/qt5ct"
  install -Dm644 COPYING "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}