]>
Commit | Line | Data |
---|---|---|
e2f5e569 | 1 | # TODO: |
8d102fea JB |
2 | # - what is libpcsc-winpr? (-DWITH_PCSC_WINPR) |
3 | # - fix DirectFB client build (orphaned code) | |
3f47f72e | 4 | # - WITH_IPP? |
dd410870 | 5 | # |
acdabdb6 JB |
6 | # Conditional build: |
7 | %bcond_without alsa # ALSA sound support | |
8 | %bcond_without cups # CUPS printing support | |
e2f5e569 | 9 | %bcond_with directfb # DirectFB client |
3f47f72e JB |
10 | %bcond_without ffmpeg # FFmpeg audio/video codecs support (covers H264, GSM, LAME, FAAC, FAAD2, SOXR) |
11 | %bcond_with faac # faac for AAC audio coding (if without ffmpeg) | |
12 | %bcond_with faad # faad2 for AAC audio decoding (if without ffmpeg) | |
13 | %bcond_with gsm # GSM audio codec (if without ffmpeg) | |
8d102fea | 14 | %bcond_without gstreamer # GStreamer sound support |
cccedb6c JB |
15 | # for now the kerberos5 support has to be disabled due to a bad state of its code. |
16 | # See: https://github.com/FreeRDP/FreeRDP/issues/4348 | |
17 | # See: https://github.com/FreeRDP/FreeRDP/issues/5746 | |
18 | %bcond_with kerberos5 # GSSAPI auth support | |
3f47f72e JB |
19 | %bcond_with lame # LAME for MP3 audio codec (if without ffmpeg) |
20 | %bcond_without opencl # OpenCL support | |
21 | %bcond_with openh264 # OpenH264 for H.264 codec (overrides ffmpeg for H264) | |
acdabdb6 JB |
22 | %bcond_without pcsc # SmartCard support via PCSC-lite library |
23 | %bcond_without pulseaudio # Pulseaudio sound support | |
3f47f72e | 24 | %bcond_with soxr # soxr for audio resampling (if without ffmpeg) |
8d102fea | 25 | %bcond_without systemd # systemd journal support |
e2f5e569 | 26 | %bcond_without wayland # Wayland client |
acdabdb6 | 27 | %bcond_without x11 # X11 client |
3f47f72e | 28 | %bcond_with x264 # X264 for H.264 codec (only if without ffmpeg and openh264) |
d231618e | 29 | %bcond_without sse2 # SSE2 and higher instructions (runtime detection with sse patch) |
dd410870 | 30 | |
6aef7f8d AM |
31 | %define freerdp_api 2 |
32 | ||
d231618e JB |
33 | %ifnarch %{ix86} %{x8664} x32 |
34 | %undefine with_sse2 | |
acdabdb6 | 35 | %endif |
e07ea24b | 36 | Summary: Remote Desktop Protocol client |
acdabdb6 | 37 | Summary(pl.UTF-8): Klient protokołu RDP |
b1788d3e | 38 | Name: freerdp2 |
090af3f0 | 39 | Version: 2.2.0 |
f9066b2e | 40 | Release: 1 |
acdabdb6 | 41 | License: Apache v2.0 |
e07ea24b | 42 | Group: Applications/Communications |
f9066b2e | 43 | Source0: https://pub.freerdp.com/releases/freerdp-%{version}.tar.gz |
090af3f0 | 44 | # Source0-md5: 16e7f6063cb0e211eeed83a2fe938462 |
d3f0825a AG |
45 | Patch0: freerdp-opt.patch |
46 | Patch1: freerdp-gsm.patch | |
f7c5a180 | 47 | Patch2: docbook-xsl.patch |
e07ea24b | 48 | URL: http://www.freerdp.com/ |
acdabdb6 | 49 | %{?with_directfb:BuildRequires: DirectFB-devel} |
3f47f72e | 50 | %{?with_opencl:BuildRequires: OpenCL-devel} |
acdabdb6 | 51 | %{?with_alsa:BuildRequires: alsa-lib-devel} |
cccedb6c | 52 | %{!?with_ffmpeg:BuildRequires: cairo-devel} |
8d102fea | 53 | BuildRequires: cmake >= 2.8 |
acdabdb6 | 54 | %{?with_cups:BuildRequires: cups-devel} |
e07ea24b | 55 | BuildRequires: desktop-file-utils |
f7c5a180 | 56 | BuildRequires: docbook-style-xsl-nons |
3f47f72e JB |
57 | %{?with_faac:BuildRequires: faac-devel} |
58 | %{?with_faad:BuildRequires: faad2-devel >= 2} | |
c7f505fc JB |
59 | # libavcodec >= 57.48.101, libavresample, libavutil |
60 | %{?with_ffmpeg:BuildRequires: ffmpeg-devel >= 3.1} | |
8d102fea JB |
61 | %{?with_gstreamer:BuildRequires: gstreamer-devel >= 1.0.5} |
62 | %{?with_gstreamer:BuildRequires: gstreamer-plugins-base-devel >= 1.0.5} | |
7809f0d2 JB |
63 | # MIT krb5 >= 1.13 also possible |
64 | %{?with_kerberos5:BuildRequires: heimdal-devel} | |
3f47f72e | 65 | %{?with_lame:BuildRequires: lame-libs-devel} |
8d102fea JB |
66 | %{?with_gsm:BuildRequires: libgsm-devel} |
67 | BuildRequires: libjpeg-devel | |
68 | %{?with_x264:BuildRequires: libx264-devel} | |
69 | %{?with_openh264:BuildRequires: openh264-devel} | |
3f47f72e | 70 | # also mbedtls possible |
e07ea24b | 71 | BuildRequires: openssl-devel |
dd410870 | 72 | %{?with_pcsc:BuildRequires: pcsc-lite-devel} |
acdabdb6 JB |
73 | BuildRequires: pkgconfig |
74 | %{?with_pulseaudio:BuildRequires: pulseaudio-devel} | |
57e67cef | 75 | BuildRequires: rpmbuild(macros) >= 1.742 |
3f47f72e | 76 | %{?with_soxr:BuildRequires: soxr-devel} |
8d102fea | 77 | %{?with_systemd:BuildRequires: systemd-devel >= 1:209} |
e2f5e569 | 78 | %{?with_wayland:BuildRequires: wayland-devel} |
e07ea24b | 79 | BuildRequires: xmlto |
cccedb6c | 80 | %{?with_wayland:BuildRequires: xorg-lib-libxkbcommon-devel} |
8d102fea | 81 | %if %{with x11} |
e07ea24b | 82 | BuildRequires: xorg-lib-libX11-devel |
e5316440 ER |
83 | BuildRequires: xorg-lib-libXcursor-devel |
84 | BuildRequires: xorg-lib-libXdamage-devel | |
e07ea24b | 85 | BuildRequires: xorg-lib-libXext-devel |
acdabdb6 | 86 | BuildRequires: xorg-lib-libXfixes-devel |
e07ea24b | 87 | BuildRequires: xorg-lib-libXinerama-devel |
cccedb6c | 88 | BuildRequires: xorg-lib-libXrandr-devel |
acdabdb6 | 89 | BuildRequires: xorg-lib-libXtst-devel |
7d17d2a0 | 90 | BuildRequires: xorg-lib-libXv-devel |
cccedb6c | 91 | BuildRequires: xorg-lib-libxkbfile-devel |
e2f5e569 | 92 | %endif |
acdabdb6 | 93 | BuildRequires: zlib-devel |
e5316440 | 94 | Requires: %{name}-libs = %{version}-%{release} |
acdabdb6 | 95 | Requires: hicolor-icon-theme |
e5316440 | 96 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
e07ea24b AM |
97 | |
98 | %description | |
8d102fea | 99 | FreeRDP is Remote Desktop Protocol (RDP) client. |
e07ea24b AM |
100 | |
101 | xfreerdp can connect to RDP servers such as Microsoft Windows | |
102 | machines, xrdp and VirtualBox. | |
103 | ||
acdabdb6 JB |
104 | %description -l pl.UTF-8 |
105 | xfreerdp to klient protokołu RDP (Remote Desktop Protocol) z projektu | |
106 | FreeRDP. | |
107 | ||
108 | xfreerdp może łączyć się z serwerami RDP, takimi jak maszyny z | |
109 | Microsoft Windows, xrdp oraz VirtualBox. | |
110 | ||
111 | %package dfb | |
112 | Summary: DirectFB based Remote Desktop Protocol klient | |
113 | Summary(pl.UTF-8): Klient protokołu RDP oparty na DirectFB | |
114 | Group: Applications/Communications | |
8d102fea JB |
115 | Requires: %{name} = %{version}-%{release} |
116 | Obsoletes: freerdp-dfb < 2 | |
acdabdb6 JB |
117 | |
118 | %description dfb | |
119 | DirectFB based Remote Desktop Protocol klient. | |
120 | ||
121 | dfreerdp can connect to RDP servers such as Microsoft Windows | |
122 | machines, xrdp and VirtualBox. | |
123 | ||
8d102fea | 124 | %description dfb -l pl.UTF-8 |
acdabdb6 JB |
125 | Klient protokołu RDP oparty na DirectFB. |
126 | ||
127 | dfreerdp może łączyć się z serwerami RDP, takimi jak maszyny z | |
128 | Microsoft Windows, xrdp oraz VirtualBox. | |
129 | ||
8d102fea JB |
130 | %package wayland |
131 | Summary: Wayland based Remote Desktop Protocol klient | |
132 | Summary(pl.UTF-8): Klient protokołu RDP oparty na Wayland | |
133 | Group: Applications/Communications | |
134 | Requires: %{name} = %{version}-%{release} | |
135 | ||
136 | %description wayland | |
137 | Wayland based Remote Desktop Protocol klient. | |
138 | ||
139 | wlfreerdp can connect to RDP servers such as Microsoft Windows | |
140 | machines, xrdp and VirtualBox. | |
141 | ||
142 | %description wayland -l pl.UTF-8 | |
143 | Klient protokołu RDP oparty na Wayland. | |
144 | ||
145 | wlfreerdp może łączyć się z serwerami RDP, takimi jak maszyny z | |
146 | Microsoft Windows, xrdp oraz VirtualBox. | |
147 | ||
148 | %package x11 | |
149 | Summary: X11 based Remote Desktop Protocol klient | |
150 | Summary(pl.UTF-8): Klient protokołu RDP oparty na X11 | |
151 | Group: Applications/Communications | |
152 | Requires: %{name} = %{version}-%{release} | |
153 | Provides: xfreerdp = %{version}-%{release} | |
154 | Obsoletes: freerdp < 2 | |
155 | ||
156 | %description x11 | |
157 | X11 based Remote Desktop Protocol klient. | |
158 | ||
159 | xfreerdp can connect to RDP servers such as Microsoft Windows | |
160 | machines, xrdp and VirtualBox. | |
161 | ||
162 | %description x11 -l pl.UTF-8 | |
163 | Klient protokołu RDP oparty na X11. | |
164 | ||
165 | xfreerdp może łączyć się z serwerami RDP, takimi jak maszyny z | |
166 | Microsoft Windows, xrdp oraz VirtualBox. | |
167 | ||
dd410870 | 168 | %package libs |
e5316440 | 169 | Summary: Core libraries implementing the RDP protocol |
acdabdb6 JB |
170 | Summary(pl.UTF-8): Główne biblioteki implementujące protokół RDP |
171 | Group: Libraries | |
e5316440 | 172 | |
acdabdb6 | 173 | %description libs |
8d102fea | 174 | Core libraries implementing the RDP protocol. |
e07ea24b | 175 | |
acdabdb6 | 176 | %description libs -l pl.UTF-8 |
8d102fea | 177 | Główne biblioteki implementujące protokół RDP. |
acdabdb6 JB |
178 | |
179 | %package devel | |
8d102fea JB |
180 | Summary: Development files for FreeRDP 2 libraries |
181 | Summary(pl.UTF-8): Pliki programistyczne bibliotek FreeRDP 2 | |
acdabdb6 JB |
182 | Group: Development/Libraries |
183 | Requires: %{name}-libs = %{version}-%{release} | |
184 | ||
185 | %description devel | |
186 | This package contains the header files for developing applications | |
8d102fea | 187 | that use FreeRDP 2 libraries. |
acdabdb6 JB |
188 | |
189 | %description devel -l pl.UTF-8 | |
190 | Ten pakiet zawiera pliki nagłówkowe do tworzenia aplikacji | |
8d102fea | 191 | wykorzystujących biblioteki FreeRDP 2. |
acdabdb6 | 192 | |
e07ea24b | 193 | %prep |
f9066b2e | 194 | %setup -q -n freerdp-%{version} |
acdabdb6 | 195 | %patch0 -p1 |
8d102fea | 196 | %patch1 -p1 |
f7c5a180 | 197 | %patch2 -p1 |
e07ea24b AM |
198 | |
199 | cat << EOF > xfreerdp.desktop | |
200 | [Desktop Entry] | |
201 | Type=Application | |
202 | Name=X FreeRDP | |
203 | NoDisplay=true | |
204 | Comment=Connect to RDP server and display remote desktop | |
acdabdb6 | 205 | Comment[pl]=Połączenie z serwerem RDP i wyświetlanie zdalnego pulpitu |
e07ea24b AM |
206 | Icon=%{name} |
207 | Exec=%{_bindir}/xfreerdp | |
208 | Terminal=false | |
209 | Categories=Network;RemoteAccess; | |
210 | EOF | |
211 | ||
e07ea24b | 212 | %build |
e5316440 ER |
213 | install -d build |
214 | cd build | |
acdabdb6 JB |
215 | %cmake .. \ |
216 | -DCMAKE_INSTALL_LIBDIR:PATH=%{_lib} \ | |
8bd931f3 | 217 | %{cmake_on_off alsa WITH_ALSA} \ |
cccedb6c | 218 | %{!?with_ffmpeg:-DWITH_CAIRO=ON} \ |
acdabdb6 | 219 | -DWITH_CUNIT=OFF \ |
8bd931f3 | 220 | %{cmake_on_off cups WITH_CUPS} \ |
d2cddd3f | 221 | -DWITH_DEBUG_LICENSE=ON \ |
8bd931f3 | 222 | %{cmake_on_off directfb WITH_DIRECTFB} \ |
3f47f72e JB |
223 | %{cmake_on_off ffmpeg WITH_DSP_FFMPEG} \ |
224 | %{cmake_on_off faac WITH_FAAC} \ | |
225 | %{cmake_on_off faad WITH_FAAD2} \ | |
8bd931f3 JB |
226 | %{cmake_on_off ffmpeg WITH_FFMPEG} \ |
227 | %{cmake_on_off gsm WITH_GSM} \ | |
228 | %{cmake_on_off gstreamer WITH_GSTREAMER_1_0} \ | |
229 | %{cmake_on_off kerberos5 WITH_GSSAPI} \ | |
6aef7f8d | 230 | -DWITH_JPEG=ON \ |
8bd931f3 | 231 | %{cmake_on_off systemd WITH_LIBSYSTEMD} \ |
3f47f72e | 232 | %{cmake_on_off opencl WITH_OPENCL} \ |
8bd931f3 | 233 | %{cmake_on_off openh264 WITH_OPENH264} \ |
8d102fea | 234 | -DWITH_OSS=ON \ |
8bd931f3 JB |
235 | %{cmake_on_off pcsc WITH_PCSC} \ |
236 | %{cmake_on_off pulseaudio WITH_PULSE} \ | |
acdabdb6 | 237 | -DWITH_SERVER=ON \ |
3f47f72e | 238 | %{cmake_on_off soxr WITH_SOXR} \ |
8bd931f3 | 239 | %{cmake_on_off sse2 WITH_SSE2} \ |
cccedb6c | 240 | %{cmake_on_off ffmpeg WITH_SWSCALE} \ |
8bd931f3 JB |
241 | %{cmake_on_off wayland WITH_WAYLAND} \ |
242 | %{cmake_on_off x11 WITH_X11} \ | |
243 | %{cmake_on_off x264 WITH_X264} \ | |
e5316440 ER |
244 | -DWITH_XCURSOR=ON \ |
245 | -DWITH_XEXT=ON \ | |
246 | -DWITH_XINERAMA=ON \ | |
247 | -DWITH_XKBFILE=ON \ | |
acdabdb6 | 248 | -DWITH_XV=ON |
e5316440 ER |
249 | |
250 | %{__make} | |
e07ea24b AM |
251 | |
252 | %install | |
253 | rm -rf $RPM_BUILD_ROOT | |
8d102fea | 254 | |
dd410870 | 255 | %{__make} -C build install \ |
e5316440 ER |
256 | INSTALL="install -p" \ |
257 | DESTDIR=$RPM_BUILD_ROOT | |
e07ea24b | 258 | |
e07ea24b | 259 | desktop-file-install --dir=$RPM_BUILD_ROOT%{_desktopdir} xfreerdp.desktop |
8d102fea | 260 | install -p -D resources/FreeRDP_Icon_256px.png $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/256x256/apps/%{name}.png |
e07ea24b | 261 | |
e07ea24b AM |
262 | %clean |
263 | rm -rf $RPM_BUILD_ROOT | |
264 | ||
e07ea24b | 265 | %post |
acdabdb6 JB |
266 | %update_icon_cache hicolor |
267 | ||
268 | %postun | |
269 | %update_icon_cache hicolor | |
e07ea24b | 270 | |
e5316440 ER |
271 | %post libs -p /sbin/ldconfig |
272 | %postun libs -p /sbin/ldconfig | |
e07ea24b AM |
273 | |
274 | %files | |
275 | %defattr(644,root,root,755) | |
cccedb6c | 276 | %attr(755,root,root) %{_bindir}/freerdp-proxy |
e2f5e569 | 277 | %attr(755,root,root) %{_bindir}/freerdp-shadow-cli |
e2f5e569 AO |
278 | %attr(755,root,root) %{_bindir}/winpr-hash |
279 | %attr(755,root,root) %{_bindir}/winpr-makecert | |
b1788d3e | 280 | %{_iconsdir}/hicolor/256x256/apps/freerdp2.png |
6aef7f8d AM |
281 | %{_mandir}/man1/freerdp-shadow-cli.1* |
282 | %{_mandir}/man1/winpr-hash.1* | |
283 | %{_mandir}/man1/winpr-makecert.1* | |
a6cea45d | 284 | %{_mandir}/man7/wlog.7* |
acdabdb6 | 285 | |
e2f5e569 | 286 | %if %{with directfb} |
acdabdb6 JB |
287 | %files dfb |
288 | %defattr(644,root,root,755) | |
8d102fea | 289 | %doc doc/README.directfb |
acdabdb6 | 290 | %attr(755,root,root) %{_bindir}/dfreerdp |
e2f5e569 | 291 | %endif |
e07ea24b | 292 | |
8d102fea JB |
293 | %if %{with wayland} |
294 | %files wayland | |
295 | %defattr(644,root,root,755) | |
296 | %attr(755,root,root) %{_bindir}/wlfreerdp | |
6aef7f8d | 297 | %{_mandir}/man1/wlfreerdp.1* |
8d102fea JB |
298 | %endif |
299 | ||
300 | %if %{with x11} | |
301 | %files x11 | |
302 | %defattr(644,root,root,755) | |
303 | %attr(755,root,root) %{_bindir}/xfreerdp | |
304 | %{_desktopdir}/xfreerdp.desktop | |
305 | %{_mandir}/man1/xfreerdp.1* | |
306 | %endif | |
307 | ||
e07ea24b AM |
308 | %files libs |
309 | %defattr(644,root,root,755) | |
cccedb6c | 310 | %doc ChangeLog README.md |
6aef7f8d AM |
311 | %attr(755,root,root) %{_libdir}/libfreerdp-client%{freerdp_api}.so.*.*.* |
312 | %attr(755,root,root) %ghost %{_libdir}/libfreerdp-client%{freerdp_api}.so.2 | |
313 | %attr(755,root,root) %{_libdir}/libfreerdp-server%{freerdp_api}.so.*.*.* | |
314 | %attr(755,root,root) %ghost %{_libdir}/libfreerdp-server%{freerdp_api}.so.2 | |
315 | %attr(755,root,root) %{_libdir}/libfreerdp-shadow%{freerdp_api}.so.*.*.* | |
316 | %attr(755,root,root) %ghost %{_libdir}/libfreerdp-shadow%{freerdp_api}.so.2 | |
317 | %attr(755,root,root) %{_libdir}/libfreerdp-shadow-subsystem%{freerdp_api}.so.*.*.* | |
318 | %attr(755,root,root) %ghost %{_libdir}/libfreerdp-shadow-subsystem%{freerdp_api}.so.2 | |
319 | %attr(755,root,root) %{_libdir}/libfreerdp%{freerdp_api}.so.*.*.* | |
320 | %attr(755,root,root) %ghost %{_libdir}/libfreerdp%{freerdp_api}.so.2 | |
321 | %attr(755,root,root) %{_libdir}/libuwac0.so.*.*.* | |
322 | %attr(755,root,root) %ghost %{_libdir}/libuwac0.so.0 | |
323 | %attr(755,root,root) %{_libdir}/libwinpr%{freerdp_api}.so.*.*.* | |
324 | %attr(755,root,root) %ghost %{_libdir}/libwinpr%{freerdp_api}.so.2 | |
325 | %attr(755,root,root) %{_libdir}/libwinpr-tools%{freerdp_api}.so.*.*.* | |
326 | %attr(755,root,root) %ghost %{_libdir}/libwinpr-tools%{freerdp_api}.so.2 | |
acdabdb6 JB |
327 | |
328 | %files devel | |
329 | %defattr(644,root,root,755) | |
6aef7f8d AM |
330 | %attr(755,root,root) %{_libdir}/libfreerdp-client%{freerdp_api}.so |
331 | %attr(755,root,root) %{_libdir}/libfreerdp-server%{freerdp_api}.so | |
332 | %attr(755,root,root) %{_libdir}/libfreerdp-shadow%{freerdp_api}.so | |
333 | %attr(755,root,root) %{_libdir}/libfreerdp-shadow-subsystem%{freerdp_api}.so | |
334 | %attr(755,root,root) %{_libdir}/libfreerdp%{freerdp_api}.so | |
335 | %attr(755,root,root) %{_libdir}/libuwac0.so | |
336 | %attr(755,root,root) %{_libdir}/libwinpr%{freerdp_api}.so | |
337 | %attr(755,root,root) %{_libdir}/libwinpr-tools%{freerdp_api}.so | |
e2f5e569 AO |
338 | %{_includedir}/freerdp2 |
339 | %{_includedir}/uwac0 | |
340 | %{_includedir}/winpr2 | |
341 | %{_pkgconfigdir}/freerdp-client2.pc | |
342 | %{_pkgconfigdir}/freerdp-server2.pc | |
343 | %{_pkgconfigdir}/freerdp-shadow2.pc | |
344 | %{_pkgconfigdir}/freerdp2.pc | |
345 | %{_pkgconfigdir}/uwac0.pc | |
346 | %{_pkgconfigdir}/winpr-tools2.pc | |
347 | %{_pkgconfigdir}/winpr2.pc | |
8d102fea JB |
348 | %{_libdir}/cmake/FreeRDP-Client2 |
349 | %{_libdir}/cmake/FreeRDP-Server2 | |
350 | %{_libdir}/cmake/FreeRDP-Shadow2 | |
351 | %{_libdir}/cmake/FreeRDP2 | |
352 | %{_libdir}/cmake/WinPR2 | |
353 | %{_libdir}/cmake/uwac0 |