diff options
Diffstat (limited to 'community/haskell-gtk/PKGBUILD')
-rw-r--r-- | community/haskell-gtk/PKGBUILD | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/community/haskell-gtk/PKGBUILD b/community/haskell-gtk/PKGBUILD index b0dd2cf5d..3e8988bd4 100644 --- a/community/haskell-gtk/PKGBUILD +++ b/community/haskell-gtk/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 110622 2014-05-04 13:55:01Z td123 $ +# $Id: PKGBUILD 115979 2014-07-19 16:05:06Z td123 $ # Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com> pkgname=haskell-gtk pkgver=0.12.5.7 -pkgrel=1 +pkgrel=2 pkgdesc="Binding to the gtk library for Gtk2Hs." url="http://hackage.haskell.org/package/gtk" license=('LGPL2.1') @@ -30,10 +30,19 @@ build() { sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh } +_update_deps() { + _ver=`pacman -Q $1 | cut -f2 -d\ | cut -f1 -d-` + for i in `seq 0 $(expr ${#depends[@]} - 1)`; do + if [ ${depends[$i]} == $1 ]; then + depends[$i]="$1=${_ver}" + fi + done +} + package() { - _hmtlver=`pacman -Q haskell-mtl | cut -f2 -d\ | cut -f1 -d-` - _hpangover=`pacman -Q haskell-pango | cut -f2 -d\ | cut -f1 -d-` - depends=("ghc" "gtk2" "haskell-pango=${_hpangover}" "haskell-mtl=${_hmtlver}") + _update_deps ghc + _update_deps haskell-mtl + _update_deps haskell-pango cd ${srcdir}/gtk-${pkgver} install -D -m744 register.sh ${pkgdir}/usr/share/haskell/gtk2hs-gtk/register.sh |