summaryrefslogtreecommitdiff
path: root/qwt-qt4/PKGBUILD
blob: 55f3ee4931ddc688b01d01c8e8d63939d5a7954e (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
# Maintainer: Erich Eckner <arch at eckner dot net>
# Contributor: Doug Newgard <scimmia at archlinux dot info>
# Contributor: Ronald van Haren <ronald.archlinux.org>

pkgname=qwt-qt4
_pkgname=qwt
pkgver=6.1.4
pkgrel=1
pkgdesc='Qt Widgets for Technical Applications - Qt4 version'
arch=('i686' 'pentium4' 'x86_64')
url='http://qwt.sourceforge.net/'
depends=('gcc-libs' 'glibc' 'qt4')
makedepends=('mesa')
license=('custom')
source=("https://downloads.sourceforge.net/$_pkgname/$_pkgname-$pkgver.tar.bz2")
sha512sums=('6135ce47fd4f9ff5b705193fc1f7410cfd5a0b84931bb17db750f6a5486ae810c261dae32431bd52838c36eadee02487148e1efa71c465c63aa43062eec160da')

prepare() {
  cd $_pkgname-$pkgver

  sed -e '/^\s*QWT_INSTALL_PREFIX/ s|=.*|= /usr|' \
      -e '/^QWT_INSTALL_DOCS/ s|^|#|' \
      -e '/^QWT_INSTALL_HEADERS/ s|include|&/qwt-qt4|' \
      -e '/^QWT_INSTALL_PLUGINS/ s|plugins/designer|lib/qt4/&|' \
      -e '/^QWT_INSTALL_FEATURES/ s|features|share/qt4/mkspecs/&|' \
      -i qwtconfig.pri

  sed -i '/^\s*\(LIBRARY_NAME\|LIB_NAME\)/ s/$/-qt4/' qwtfunctions.pri
}

build() {
  cd $_pkgname-$pkgver

  qmake-qt4 qwt.pro

  make
}

package() {
  cd $_pkgname-$pkgver

  make INSTALL_ROOT="$pkgdir" install

  install -Dm644 COPYING -t "$pkgdir/usr/share/licenses/$pkgname/"
}