summaryrefslogtreecommitdiff
path: root/community/kmscon/PKGBUILD
blob: 0d04c752ffc4dd701cb93c138cbac4552f76cddf (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
46
47
48
# $Id: PKGBUILD 98861 2013-10-20 18:22:20Z thestinger $
# Maintainer: Daniel Micay <danielmicay@gmail.com>
# Contributor: David Herrmann <dh.herrmann@googlemail.com>
pkgname=kmscon
pkgver=7
pkgrel=2
pkgdesc='Terminal emulator based on Kernel Mode Setting (KMS)'
arch=(i686 x86_64)
url='https://github.com/dvdhrm/kmscon'
license=('MIT')
depends=(systemd libdrm mesa libegl libgbm libgles pango libxkbcommon libpciaccess xkeyboard-config)
makedepends=(git libxslt docbook-xsl linux-api-headers)
options=(!libtool)

__gitroot=https://github.com/dvdhrm/kmscon.git
__gitname=kmscon

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 build..."

  rm -rf "$srcdir/$__gitname-build"
  git clone "$srcdir/$__gitname" "$srcdir/$__gitname-build"
  cd "$srcdir/$__gitname-build"

  git checkout $pkgname-$pkgver
  ./autogen.sh --prefix=/usr --disable-wlterm
  make
}

package() {
  cd "$srcdir/$__gitname-build"
  make DESTDIR="$pkgdir/" install
  mkdir -p "$pkgdir/usr/share/licenses/$pkgname" "$pkgdir/usr/lib/systemd/system"
  cp COPYING "$pkgdir/usr/share/licenses/$pkgname/"
  cp docs/kmscon{,vt@}.service "$pkgdir/usr/lib/systemd/system/"
}