# vim: ft=PKGBUILD
# % Trigger %
# Maintainer: Jack Frost <fbt@fleshless.org>
# Contributor: WorMzy Tykashi <wormzy.tykashi@gmail.com>
# Contributor: OK100 <ok100 at lavabit dot com>
# Contributor: Valère Monseur <valere dot monseur at ymail dot com>
pkgname=compton-git
_gitname=compton
pkgver=v0.1_beta2.r83.g2343e4b
pkgrel=1
pkgdesc="X Compositor (a fork of xcompmgr-dana) (git-version)"
arch=(i686 x86_64)
url="https://github.com/chjj/compton"
license=('MIT')
depends=('libgl' 'libdbus' 'libxcomposite' 'libxdamage' 'libxrandr' 'pcre' 'libconfig' 'libxinerama')
makedepends=('git' 'asciidoc' 'mesa')
optdepends=('dbus: To control compton via D-Bus'
'xorg-xwininfo: For compton-trans'
'xorg-xprop: For compton-trans')
provides=('compton')
conflicts=('compton')
source=("git://github.com/chjj/compton.git")
md5sums=("SKIP")
pkgver() {
cd "${srcdir}/${_gitname}"
if git_version=$( git describe --long --tags 2>/dev/null ); then
IFS='-' read last_tag tag_rev commit <<< "$git_version"
printf '%s.r%s.%s' "$last_tag" "$tag_rev" "$commit"
else
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
fi
}
build() {
cd "$srcdir/$_gitname"
make PREFIX=/usr
make docs
package() {
make PREFIX="$pkgdir/usr" install
# install license
install -D -m644 "LICENSE" "$pkgdir/usr/share/licenses/$_gitname/LICENSE"
# example conf
install -D -m644 "compton.sample.conf" "$pkgdir/etc/xdg/compton.conf.example"