channels: merging with master
[platform/upstream/freerdp.git] / freerdp.spec
1 # rpmbuild -ta freerdp-<...>.tar.gz
2
3 Name:           freerdp
4 Version:        1.0.1
5 Release:        1%{?dist}
6 Summary:        Remote Desktop Protocol functionality
7
8 Group:          Applications/Communications
9 License:        Apache License 2.0
10 URL:            http://www.freerdp.com/
11 Source0:        https://github.com/downloads/FreeRDP/FreeRDP/%{name}-%{version}.tar.gz
12 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
13
14 BuildRequires:  cmake
15 BuildRequires:  xmlto
16 BuildRequires:  openssl-devel
17 BuildRequires:  libX11-devel
18 BuildRequires:  libXext-devel
19 BuildRequires:  libXinerama-devel
20 BuildRequires:  libXcursor-devel
21 BuildRequires:  libXdamage-devel
22 BuildRequires:  libXv-devel
23 BuildRequires:  libxkbfile-devel
24 BuildRequires:  pulseaudio-libs-devel
25 BuildRequires:  cups-devel
26 BuildRequires:  alsa-lib-devel
27 BuildRequires:  pcsc-lite-devel
28 BuildRequires:  desktop-file-utils
29
30 %description
31 FreeRDP is a free implementation of the Remote Desktop Protocol (RDP)
32 according to the Microsoft Open Specifications.
33
34
35 %package        -n xfreerdp
36 Summary:        Remote Desktop Protocol client
37 Group:          Applications/Communications
38 Requires:       %{name}-libs = %{version}-%{release}
39 Requires:       %{name}-plugins-standard = %{version}-%{release}
40 %description    -n xfreerdp
41 FreeRDP is a free implementation of the Remote Desktop Protocol (RDP)
42 according to the Microsoft Open Specifications.
43
44
45 %package        libs
46 Summary:        Core libraries implementing the RDP protocol
47 Group:          Applications/Communications
48 %description    libs
49 libfreerdp-core can be embedded in applications.
50
51 libfreerdp-channels and libfreerdp-kbd might be convenient to use in X
52 applications together with libfreerdp-core.
53
54 libfreerdp-core can be extended with plugins handling RDP channels.
55
56 %package        plugins-standard
57 Summary:        Plugins for handling the standard RDP channels
58 Group:          Applications/Communications
59 Requires:       %{name}-libs = %{version}-%{release}
60 %description    plugins-standard
61 A set of plugins to the channel manager implementing the standard virtual
62 channels extending RDP core functionality. For instance, sounds, clipboard
63 sync, disk/printer redirection, etc.
64
65
66 %package        devel
67 Summary:        Libraries and header files for embedding and extending freerdp
68 Group:          Applications/Communications
69 Requires:       %{name}-libs = %{version}-%{release}
70 Requires:       pkgconfig
71 %description    devel
72 Header files and unversioned libraries for libfreerdp-core, libfreerdp-channels,
73 libfreerdp-locale, libfreerdp-cache, libfreerdp-codec, libfreerdp-rail,
74 libfreerdp-gdi and libfreerdp-utils.
75
76 %prep
77
78 %setup -q
79
80 cat << EOF > xfreerdp.desktop 
81 [Desktop Entry]
82 Type=Application
83 Name=X FreeRDP
84 NoDisplay=true
85 Comment=Connect to RDP server and display remote desktop
86 Icon=%{name}
87 Exec=/usr/bin/xfreerdp
88 Terminal=false
89 Categories=Network;RemoteAccess;
90 EOF
91
92
93 %build
94
95 cmake \
96         -DCMAKE_INSTALL_PREFIX:PATH=/usr \
97         -DWITH_CUPS:BOOL=ON \
98         -DWITH_PCSC:BOOL=ON \
99         -DWITH_PULSEAUDIO:BOOL=ON \
100         -DWITH_MACAUDIO:BOOL=ON \
101         -DWITH_X11:BOOL=ON \
102         -DWITH_XCURSOR:BOOL=ON \
103         -DWITH_XEXT:BOOL=ON \
104         -DWITH_XINERAMA:BOOL=ON \
105         -DWITH_XKBFILE:BOOL=ON \
106         -DWITH_XV:BOOL=ON \
107         -DWITH_ALSA:BOOL=ON \
108         -DWITH_CUNIT:BOOL=OFF \
109         -DWITH_DIRECTFB:BOOL=OFF \
110         -DWITH_FFMPEG:BOOL=OFF \
111         -DWITH_SSE2:BOOL=OFF \
112         .
113
114 make %{?_smp_mflags}
115
116
117 %install
118 rm -rf $RPM_BUILD_ROOT
119
120 make install DESTDIR=$RPM_BUILD_ROOT INSTALL='install -p'
121
122 desktop-file-install --dir=$RPM_BUILD_ROOT%{_datadir}/applications xfreerdp.desktop
123 install -p -D resources/FreeRDP_Icon_256px.png $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/256x256/apps/%{name}.png
124
125
126 %clean
127 rm -rf $RPM_BUILD_ROOT
128
129
130 %post
131 # This is no gtk application, but try to integrate nicely with GNOME if it is available
132 gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
133
134
135 %post libs -p /sbin/ldconfig
136
137
138 %postun libs -p /sbin/ldconfig
139
140
141 %files -n xfreerdp
142 %defattr(-,root,root,-)
143 %{_bindir}/xfreerdp
144 %{_mandir}/man1/xfreerdp.*
145 %{_datadir}/applications/xfreerdp.desktop
146 %{_datadir}/icons/hicolor/256x256/apps/%{name}.png
147
148 %files libs
149 %defattr(-,root,root,-)
150 %doc LICENSE README ChangeLog
151 %{_libdir}/lib%{name}-*.so.*
152 %dir %{_libdir}/%{name}/
153
154 %files plugins-standard
155 %defattr(-,root,root,-)
156 %{_libdir}/%{name}/*
157
158 %files devel
159 %defattr(-,root,root,-)
160 %{_includedir}/%{name}/
161 %{_libdir}/lib%{name}-*.so
162 %{_libdir}/pkgconfig/%{name}.pc
163
164
165 %changelog