blob: f3dc89972c355ae240d8aa711acd7dec55336a97 [file] [log] [blame]
Brad Bishop1a4b7ee2018-12-16 17:11:34 -08001DESCRIPTION = "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 = "6f2301d08e64a965ad36b401ec8dc2b24bc47075"
19
20SRC_URI = "git://github.com/TigerVNC/tigervnc.git;branch=1.9-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"
26
27# Keep sync with xorg-server in oe-core
28XORG_PN ?= "xorg-server"
29XORG_PV ?= "1.19.6"
30SRC_URI += "${XORG_MIRROR}/individual/xserver/${XORG_PN}-${XORG_PV}.tar.bz2;name=xorg"
31XORG_S = "${WORKDIR}/${XORG_PN}-${XORG_PV}"
32SRC_URI[xorg.md5sum] = "3e47777ff034a331aed2322b078694a8"
33SRC_URI[xorg.sha256sum] = "a732502f1db000cf36a376cd0c010ffdbf32ecdd7f1fa08ba7f5bdf9601cc197"
34
35# It is the directory containing the Xorg source for the
36# machine on which you are building TigerVNC.
37XSERVER_SOURCE_DIR="${S}/unix/xserver"
38
39do_patch[postfuncs] += "do_patch_xserver"
40do_patch_xserver () {
41 for subdir in Xext xkb GL hw/xquartz/bundle hw/xfree86/common; do
42 install -d ${XSERVER_SOURCE_DIR}/$subdir
43 done
44
45 for subdir in hw/dmx/doc man doc hw/dmx/doxygen; do
46 install -d ${XSERVER_SOURCE_DIR}/$subdir
47 done
48
49 sources="hw/xquartz/bundle/cpprules.in man/Xserver.man doc/smartsched \
50 hw/dmx/doxygen/doxygen.conf.in xserver.ent.in xkb/README.compiled \
51 hw/xfree86/xorgconf.cpp hw/xfree86/Xorg.sh.in"
52 for i in ${sources}; do
53 install -m 0644 ${XORG_S}/$i ${XSERVER_SOURCE_DIR}/$i;
54 done
55
56 cd ${XORG_S}
57 find . -type f | egrep '.*\.(c|h|am|ac|inc|m4|h.in|pc.in|man.pre|pl|txt)$' | \
58 xargs tar cf - | (cd ${XSERVER_SOURCE_DIR} && tar xf -)
59
60 cd ${XSERVER_SOURCE_DIR}
61 xserverpatch="${S}/unix/xserver119.patch"
62 echo "Apply $xserverpatch"
63 patch -p1 -b --suffix .vnc < $xserverpatch
64}
65
66EXTRA_OECONF = "--disable-xorg --disable-xnest --disable-xvfb --disable-dmx \
67 --disable-xwin --disable-xephyr --disable-kdrive --with-pic \
68 --disable-static --disable-xinerama \
69 --with-xkb-output=${localstatedir}/lib/xkb \
70 --disable-glx --disable-dri --disable-dri2 \
71 --disable-config-hal \
72 --disable-config-udev \
73 --without-dtrace \
74 --disable-unit-tests \
75 --disable-devel-docs \
76 --disable-selective-werror \
77 --disable-xshmfence \
78 --disable-config-udev \
79 --disable-dri3 \
80 --disable-libunwind \
81 --without-xmlto \
82 --enable-systemd-logind=no \
83 --disable-xinerama \
84 --disable-xwayland \
85"
86
87do_configure_append () {
88 olddir=`pwd`
89 cd ${XSERVER_SOURCE_DIR}
90
91 rm -rf aclocal-copy/
92 rm -f aclocal.m4
93
94 export ACLOCALDIR="${XSERVER_SOURCE_DIR}/aclocal-copy"
95 mkdir -p ${ACLOCALDIR}/
96 if [ -d ${STAGING_DATADIR_NATIVE}/aclocal ]; then
97 cp-noerror ${STAGING_DATADIR_NATIVE}/aclocal/ ${ACLOCALDIR}/
98 fi
99 if [ -d ${STAGING_DATADIR}/aclocal -a "${STAGING_DATADIR_NATIVE}/aclocal" != "${STAGING_DATADIR}/aclocal" ]; then
100 cp-noerror ${STAGING_DATADIR}/aclocal/ ${ACLOCALDIR}/
101 fi
102 ACLOCAL="aclocal --system-acdir=${ACLOCALDIR}/" autoreconf -Wcross --verbose --install --force ${EXTRA_AUTORECONF} $acpaths || bbfatal "autoreconf execution failed."
103 chmod +x ./configure
104 ${CACHED_CONFIGUREVARS} ./configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
105 cd $olddir
106}
107
108do_compile_append () {
109 olddir=`pwd`
110 cd ${XSERVER_SOURCE_DIR}
111
112 oe_runmake
113
114 cd $olddir
115}
116
117do_install_append() {
118 olddir=`pwd`
119 cd ${XSERVER_SOURCE_DIR}/hw/vnc
120
121 oe_runmake 'DESTDIR=${D}' install
122
123 cd $olddir
124}
125
126FILES_${PN} += " \
127 ${libdir}/xorg/modules/extensions \
128 ${datadir}/icons \
129"
130
131FILES_${PN}-dbg += "${libdir}/xorg/modules/extensions/.debug"