ArchLinux/pkgbuild/xmobar-git/PKGBUILD

46 lines
1.3 KiB
Bash

# Maintainer: Cedric Girard <girard.cedric@gmail.com>
pkgname=xmobar-git
pkgver=20101222
pkgrel=2
pkgdesc="A minimal status bar for the XMonad Window Manager"
arch=('i686' 'x86_64')
url="http://projects.haskell.org/xmobar/"
license=('custom:BSD3')
makedepends=('ghc>=6.12' 'haskell-x11-xft' 'haskell-stm' 'haskell-parsec' 'haskell-utf8-string' 'haskell-libmpd' 'haskell-hinotify' 'wireless_tools' 'git')
depends=('wireless_tools' 'gmp' 'libxinerama' 'libxft')
conflicts=('xmobar' 'xmobar-darcs')
install=
source=()
md5sums=()
_gitroot="https://github.com/jaor/xmobar.git"
_gitname="xmobar"
build() {
cd "${srcdir}"
msg "Connecting to GIT server...."
if [ -d $_gitname ] ; then
cd $_gitname && git pull origin
msg "The local files are updated."
else
git clone $_gitroot $_gitname
fi
msg "GIT checkout done or server timeout"
msg "Starting make..."
rm -rf "${srcdir}/$_gitname-build"
git clone "${srcdir}/$_gitname" "${srcdir}/$_gitname-build"
cd "${srcdir}/$_gitname-build"
runhaskell Setup configure --flags="all_extensions" --prefix=/usr
runhaskell Setup build
install -D -m644 LICENSE ${pkgdir}/usr/share/licenses/$pkgname/BSD3
}
package() {
cd "${srcdir}/$_gitname-build"
runhaskell Setup copy --destdir=${pkgdir}
}