PKGBUILDs/community/tigervnc/PKGBUILD
2015-11-25 19:13:17 +00:00

77 lines
2.7 KiB
Bash

# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Maintainer: Uroš Vampl <mobile.leecher at gmail dot com>
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - use -fPIC for v7
pkgname=tigervnc
pkgver=1.5.0
pkgrel=2
_xorgver=1.18.0
pkgdesc="Suite of VNC servers and clients. Based on the VNC 4 branch of TightVNC."
arch=('i686' 'x86_64')
url="http://www.tigervnc.org"
license=('GPL')
depends=('fltk' 'pam' 'gnutls' 'libjpeg-turbo' 'libxtst' 'libxfont' 'pixman'
'xorg-xauth' 'xorg-xsetroot' 'xkeyboard-config' 'xorg-xkbcomp'
'libgl' 'libgcrypt' 'perl' 'libxdamage')
makedepends=('cmake' 'nasm' 'xorg-font-util' 'xorg-util-macros' 'bigreqsproto'
'compositeproto' 'damageproto' 'randrproto' 'resourceproto'
'scrnsaverproto' 'videoproto' 'xcmiscproto' 'xf86vidmodeproto'
'xtrans' 'glproto' 'dri2proto' 'dri3proto' 'presentproto'
'mesa' 'imagemagick')
optdepends=('mesa: for OpenGL functionality in Xvnc')
conflicts=('tightvnc')
source=($pkgname-$pkgver.tar.gz::https://github.com/TigerVNC/tigervnc/archive/v${pkgver}.tar.gz
ftp://ftp.freedesktop.org/pub/xorg/individual/xserver/xorg-server-${_xorgver}.tar.bz2
vncserver.service
vncviewer.desktop
gethomedir.patch
xorg118.patch)
md5sums=('b11cc4c4d5249b9b8e355ee6f47ec4fe'
'3c1c1057d3ad27380d8dd87ffcc182cd'
'1aad8f06504b3e29a24ccfbaab617973'
'b200d83c60e80c6f9693ea19a2d9f5b0'
'22f1523a0eca56ad79cfabd0db6e2cf6'
'2fd32181679077eb7f7ca06cf25f443f')
prepare() {
cd ${srcdir}/${pkgname}-${pkgver}
patch -Np1 -i ${srcdir}/xorg118.patch
patch -Np1 -i ${srcdir}/gethomedir.patch
sed -i 's/iconic/nowin/' unix/vncserver
cd unix/xserver
cp -r ${srcdir}/xorg-server-${_xorgver}/* .
patch -Np1 -i ../xserver117.patch
}
build() {
cd ${srcdir}/${pkgname}-${pkgver}
[ "$CARCH" == "armv7h" ] && CFLAGS+=" -fPIC" && CXXFLAGS+=" -fPIC"
cmake -G "Unix Makefiles" -DCMAKE_INSTALL_PREFIX=/usr
make
cd unix/xserver
autoreconf -fiv
./configure --prefix=/usr \
--disable-static --without-dtrace \
--disable-xorg --disable-xnest --disable-xvfb --disable-dmx \
--disable-xwin --disable-xephyr --disable-kdrive --disable-xwayland \
--disable-config-hal --disable-config-udev --with-pic \
--disable-unit-tests --disable-devel-docs --disable-selective-werror \
--disable-dri --enable-dri2 --enable-dri3 --enable-glx --enable-glx-tls
make
}
package() {
cd ${srcdir}/${pkgname}-${pkgver}
make DESTDIR=${pkgdir} install
cd unix/xserver/hw/vnc
make DESTDIR=${pkgdir} install
install -Dm0644 $srcdir/vncserver.service $pkgdir/usr/lib/systemd/system/vncserver.service
install -Dm0644 $srcdir/vncviewer.desktop $pkgdir/usr/share/applications/vncviewer.desktop
}