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