]> git.pld-linux.org Git - packages/xen.git/blob - xen.spec
6cc3d29985d79cf20e600151bb90665d84e30999
[packages/xen.git] / xen.spec
1 #
2 # TODO:
3 #  - most of the qemu config options aren't detected (curses, NPTL, vde, fdt)
4 #  - package the ocaml stuff
5 #
6 # Conditional build:
7 %bcond_without  hvm             # build with hvm (full virtualization) support
8
9 %define xen_extfiles_url        http://xenbits.xensource.com/xen-extfiles
10 Summary:        Xen - a virtual machine monitor
11 Summary(pl.UTF-8):      Xen - monitor maszyny wirtualnej
12 Name:           xen
13 Version:        4.1.2
14 Release:        1
15 License:        GPL
16 Group:          Applications/System
17 Source0:        http://bits.xensource.com/oss-xen/release/%{version}/%{name}-%{version}.tar.gz
18 # Source0-md5:  73561faf3c1b5e36ec5c089b5db848ad
19 # used by stubdoms
20 Source10: %{xen_extfiles_url}/lwip-1.3.0.tar.gz
21 # Source10-md5: 36cc57650cffda9a0269493be2a169bb
22 Source11: %{xen_extfiles_url}/newlib-1.16.0.tar.gz
23 # Source11-md5: bf8f1f9e3ca83d732c00a79a6ef29bc4
24 Source12: %{xen_extfiles_url}/zlib-1.2.3.tar.gz
25 # Source12-md5: debc62758716a169df9f62e6ab2bc634
26 Source13: %{xen_extfiles_url}/pciutils-2.2.9.tar.bz2
27 # Source13-md5: cec05e7785497c5e19da2f114b934ffd
28 Source14: %{xen_extfiles_url}/grub-0.97.tar.gz
29 # Source14-md5: cd3f3eb54446be6003156158d51f4884
30 Source15: %{xen_extfiles_url}/ipxe-git-v1.0.0.tar.gz
31 # Source15-md5: fb7df96781d337899066d82059346885
32 Patch0:         %{name}-python_scripts.patch
33 Patch1:         %{name}-symbols.patch
34 Patch2:         %{name}-curses.patch
35 Patch3:         %{name}-gcc.patch
36 Patch4:         %{name}-xz.patch
37 URL:            http://www.cl.cam.ac.uk/Research/SRG/netos/xen/index.html
38 BuildRequires:  SDL-devel
39 %{?with_hvm:BuildRequires:      bcc}
40 BuildRequires:  curl-devel
41 BuildRequires:  e2fsprogs-devel
42 BuildRequires:  gcc >= 5:3.4
43 BuildRequires:  gettext-devel
44 BuildRequires:  latex2html
45 BuildRequires:  libidn-devel
46 BuildRequires:  ncurses-devel
47 BuildRequires:  pciutils-devel
48 BuildRequires:  pkgconfig
49 BuildRequires:  python-devel
50 BuildRequires:  rpm-pythonprov
51 BuildRequires:  rpmbuild(macros) >= 1.268
52 #BuildRequires: texlive-dvips
53 #BuildRequires: texlive-latex-data
54 BuildRequires:  texlive-latex-psnfss
55 BuildRequires:  transfig
56 BuildRequires:  which
57 BuildRequires:  zlib-devel
58 Requires(post,preun):   /sbin/chkconfig
59 Requires:       %{name}-libs = %{version}-%{release}
60 Requires:       ZopeInterface
61 Requires:       bridge-utils
62 Requires:       coreutils
63 Requires:       diffutils
64 Requires:       gawk
65 Requires:       iptables
66 Requires:       kernel(xen0)
67 Requires:       losetup
68 Requires:       net-tools
69 Requires:       python-%{name} = %{version}-%{release}
70 Requires:       rc-scripts
71 Requires:       sed
72 Requires:       util-linux
73 Requires:       which
74 Obsoletes:      xen-doc
75 ExclusiveArch:  %{ix86} %{x8664}
76 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
77
78 # some PPC/SPARC boot image in ELF format
79 %define         _noautostrip    .*%{_datadir}/xen/qemu/openbios-.*
80
81 %description
82 This package contains the Xen hypervisor and Xen tools, needed to run
83 virtual machines on x86 systems, together with the kernel-xen*
84 packages. Information on how to use Xen can be found at the Xen
85 project pages.
86
87 Virtualisation can be used to run multiple versions or multiple Linux
88 distributions on one system, or to test untrusted applications in a
89 sandboxed environment. Note that the Xen technology is still in
90 development, and this RPM has received extremely little testing. Don't
91 be surprised if this RPM eats your data, drinks your coffee or makes
92 fun of you in front of your friends.
93
94 %description -l pl.UTF-8
95 Ten pakiet zawiera nadzorcę oraz narzędzia Xen, potrzebne do
96 uruchamiania wirtualnych maszyn w systemach x86, wraz z pakietami
97 kernel-xen*. Informacje jak używać Xena można znaleźć na stronach
98 projektu.
99
100 Wirtualizacja może być używana do uruchamiania wielu wersji lub wielu
101 dystrybucji Linuksa na jednym systemie lub do testowania nie zaufanych
102 aplikacji w odizolowanym środowisku. Należy zauważyć, że technologia
103 Xen jest ciągle rozwijana, a ten RPM był słabo testowany. Nie należy
104 być zdziwionym, jeśli ten pakiet zje dane, wypije całą kawę czy będzie
105 się wyśmiewał w obecności przyjaciół.
106
107 %package libs
108 Summary:        xen libraries
109 Summary(pl.UTF-8):      Biblioteki xena
110 Group:          Libraries
111
112 %description libs
113 xen libraries.
114
115 %description libs -l pl.UTF-8
116 Biblioteki xena.
117
118 %package devel
119 Summary:        Header files for xen
120 Summary(pl.UTF-8):      Pliki nagłówkowe xena
121 Group:          Development/Libraries
122 Requires:       %{name}-libs = %{version}-%{release}
123
124 %description devel
125 Header files for xen.
126
127 %description devel -l pl.UTF-8
128 Pliki nagłówkowe xena.
129
130 %package static
131 Summary:        Static xen libraries
132 Summary(pl.UTF-8):      Statyczne biblioteki xena
133 Group:          Development/Libraries
134 Requires:       %{name}-devel = %{version}-%{release}
135
136 %description static
137 Static xen libraries.
138
139 %description static -l pl.UTF-8
140 Statyczne biblioteki xena.
141
142 %package udev
143 Summary:        xen udev scripts
144 Summary(pl.UTF-8):      Skrypty udev dla xena
145 Group:          Applications/System
146
147 %description udev
148 xen udev scripts.
149
150 %description udev -l pl.UTF-8
151 Skrypty udev dla xena.
152
153 %package xend
154 Summary:        xend daemon
155 Summary(pl.UTF-8):      Demon xend
156 Group:          Daemons
157
158 %description xend
159 xend daemon.
160
161 %description xend -l pl.UTF-8
162 Demon xend.
163
164 %package -n python-xen
165 Summary:        xen Python modules
166 Summary(pl.UTF-8):      Moduły Pythona dla xena
167 Group:          Libraries
168 Conflicts:      xen < 3.2.1-0.3
169
170 %description -n python-xen
171 xen Python modules.
172
173 %description -n python-xen -l pl.UTF-8
174 Moduły Pythona dla xena.
175
176 %package -n bash-completion-%{name}
177 Summary:    bash-completion for xen
178 Group:      Applications/Shells
179 Requires:   %{name} = %{version}-%{release}
180 Requires:   bash-completion
181
182 %description -n bash-completion-%{name}
183 This package provides bash-completion for xen.
184
185 %prep
186 %setup -q
187 %patch0 -p1
188 %patch1 -p1
189 %patch2 -p1
190 #%%patch3 -p1
191 %patch4 -p1
192
193 %{__rm} -v tools/check/*.orig
194
195 # stubdom sources
196 ln -s %{SOURCE10} %{SOURCE11} %{SOURCE12} %{SOURCE13} %{SOURCE14} stubdom
197 ln -s %{PATCH23} stubdom/grub.patches/99grub-ext4-support.patch
198 ln -s %{SOURCE15} tools/firmware/etherboot/ipxe.tar.gz
199
200 %build
201 CFLAGS="%{rpmcflags} -I/usr/include/ncurses" \
202 CXXFLAGS="%{rpmcflags} -I/usr/include/ncurses" \
203 %{__make} -j1 xen tools \
204         CC="%{__cc}" \
205         CXX="%{__cxx}"
206
207 %install
208 rm -rf $RPM_BUILD_ROOT
209 install -d $RPM_BUILD_ROOT/etc/xen/examples
210
211 %{__make} install-xen install-tools install-stubdom install-docs \
212         CC="%{__cc}" \
213         CXX="%{__cxx}" \
214         DESTDIR=$RPM_BUILD_ROOT
215
216 mv $RPM_BUILD_ROOT/etc/xen/{xmexample*,examples}
217
218 cp -p tools/blktap/README{,.blktap}
219 cp -p tools/xenmon/README{,.xenmon}
220
221 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
222 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
223
224 %py_postclean
225
226 # remove unneeded files
227 %{__rm} $RPM_BUILD_ROOT/boot/xen-4.1.gz
228 %{__rm} $RPM_BUILD_ROOT/boot/xen-4.gz
229 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/xen
230 %{__rm} $RPM_BUILD_ROOT%{_includedir}/%{name}/COPYING
231
232 %clean
233 rm -rf $RPM_BUILD_ROOT
234
235 %post
236 /sbin/chkconfig --add xen-watchdog
237 /sbin/chkconfig --add xencommons
238 /sbin/chkconfig --add xendomains
239
240 %preun
241 if [ "$1" = "0" ]; then
242         %service xendomains stop
243         /sbin/chkconfig --del xendomains
244
245         %service xencommons stop
246         /sbin/chkconfig --del xencommons
247
248         %service xen-watchdog stop
249         /sbin/chkconfig --del xen-watchdog
250 fi
251
252 %post  xend
253 /sbin/chkconfig --add xend
254
255 %preun xend
256 if [ "$1" = "0" ]; then
257         %service xend stop
258         /sbin/chkconfig --del xend
259 fi
260
261 %post   libs -p /sbin/ldconfig
262 %postun libs -p /sbin/ldconfig
263
264 %files
265 %defattr(644,root,root,755)
266 %doc COPYING README* docs/misc/* 
267 %doc docs/html/*
268 %doc tools/blktap/README.blktap tools/xenmon/README.xenmon
269 %doc tools/ioemu-dir/*.html
270 /boot/%{name}-syms-%{version}
271 /boot/%{name}-%{version}.gz
272 /boot/%{name}.gz
273 %attr(754,root,root) /etc/rc.d/init.d/xen-watchdog
274 %attr(754,root,root) /etc/rc.d/init.d/xencommons
275 %attr(754,root,root) /etc/rc.d/init.d/xendomains
276 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/*
277 %dir %{_sysconfdir}/xen
278 %dir %{_sysconfdir}/xen/auto
279 %dir %{_sysconfdir}/xen/examples
280 %dir %{_sysconfdir}/xen/scripts
281 %attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/scripts/*
282 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/examples/*
283 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/README*
284 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/cpupool
285 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/xl.conf
286 %attr(755,root,root) %{_bindir}/*
287 %attr(755,root,root) %{_sbindir}/[bfgikloqtv]*
288 %attr(755,root,root) %{_sbindir}/xen??*
289 %attr(755,root,root) %{_sbindir}/xl
290 %attr(755,root,root) %{_sbindir}/xsview
291 %dir %{_libdir}/%{name}
292 %dir %{_libdir}/%{name}/bin
293 %attr(744,root,root) %{_libdir}/%{name}/bin/*
294 %if "%{_lib}" != "lib"
295 %dir %{_prefix}/lib/%{name}
296 %endif
297 %dir %{_prefix}/lib/%{name}/boot
298 %{?with_hvm:%attr(744,root,root) %{_prefix}/lib/%{name}/boot/hvmloader}
299 %{_datadir}/xen
300 %{_mandir}/man?/*
301 %{_sharedstatedir}/xen
302 %{_sharedstatedir}/xenstored
303 %dir /var/run/xenstored
304
305 %files libs
306 %defattr(644,root,root,755)
307 %attr(755,root,root) %{_libdir}/lib*.so.*
308 %dir %{_libdir}/fs
309 %dir %{_libdir}/fs/ext2fs-lib
310 %dir %{_libdir}/fs/fat
311 %dir %{_libdir}/fs/iso9660
312 %dir %{_libdir}/fs/reiserfs
313 %dir %{_libdir}/fs/ufs
314 %dir %{_libdir}/fs/zfs
315 %attr(755,root,root) %{_libdir}/fs/*/*.so
316
317 %files devel
318 %defattr(644,root,root,755)
319 %attr(755,root,root) %{_libdir}/lib*.so
320 %{_includedir}/*
321
322 %files static
323 %defattr(644,root,root,755)
324 %{_libdir}/lib*.a
325
326 %files udev
327 %defattr(644,root,root,755)
328 %config(noreplace) %verify(not md5 mtime size) /etc/udev/*
329
330 %files xend
331 %defattr(644,root,root,755)
332 %attr(754,root,root) %{_sysconfdir}/rc.d/init.d/xend
333 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/xm*
334 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/xend*
335 %attr(755,root,root) %{_sbindir}/xend
336 %attr(755,root,root) %{_sbindir}/xm
337 %dir %attr(700,root,root) /var/run/xend
338
339 %files -n python-xen
340 %defattr(644,root,root,755)
341 %attr(755,root,root) %{py_sitedir}/fsimage.so
342 %{py_sitedir}/grub
343 %dir %{py_sitedir}/xen
344 %dir %{py_sitedir}/xen/lowlevel
345 %{py_sitedir}/xen/lowlevel/*.py*
346 %attr(755,root,root) %{py_sitedir}/xen/lowlevel/*.so
347 %{py_sitedir}/xen/remus
348 %{py_sitedir}/xen/sv
349 %{py_sitedir}/xen/util
350 %{py_sitedir}/xen/web
351 %{py_sitedir}/xen/xend
352 %{py_sitedir}/xen/xm
353 %{py_sitedir}/xen/xsview
354 %{py_sitedir}/xen/*.py*
355 %if "%{py_ver}" > "2.4"
356 %{py_sitedir}/*.egg-info
357 %endif
358
359 %files -n bash-completion-%{name}
360 %defattr(644,root,root,755)
361 /etc/bash_completion.d/*
This page took 0.912133 seconds and 3 git commands to generate.