Summary(pl.UTF-8): System zdalnego dostępu TigerVNC
Name: tigervnc
Version: 1.3.0
-Release: 2
+Release: 9
License: GPL v2
Group: X11/Applications/Networking
Source0: http://download.sourceforge.net/tigervnc/%{name}-%{version}.tar.bz2
Source1: %{name}.desktop
Source2: vncserver.init
Source3: vncserver.sysconfig
+Source4: vncserver.target
+Source5: vncserver-service-generator
Patch0: %{name}-cookie.patch
Patch1: %{name}-ldnow.patch
-Patch2: %{name}-rh102434.patch
Patch3: %{name}-as-needed.patch
Patch4: %{name}-ipv6.patch
Patch5: %{name}-rh692048.patch
Patch6: no-bashizm.patch
Patch7: format-security.patch
Patch8: %{name}-typecast.patch
-Patch9: xserver.patch
+Patch9: tigervnc-xstartup.patch
+Patch10: xserver.patch
+Patch11: tigervnc-getmaster.patch
+Patch12: tigervnc-setcursor-crash.patch
+Patch13: tigervnc-xserver-1.15.patch
+Patch14: tigervnc-zrle-crash.patch
URL: http://www.tigervnc.com/
BuildRequires: ImageMagick
BuildRequires: ImageMagick-coder-png
BuildRequires: perl-base
BuildRequires: pixman-devel >= 0.16.0
BuildRequires: pkgconfig >= 1:0.19
+BuildRequires: rpmbuild(macros) >= 1.647
BuildRequires: xorg-app-mkfontscale
BuildRequires: xorg-font-font-util >= 1.1
BuildRequires: xorg-lib-libX11-devel
BuildRequires: xorg-lib-libpciaccess-devel >= 0.13
BuildRequires: xorg-lib-libxkbfile-devel
BuildRequires: xorg-lib-libxkbui-devel >= 1.0.2
+BuildRequires: xorg-lib-libxshmfence-devel >= 1.1
BuildRequires: xorg-lib-xtrans-devel >= 1.2.2
BuildRequires: xorg-proto-bigreqsproto-devel >= 1.1.0
BuildRequires: xorg-proto-damageproto-devel >= 1.1
+BuildRequires: xorg-proto-dri3proto-devel >= 1.0
BuildRequires: xorg-proto-fixesproto-devel >= 4.1
BuildRequires: xorg-proto-fontcacheproto-devel
BuildRequires: xorg-proto-fontsproto-devel
BuildRequires: xorg-proto-glproto-devel >= 1.4.10
BuildRequires: xorg-proto-inputproto-devel >= 1.9.99.902
BuildRequires: xorg-proto-kbproto-devel >= 1.0.3
+BuildRequires: xorg-proto-presentproto-devel >= 1.0
BuildRequires: xorg-proto-printproto-devel
BuildRequires: xorg-proto-randrproto-devel >= 1.3
BuildRequires: xorg-proto-recordproto-devel
Summary(pl.UTF-8): X serwer VNC - wersja TigerVNC
Group: X11/Applications/Networking
Requires(post,preun): /sbin/chkconfig
+Requires(post,preun,postun): systemd-units >= 38
Requires: xorg-app-rgb
# for vncpasswd tool
Requires: %{name}-utils = %{version}-%{release}
# for mcookie
Requires: util-linux
Requires: libjpeg-turbo
+Requires: systemd-units >= 38
Requires: xkeyboard-config
Requires: xorg-app-xauth
Requires: xorg-app-xkbcomp
%setup -q
%patch0 -p1
%patch1 -p1
-%patch2 -p1
%patch3 -p1
%patch4 -p0
%patch5 -p1
%patch6 -p1
%patch7 -p1
%patch8 -p1
+%patch9 -p1
+%patch11 -p1
+%patch12 -p1
+%patch14 -p1
cp -a %{_usrsrc}/xorg-xserver-server-%{_xserverver}/* unix/xserver
+%patch13 -p1
+
cd unix/xserver
-patch -p1 <%{PATCH9}
-cd -
+%patch10 -p1
%build
%cmake .
--disable-xfbdev \
--disable-dri \
--enable-dri2 \
+ --enable-dri3 \
--with-pic \
--disable-static \
--disable-xinerama \
--disable-composite \
+ --disable-wayland \
--enable-glx \
--enable-glx-tls \
--enable-aiglx \
install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/vncserver
install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/vncserver
+install -d $RPM_BUILD_ROOT{%{systemdunitdir},/lib/systemd/system-generators}
+install -p %{SOURCE4} $RPM_BUILD_ROOT%{systemdunitdir}/vncserver.target
+install -p %{SOURCE5} $RPM_BUILD_ROOT/lib/systemd/system-generators/vncserver-service-generator
+ln -s /dev/null $RPM_BUILD_ROOT%{systemdunitdir}/vncserver.service
+
%{__rm} -r $RPM_BUILD_ROOT%{_docdir}
%find_lang %{name}
%post server
/sbin/chkconfig --add vncserver
%service vncserver restart "VNC server"
+NORESTART=1
+%systemd_post vncserver.target
%preun server
if [ "$1" = "0" ]; then
%service vncserver stop
/sbin/chkconfig --del vncserver
fi
+%systemd_preun vncserver.target
+
+%postun server
+%systemd_reload
+
+%triggerpostun server -- tigervnc-server < 1.3.0-5
+[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
+[ ${RPM_ENABLE_SYSTEMD_SERVICE:-yes} = no ] && return 1
+export SYSTEMD_LOG_LEVEL=warning SYSTEMD_LOG_TARGET=syslog
+if [ "$(echo /etc/rc.d/rc[0-6].d/S[0-9][0-9]vncserver)" != "/etc/rc.d/rc[0-6].d/S[0-9][0-9]vncserver" ]; then
+ /bin/systemctl --quiet enable vncserver.target || :
+fi
%files -f %{name}.lang
%defattr(644,root,root,755)
%attr(755,root,root) %{_bindir}/x0vncserver
%attr(754,root,root) /etc/rc.d/init.d/vncserver
%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/vncserver
+%attr(755,root,root) /lib/systemd/system-generators/vncserver-service-generator
+%{systemdunitdir}/vncserver.target
+%{systemdunitdir}/vncserver.service
%{_mandir}/man1/Xvnc.1*
%{_mandir}/man1/vncserver.1*
%{_mandir}/man1/x0vncserver.1*