blob: 469745f2a7e811ced973537b8bce03e012e96ce7 [file] [log] [blame]
Brad Bishopd7bf8c12018-02-25 22:55:05 -05001DESCRIPTION = "TigerVNC remote display system"
2HOMEPAGE = "http://www.tigervnc.com/"
3LICENSE = "GPLv2+"
4SECTION = "x11/utils"
5DEPENDS = "xserver-xorg gnutls jpeg libxtst gettext-native fltk"
6RDEPENDS_${PN} = "chkconfig coreutils hicolor-icon-theme"
7
8LIC_FILES_CHKSUM = "file://LICENCE.TXT;md5=75b02c2872421380bbd47781d2bd75d3"
9
10S = "${WORKDIR}/git"
11
12inherit distro_features_check
13REQUIRED_DISTRO_FEATURES = "x11"
14
15inherit autotools cmake
16B = "${S}"
17
18SRCREV = "4d6e1b8306a8cca8ad5e15ff8201f6ea24459cfd"
19
20SRC_URI = "git://github.com/TigerVNC/tigervnc.git;branch=1.8-branch \
21 file://0001-tigervnc-remove-includedir.patch \
22 file://0002-do-not-build-tests-sub-directory.patch \
23 file://0003-add-missing-dynamic-library-to-FLTK_LIBRARIES.patch \
24 file://0004-tigervnc-add-fPIC-option-to-COMPILE_FLAGS.patch \
25 file://0005-Remove-INITARGS-from-xserver119.patch.patch \
26"
27
28# Keep sync with xorg-server in oe-core
29XORG_PN ?= "xorg-server"
30XORG_PV ?= "1.19.3"
31SRC_URI += "${XORG_MIRROR}/individual/xserver/${XORG_PN}-${XORG_PV}.tar.bz2;name=xorg"
32XORG_S = "${WORKDIR}/${XORG_PN}-${XORG_PV}"
33SRC_URI[xorg.md5sum] = "015d2fc4b9f2bfe7a626edb63a62c65e"
34SRC_URI[xorg.sha256sum] = "677a8166e03474719238dfe396ce673c4234735464d6dadf2959b600d20e5a98"
35
36# It is the directory containing the Xorg source for the
37# machine on which you are building TigerVNC.
38XSERVER_SOURCE_DIR="${S}/unix/xserver"
39
40do_patch[postfuncs] += "do_patch_xserver"
41do_patch_xserver () {
42 for subdir in Xext xkb GL hw/xquartz/bundle hw/xfree86/common; do
43 install -d ${XSERVER_SOURCE_DIR}/$subdir
44 done
45
46 for subdir in hw/dmx/doc man doc hw/dmx/doxygen; do
47 install -d ${XSERVER_SOURCE_DIR}/$subdir
48 done
49
50 sources="hw/xquartz/bundle/cpprules.in man/Xserver.man doc/smartsched \
51 hw/dmx/doxygen/doxygen.conf.in xserver.ent.in xkb/README.compiled \
52 hw/xfree86/xorgconf.cpp hw/xfree86/Xorg.sh.in"
53 for i in ${sources}; do
54 install -m 0644 ${XORG_S}/$i ${XSERVER_SOURCE_DIR}/$i;
55 done
56
57 cd ${XORG_S}
58 find . -type f | egrep '.*\.(c|h|am|ac|inc|m4|h.in|pc.in|man.pre|pl|txt)$' | \
59 xargs tar cf - | (cd ${XSERVER_SOURCE_DIR} && tar xf -)
60
61 cd ${XSERVER_SOURCE_DIR}
62 xserverpatch="${S}/unix/xserver119.patch"
63 echo "Apply $xserverpatch"
64 patch -p1 -b --suffix .vnc < $xserverpatch
65}
66
67EXTRA_OECONF = "--disable-xorg --disable-xnest --disable-xvfb --disable-dmx \
68 --disable-xwin --disable-xephyr --disable-kdrive --with-pic \
69 --disable-static --disable-xinerama \
70 --with-xkb-output=${localstatedir}/lib/xkb \
71 --disable-glx --disable-dri --disable-dri2 \
72 --disable-config-hal \
73 --disable-config-udev \
74 --without-dtrace \
75 --disable-unit-tests \
76 --disable-devel-docs \
77 --disable-selective-werror \
78 --disable-xshmfence \
79 --disable-config-udev \
80 --disable-dri3 \
81 --disable-libunwind \
82 --without-xmlto \
83 --enable-systemd-logind=no \
84 --disable-xinerama \
85 --disable-xwayland \
86"
87
88do_configure_append () {
89 olddir=`pwd`
90 cd ${XSERVER_SOURCE_DIR}
91
92 rm -rf aclocal-copy/
93 rm -f aclocal.m4
94
95 export ACLOCALDIR="${XSERVER_SOURCE_DIR}/aclocal-copy"
96 mkdir -p ${ACLOCALDIR}/
97 if [ -d ${STAGING_DATADIR_NATIVE}/aclocal ]; then
98 cp-noerror ${STAGING_DATADIR_NATIVE}/aclocal/ ${ACLOCALDIR}/
99 fi
100 if [ -d ${STAGING_DATADIR}/aclocal -a "${STAGING_DATADIR_NATIVE}/aclocal" != "${STAGING_DATADIR}/aclocal" ]; then
101 cp-noerror ${STAGING_DATADIR}/aclocal/ ${ACLOCALDIR}/
102 fi
103 ACLOCAL="aclocal --system-acdir=${ACLOCALDIR}/" autoreconf -Wcross --verbose --install --force ${EXTRA_AUTORECONF} $acpaths || bbfatal "autoreconf execution failed."
104 chmod +x ./configure
105 ${CACHED_CONFIGUREVARS} ./configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
106 cd $olddir
107}
108
109do_compile_append () {
110 olddir=`pwd`
111 cd ${XSERVER_SOURCE_DIR}
112
113 oe_runmake
114
115 cd $olddir
116}
117
118do_install_append() {
119 olddir=`pwd`
120 cd ${XSERVER_SOURCE_DIR}/hw/vnc
121
122 oe_runmake 'DESTDIR=${D}' install
123
124 cd $olddir
125}
126
127FILES_${PN} += " \
128 ${libdir}/xorg/modules/extensions \
129 ${datadir}/icons \
130"
131
132FILES_${PN}-dbg += "${libdir}/xorg/modules/extensions/.debug"