|
#snapshotver is year-month-day-svnrevision, generated by "make dist" |
|
|
%define snapshot 0 |
|
|
%define snapshotversion 201106280527 |
|
|
%define version 1.1.0 |
|
|
%define rel 4 |
|
|
|
|
1 |
Name: tigervnc |
Name: tigervnc |
2 |
Version: %{version} |
Version: 1.3.0 |
3 |
%if %{snapshot} |
Release: %mkrel 1 |
|
Release: %mkrel 0.%{snapshotversion}.%{rel} |
|
|
%else |
|
|
Release: %mkrel %{rel} |
|
|
%endif |
|
|
|
|
4 |
License: GPLv2+ |
License: GPLv2+ |
5 |
URL: http://www.tigervnc.com/ |
URL: http://www.tigervnc.com/ |
6 |
|
Source0: %{name}-%{version}.tar.bz2 |
|
Source0: %{name}-%{version}.tar.gz |
|
7 |
Source6: vncviewer.desktop |
Source6: vncviewer.desktop |
8 |
Source7: xserver110-fdr.patch |
|
9 |
Patch0: tigervnc-102434.patch |
#Patch mga3 |
10 |
Patch4: tigervnc-cookie.patch |
Patch1: tigervnc-cookie.patch |
11 |
Patch8: tigervnc-viewer-reparent.patch |
Patch2: tigervnc11-ldnow.patch |
12 |
Patch10: tigervnc11-ldnow.patch |
Patch3: tigervnc11-gethomedir.patch |
13 |
Patch11: tigervnc11-gethomedir.patch |
Patch4: tigervnc11-rh692048.patch |
14 |
Patch13: tigervnc11-rh692048.patch |
# Patch syncro fdr 20 |
15 |
Patch16: tigervnc11-fdr-xorg111.patch |
Patch5: tigervnc-fdr-inetd-nowait.patch |
16 |
Patch17: tigervnc11-fdr-xorg112.patch |
Patch6: tigervnc-fdr-setcursor-crash.patch |
17 |
Patch18: tigervnc11-fdr-java7.patch |
Patch7: tigervnc-fdr-manpages.patch |
18 |
Patch19: tigervnc11-fdr-xorg113.patch |
Patch8: tigervnc-fdr-getmaster.patch |
19 |
|
Patch9: tigervnc-fdr-shebang.patch |
20 |
|
# Patch from openmdv to build |
21 |
|
Patch10: tigervnc11-mdv-link.patch |
22 |
|
Patch11: tigervnc11-mdv-strfmt.patch |
23 |
|
Patch12: tigervnc11-mdv-buildir.patch |
24 |
|
|
25 |
|
|
26 |
|
|
27 |
|
|
28 |
BuildRequires: x11-server-source |
BuildRequires: x11-server-source |
29 |
BuildRequires: gettext-devel |
BuildRequires: gettext-devel |
30 |
BuildRequires: pkgconfig(x11) |
BuildRequires: pkgconfig(x11) |
44 |
BuildRequires: imagemagick |
BuildRequires: imagemagick |
45 |
BuildRequires: nasm |
BuildRequires: nasm |
46 |
BuildRequires: java-devel |
BuildRequires: java-devel |
47 |
BuildRequires: desktop-file-utils |
BuildRequires: desktop-file-utils |
48 |
|
BuildRequires: jpackage-utils |
49 |
|
BuildRequires: java-rpmbuild |
50 |
|
BUildRequires: fltk-devel |
51 |
|
BuildRequires: libtool |
52 |
|
BuildRequires: autoconf |
53 |
|
BUildRequires: libxi-devel |
54 |
|
BuildRequires: libxinerama-devel |
55 |
|
BuildRequires: freetype-devel |
56 |
|
BuildRequires: libxdmcp-devel |
57 |
|
BuildRequires: pam-devel |
58 |
|
BuildRequires: libjpeg-devel |
59 |
|
BuildRequires: cmake |
60 |
|
|
61 |
|
|
62 |
|
|
63 |
|
|
64 |
#------------------------------------------------------------------------------ |
#------------------------------------------------------------------------------ |
65 |
|
|
77 |
server. |
server. |
78 |
|
|
79 |
%files -f %{name}.lang |
%files -f %{name}.lang |
80 |
|
%_defaultdocdir/%{name}-%{version}/* |
81 |
%{_bindir}/vncviewer |
%{_bindir}/vncviewer |
82 |
%{_iconsdir}/* |
%{_iconsdir}/* |
83 |
%{_datadir}/applications/* |
%{_datadir}/applications/* |
155 |
%prep |
%prep |
156 |
%setup -q -n %{name}-%{version} |
%setup -q -n %{name}-%{version} |
157 |
|
|
158 |
%patch0 -p1 -b .102434 |
%patch12 -p1 -b .builddir |
159 |
%patch4 -p1 -b .cookie |
%patch1 -p1 -b .cookie |
160 |
%patch8 -p1 -b .viewer-reparent |
%patch2 -p1 -b .ldnow |
161 |
%patch10 -p1 -b .ldnow |
%patch3 -p1 -b .gethomedir |
162 |
%patch11 -p1 -b .gethomedir |
%patch4 -p1 -b .rh692048 |
163 |
%patch13 -p1 -b .rh692048 |
%patch11 -p1 -b .strfmt |
164 |
|
|
165 |
|
|
166 |
|
|
167 |
|
|
168 |
cp -r /usr/share/x11-server-source/* unix/xserver |
cp -r /usr/share/x11-server-source/* unix/xserver |
|
%patch16 -p1 -b .xorg111 |
|
169 |
pushd unix/xserver |
pushd unix/xserver |
170 |
for all in `find . -type f -perm -001`; do |
for all in `find . -type f -perm -001`; do |
171 |
chmod -x "$all" |
chmod -x "$all" |
172 |
done |
done |
173 |
patch -p1 -b --suffix .vnc < %{SOURCE7} |
patch -p1 -b --suffix .vnc < ../xserver114.patch |
174 |
%patch17 -p1 -b .xorg112 |
|
|
%patch19 -p1 -b .xorg113 |
|
175 |
popd |
popd |
176 |
|
|
177 |
%patch18 -p1 -b .java7 |
# Applied Debian patch to fix busy loop when run from inetd in nowait |
178 |
|
# mode (bug #920373). |
179 |
|
%patch5 -p1 -b .inetd-nowait |
180 |
|
|
181 |
|
%patch6 -p1 -b .setcursor-crash |
182 |
|
|
183 |
|
# Synchronise manpages and --help output (bug #980870). |
184 |
|
%patch7 -p1 -b .manpages |
185 |
|
|
186 |
|
# libvnc.so: don't use unexported GetMaster function (bug #744881 again). |
187 |
|
%patch8 -p1 -b .getmaster |
188 |
|
|
189 |
# Use newer gettext |
# Don't use shebang in vncserver script. |
190 |
sed -i 's/AM_GNU_GETTEXT_VERSION.*/AM_GNU_GETTEXT_VERSION([0.18.1])/' \ |
%patch9 -p1 -b .shebang |
191 |
configure.ac |
|
192 |
|
|
193 |
|
%patch10 -p1 -b .link |
194 |
|
|
195 |
%build |
%build |
|
# Temporary build with -fno-omit-frame-pointer, it causes problems |
|
|
export CFLAGS="$RPM_OPT_FLAGS -fno-omit-frame-pointer" |
|
|
export CXXFLAGS="$CFLAGS" |
|
196 |
|
|
197 |
autoreconf -fiv |
%{cmake} |
|
%configure2_5x --disable-static --with-system-jpeg |
|
198 |
%make |
%make |
199 |
|
cd .. |
|
# XXX: I'm not sure this define is actually needed |
|
|
# Need this for shared objects that reference X Server, or other modules symbols |
|
|
%define _disable_ld_no_undefined 1 |
|
|
# Search for modules in extra_module_dir before the default path. |
|
|
# This will allow fglrx to install its modified modules in more cleaner way. |
|
|
%define extra_module_dir %{_libdir}/xorg/extra-modules |
|
200 |
|
|
201 |
pushd unix/xserver |
pushd unix/xserver |
202 |
chmod +x configure |
rm -f configure |
203 |
autoreconf -fiv |
autoreconf -fiv |
204 |
|
%configure2_5x --disable-xorg --disable-xnest --disable-xvfb --disable-dmx \ |
205 |
|
--disable-xwin --disable-xephyr --disable-kdrive --with-pic \ |
206 |
|
--disable-static --disable-xinerama \ |
207 |
|
--with-default-font-path="catalogue:%{_sysconfdir}/X11/fontpath.d,built-ins" \ |
208 |
|
--with-fontdir=%{_datadir}/X11/fonts \ |
209 |
|
--with-xkb-output=%{_localstatedir}/lib/xkb \ |
210 |
|
--enable-install-libxf86config \ |
211 |
|
--enable-glx --disable-dri --enable-dri2 \ |
212 |
|
--disable-config-dbus \ |
213 |
|
--disable-config-hal \ |
214 |
|
--disable-config-udev \ |
215 |
|
--with-dri-driver-path=%{_libdir}/dri \ |
216 |
|
--without-dtrace \ |
217 |
|
--disable-unit-tests \ |
218 |
|
--disable-devel-docs \ |
219 |
|
--disable-selective-werror |
220 |
|
|
221 |
# After the "--disable-config-hal", most options are just a paste from |
%make |
|
# Mandriva's x11-server. We need to check what we can clean here (without |
|
|
# reducing features) |
|
|
%configure2_5x --disable-xorg \ |
|
|
--disable-xwin \ |
|
|
--disable-xvfb \ |
|
|
--disable-xnest \ |
|
|
--disable-dmx \ |
|
|
--disable-xfbdev \ |
|
|
--disable-xephyr \ |
|
|
--disable-kdrive \ |
|
|
--disable-config-dbus \ |
|
|
--disable-config-hal \ |
|
|
--with-log-dir=%{_logdir} \ |
|
|
--with-os-vendor="%distribution" \ |
|
|
--with-os-name="$(uname -s -r | sed -e s'/ /_/g')" \ |
|
|
--with-vendor-web="http://bugs.mageia.org" \ |
|
|
--with-extra-module-dir=%{extra_module_dir} \ |
|
|
--enable-xwrapper \ |
|
|
--enable-pam \ |
|
|
--without-dtrace --disable-unit-tests \ |
|
|
--disable-devel-docs --disable-docs \ |
|
|
--with-default-font-path="catalogue:%{_sysconfdir}/X11/fontpath.d" |
|
222 |
|
|
|
make |
|
223 |
popd |
popd |
224 |
|
|
225 |
|
|
226 |
# Build icons |
# Build icons |
227 |
pushd media |
pushd media |
228 |
|
%{cmake} |
229 |
%make |
%make |
230 |
|
|
231 |
popd |
popd |
232 |
|
|
233 |
# Build java |
# Build java |
234 |
pushd java/src/com/tigervnc/vncviewer |
pushd java |
235 |
%make all |
%{cmake} |
236 |
|
%make |
237 |
|
#cd .. |
238 |
popd |
popd |
239 |
|
|
240 |
%install |
%install |
241 |
rm -rf %{buildroot} |
rm -rf %{buildroot} |
242 |
|
pushd build |
243 |
%makeinstall_std |
%makeinstall_std |
244 |
|
popd |
245 |
|
|
246 |
pushd unix/xserver/hw/vnc |
pushd unix/xserver/hw/vnc |
247 |
%makeinstall_std |
%makeinstall_std |
258 |
|
|
259 |
mkdir %{buildroot}/%{_datadir}/applications |
mkdir %{buildroot}/%{_datadir}/applications |
260 |
desktop-file-install \ |
desktop-file-install \ |
261 |
--dir %{buildroot}%{_datadir}/applications \ |
--dir %{buildroot}%{_datadir}/applications \ |
262 |
%{SOURCE6} |
%{SOURCE6} |
263 |
|
|
264 |
%find_lang %{name} %{name}.lang |
%find_lang %{name} %{name}.lang |
265 |
|
|
266 |
# remove unwanted files |
# remove unwanted files |
267 |
rm -f %{buildroot}/%{_libdir}/xorg/modules/extensions/libvnc.la |
rm -f %{buildroot}/%{_libdir}/xorg/modules/extensions/libvnc.la |
268 |
|
|
269 |
|
# Install Java applet |
270 |
|
|
|
# java |
|
271 |
install -d -m 755 %{buildroot}%{_javadir} |
install -d -m 755 %{buildroot}%{_javadir} |
272 |
install -d -m 755 %{buildroot}%{_datadir}/vnc/classes |
install -d -m 755 %{buildroot}%{_datadir}/vnc/classes |
273 |
|
pushd java/build |
274 |
|
|
275 |
|
install -m 755 VncViewer.jar %{buildroot}%{_datadir}/vnc/classes/vncviewer-%{version}.jar |
276 |
|
popd |
277 |
|
|
278 |
pushd java/src/com/tigervnc/vncviewer |
pushd java |
279 |
make install INSTALL_DIR=%{buildroot}%{_datadir}/vnc/classes \ |
install -m 644 com/tigervnc/vncviewer/index.vnc %{buildroot}%{_datadir}/vnc/classes |
|
ARCHIVE=vncviewer-%{version}.jar |
|
280 |
popd |
popd |
281 |
|
|
282 |
pushd %{buildroot}%{_datadir}/vnc/classes |
pushd %{buildroot}%{_datadir}/vnc/classes |
283 |
mv vncviewer-%{version}.jar %{buildroot}%{_javadir} |
mv vncviewer-%{version}.jar %{buildroot}%{_javadir} |
284 |
ln -s %{_javadir}/vncviewer-%{version}.jar VncViewer.jar |
ln -s %{_javadir}/vncviewer-%{version}.jar VncViewer.jar |
285 |
popd |
popd |
286 |
|
|
287 |
pushd %{buildroot}%{_javadir} |
pushd %{buildroot}%{_javadir} |
288 |
ln -s vncviewer-%{version}.jar vncviewer.jar |
ln -s vncviewer-%{version}.jar vncviewer.jar |
289 |
ln -s vncviewer-%{version}.jar VncViewer.jar |
ln -s vncviewer-%{version}.jar VncViewer.jar |
290 |
popd |
popd |
291 |
|
|
292 |
|
|