]>
Commit | Line | Data |
---|---|---|
2f3b83cd | 1 | # |
403a0e9f | 2 | # TODO: |
e9753e37 | 3 | # - most of the qemu config options aren't detected (curses, NPTL, vde, fdt) |
263a9ffc JK |
4 | # - check if other tools/libs are not usable in domU, move them to -guest |
5 | # packages if so | |
b650a78f | 6 | # |
732e4a65 JR |
7 | # |
8 | # Conditional build: | |
e6e7d0de | 9 | %bcond_without ocaml # build Ocaml libraries for Xen tools |
732e4a65 | 10 | # |
c1281a11 | 11 | %define xen_extfiles_url http://xenbits.xensource.com/xen-extfiles |
adbb6385 | 12 | Summary: Xen - a virtual machine monitor |
a1a3c257 | 13 | Summary(pl.UTF-8): Xen - monitor maszyny wirtualnej |
fda6847b | 14 | Name: xen |
e9753e37 | 15 | Version: 4.1.2 |
944e4f79 | 16 | Release: 4 |
e6e7d0de | 17 | License: GPL v2, interface parts on BSD-like |
129858a4 | 18 | Group: Applications/System |
98fa2458 | 19 | Source0: http://bits.xensource.com/oss-xen/release/%{version}/%{name}-%{version}.tar.gz |
e9753e37 | 20 | # Source0-md5: 73561faf3c1b5e36ec5c089b5db848ad |
c1281a11 | 21 | # used by stubdoms |
94b34ae4 | 22 | Source10: %{xen_extfiles_url}/lwip-1.3.0.tar.gz |
c1281a11 | 23 | # Source10-md5: 36cc57650cffda9a0269493be2a169bb |
94b34ae4 | 24 | Source11: %{xen_extfiles_url}/newlib-1.16.0.tar.gz |
c1281a11 | 25 | # Source11-md5: bf8f1f9e3ca83d732c00a79a6ef29bc4 |
94b34ae4 | 26 | Source12: %{xen_extfiles_url}/zlib-1.2.3.tar.gz |
c1281a11 | 27 | # Source12-md5: debc62758716a169df9f62e6ab2bc634 |
94b34ae4 | 28 | Source13: %{xen_extfiles_url}/pciutils-2.2.9.tar.bz2 |
c1281a11 | 29 | # Source13-md5: cec05e7785497c5e19da2f114b934ffd |
94b34ae4 | 30 | Source14: %{xen_extfiles_url}/grub-0.97.tar.gz |
c1281a11 | 31 | # Source14-md5: cd3f3eb54446be6003156158d51f4884 |
94b34ae4 | 32 | Source15: %{xen_extfiles_url}/ipxe-git-v1.0.0.tar.gz |
c1281a11 | 33 | # Source15-md5: fb7df96781d337899066d82059346885 |
2e8b91a6 JR |
34 | Source30: proc-xen.mount |
35 | Source31: var-lib-xenstored.mount | |
36 | Source32: blktapctrl.service | |
37 | Source33: blktapctrl.sysconfig | |
38 | Source34: xenconsoled.service | |
39 | Source35: xenconsoled.sysconfig | |
40 | Source36: xenstored.service | |
41 | Source37: xenstored.sysconfig | |
42 | Source38: xenstored.tmpfiles | |
43 | Source39: xend.service | |
44 | Source40: xend.tmpfiles | |
45 | Source41: xen-watchdog.service | |
36106ee8 | 46 | Source42: xen-dom0-modules-load.conf |
2e8b91a6 JR |
47 | # sysvinit scripts |
48 | Source50: xend.init | |
49 | Source51: xenconsoled.init | |
50 | Source52: xenstored.init | |
51 | Source53: xen-watchdog.init | |
52 | Source54: xendomains.init | |
53 | Source55: xen.logrotate | |
47d65e01 | 54 | Patch0: %{name}-python_scripts.patch |
e9753e37 MM |
55 | Patch1: %{name}-symbols.patch |
56 | Patch2: %{name}-curses.patch | |
6ca9eddd JR |
57 | Patch3: %{name}-xz.patch |
58 | Patch4: pygrubfix.patch | |
59 | Patch5: pygrubfix2.patch | |
60 | Patch6: qemu-xen-4.1-testing.git-3cf61880403b4e484539596a95937cc066243388.patch | |
61 | Patch7: xen-4.1-testing.23190.patch | |
62 | Patch8: xend.catchbt.patch | |
63 | Patch9: xend.empty.xml.patch | |
64 | Patch10: xend-pci-loop.patch | |
65 | Patch11: xen-dumpdir.patch | |
94ddf9c9 | 66 | Patch12: xen-net-disable-iptables-on-bridge.patch |
78c13f9d | 67 | Patch13: xen-configure-xend.patch |
7f560d13 | 68 | Patch14: xen-initscript.patch |
6ca9eddd JR |
69 | # stubdom patch |
70 | Patch100: grub-ext4-support.patch | |
67494ff6 | 71 | URL: http://www.cl.cam.ac.uk/Research/SRG/netos/xen/index.html |
04f24179 | 72 | BuildRequires: OpenGL-devel |
abdd4c6d | 73 | BuildRequires: SDL-devel |
24d6dc2b | 74 | BuildRequires: acpica |
2e8b91a6 | 75 | BuildRequires: bcc |
04f24179 JB |
76 | BuildRequires: bluez-libs-devel |
77 | BuildRequires: brlapi-devel | |
39eabac9 | 78 | BuildRequires: curl-devel |
d9ee3ddc | 79 | BuildRequires: e2fsprogs-devel |
fc7816dc | 80 | BuildRequires: gcc >= 5:3.4 |
abdd4c6d | 81 | BuildRequires: gettext-devel |
04f24179 | 82 | BuildRequires: gnutls-devel |
47d65e01 | 83 | BuildRequires: latex2html |
403a0e9f | 84 | BuildRequires: libidn-devel |
403a0e9f | 85 | BuildRequires: ncurses-devel |
732e4a65 JR |
86 | %if %{with ocaml} |
87 | BuildRequires: ocaml >= 3.04-7 | |
88 | BuildRequires: ocaml-findlib | |
732e4a65 | 89 | %endif |
42bff0c7 | 90 | BuildRequires: pciutils-devel |
abdd4c6d | 91 | BuildRequires: pkgconfig |
53503036 | 92 | BuildRequires: python-devel |
48c47956 | 93 | BuildRequires: rpm-pythonprov |
5db31b25 | 94 | BuildRequires: rpmbuild(macros) >= 1.647 |
e9753e37 | 95 | #BuildRequires: texlive-dvips |
abdd4c6d | 96 | #BuildRequires: texlive-latex-data |
f03e6adf | 97 | BuildRequires: texlive-latex-psnfss |
53503036 | 98 | BuildRequires: transfig |
12f352e2 | 99 | BuildRequires: which |
04f24179 JB |
100 | BuildRequires: xorg-lib-libX11-devel |
101 | BuildRequires: xorg-lib-libXext-devel | |
53503036 | 102 | BuildRequires: zlib-devel |
129858a4 | 103 | Requires(post,preun): /sbin/chkconfig |
c2ee841b | 104 | Requires(post,preun,postun): systemd-units >= 38 |
9f9b2612 | 105 | Requires: %{name}-libs = %{version}-%{release} |
53503036 JB |
106 | Requires: ZopeInterface |
107 | Requires: bridge-utils | |
e77e45ff AM |
108 | Requires: coreutils |
109 | Requires: diffutils | |
d78769bd | 110 | Requires: gawk |
e77e45ff | 111 | Requires: iptables |
53503036 | 112 | Requires: losetup |
e77e45ff | 113 | Requires: net-tools |
8e6e2740 | 114 | Requires: python-%{name} = %{version}-%{release} |
129858a4 | 115 | Requires: rc-scripts |
e77e45ff | 116 | Requires: sed |
5db31b25 | 117 | Requires: systemd-units >= 38 |
a674a8b2 | 118 | Requires: util-linux |
e77e45ff | 119 | Requires: which |
263a9ffc | 120 | Requires: %{name}-guest = %{version}-%{release} |
cef7399d | 121 | Obsoletes: xen-doc |
2e8b91a6 | 122 | Obsoletes: xen-udev |
971d1e2c | 123 | ExclusiveArch: %{ix86} %{x8664} |
fda6847b AM |
124 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
125 | ||
8f12ec8f | 126 | # some PPC/SPARC boot image in ELF format |
7fb9617b | 127 | %define _noautostrip .*%{_datadir}/xen/qemu/openbios-.* |
8f12ec8f | 128 | |
fda6847b AM |
129 | %description |
130 | This package contains the Xen hypervisor and Xen tools, needed to run | |
131 | virtual machines on x86 systems, together with the kernel-xen* | |
132 | packages. Information on how to use Xen can be found at the Xen | |
133 | project pages. | |
134 | ||
135 | Virtualisation can be used to run multiple versions or multiple Linux | |
136 | distributions on one system, or to test untrusted applications in a | |
137 | sandboxed environment. Note that the Xen technology is still in | |
138 | development, and this RPM has received extremely little testing. Don't | |
139 | be surprised if this RPM eats your data, drinks your coffee or makes | |
140 | fun of you in front of your friends. | |
141 | ||
d2a30a0d | 142 | %description -l pl.UTF-8 |
3615a8c8 | 143 | Ten pakiet zawiera nadzorcę oraz narzędzia Xen, potrzebne do |
adbb6385 | 144 | uruchamiania wirtualnych maszyn w systemach x86, wraz z pakietami |
3615a8c8 | 145 | kernel-xen*. Informacje jak używać Xena można znaleźć na stronach |
adbb6385 JB |
146 | projektu. |
147 | ||
3615a8c8 | 148 | Wirtualizacja może być używana do uruchamiania wielu wersji lub wielu |
dcba01a0 | 149 | dystrybucji Linuksa na jednym systemie lub do testowania nie zaufanych |
3615a8c8 ER |
150 | aplikacji w odizolowanym środowisku. Należy zauważyć, że technologia |
151 | Xen jest ciągle rozwijana, a ten RPM był słabo testowany. Nie należy | |
152 | być zdziwionym, jeśli ten pakiet zje dane, wypije całą kawę czy będzie | |
153 | się wyśmiewał w obecności przyjaciół. | |
403a0e9f | 154 | |
263a9ffc JK |
155 | %package guest |
156 | Summary: Xen tools for virtual machines | |
157 | Summary(pl.UTF-8): Narzędzia Xen dla maszyn virtualnych | |
158 | Group: Applications/System | |
159 | Requires: %{name}-libs-guest = %{version}-%{release} | |
160 | ||
161 | %description guest | |
162 | Xen utilities for both dom0 and domU virtual domains. | |
163 | ||
164 | %description guest -l pl.UTF-8 | |
165 | Narzędzia Xena dla maszyn wirtualnych dom0 i domU. | |
166 | ||
26412ee3 | 167 | %package libs |
e6e7d0de JB |
168 | Summary: Xen libraries |
169 | Summary(pl.UTF-8): Biblioteki Xena | |
26412ee3 JB |
170 | Group: Libraries |
171 | ||
172 | %description libs | |
e6e7d0de | 173 | Xen libraries. |
26412ee3 JB |
174 | |
175 | %description libs -l pl.UTF-8 | |
e6e7d0de | 176 | Biblioteki Xena. |
26412ee3 | 177 | |
263a9ffc JK |
178 | %package libs-guest |
179 | Summary: Xen libraries for virtual machines | |
180 | Summary(pl.UTF-8): Biblioteki Xena dla maszyn wirtualnych | |
181 | Group: Libraries | |
182 | ||
183 | %description libs-guest | |
184 | Xen libraries for both dom0 and domU virtual machines. | |
185 | ||
186 | %description libs-guest -l pl.UTF-8 | |
187 | Biblioteki Xena dla maszyn wirtualnych dom0 i domU. | |
188 | ||
403a0e9f | 189 | %package devel |
e6e7d0de JB |
190 | Summary: Header files for Xen |
191 | Summary(pl.UTF-8): Pliki nagłówkowe Xena | |
403a0e9f | 192 | Group: Development/Libraries |
9f9b2612 | 193 | Requires: %{name}-libs = %{version}-%{release} |
403a0e9f AM |
194 | |
195 | %description devel | |
e6e7d0de | 196 | Header files for Xen. |
6eccf3e8 | 197 | |
d2a30a0d | 198 | %description devel -l pl.UTF-8 |
e6e7d0de | 199 | Pliki nagłówkowe Xena. |
403a0e9f AM |
200 | |
201 | %package static | |
e6e7d0de JB |
202 | Summary: Static Xen libraries |
203 | Summary(pl.UTF-8): Statyczne biblioteki Xena | |
403a0e9f | 204 | Group: Development/Libraries |
9f9b2612 | 205 | Requires: %{name}-devel = %{version}-%{release} |
403a0e9f AM |
206 | |
207 | %description static | |
e6e7d0de | 208 | Static Xen libraries. |
adbb6385 | 209 | |
d2a30a0d | 210 | %description static -l pl.UTF-8 |
e6e7d0de | 211 | Statyczne biblioteki Xena. |
6eccf3e8 | 212 | |
e9753e37 MM |
213 | %package xend |
214 | Summary: xend daemon | |
215 | Summary(pl.UTF-8): Demon xend | |
216 | Group: Daemons | |
c2ee841b | 217 | Requires(post,preun,postun): systemd-units >= 38 |
5db31b25 | 218 | Requires: systemd-units >= 38 |
e9753e37 MM |
219 | |
220 | %description xend | |
221 | xend daemon. | |
222 | ||
223 | %description xend -l pl.UTF-8 | |
224 | Demon xend. | |
225 | ||
e6e7d0de JB |
226 | %package -n ocaml-xen |
227 | Summary: OCaml bindings for Xen | |
228 | Summary(pl.UTF-8): Wiązania OCamla dla Xena | |
229 | License: LGPL v2.1 with linking exception | |
230 | Group: Libraries | |
231 | Requires: %{name}-libs = %{version}-%{release} | |
1d76ff09 | 232 | %if %{with ocaml} |
e6e7d0de JB |
233 | %requires_eq ocaml-runtime |
234 | ||
1d76ff09 | 235 | %endif |
e6e7d0de JB |
236 | %description -n ocaml-xen |
237 | OCaml bindings for Xen. | |
238 | ||
239 | %description -n ocaml-xen -l pl.UTF-8 | |
240 | Wiązania OCamla dla Xena. | |
241 | ||
242 | %package -n ocaml-xen-devel | |
243 | Summary: OCaml bindings for Xen - development files | |
244 | Summary(pl.UTF-8): Wiązania OCamla dla Xena - pliki programistyczne | |
245 | License: LGPL v2.1 with linking exception | |
246 | Group: Development/Libraries | |
247 | Requires: ocaml-xen = %{version}-%{release} | |
1d76ff09 | 248 | %if %{with ocaml} |
e6e7d0de | 249 | %requires_eq ocaml |
1d76ff09 | 250 | %endif |
e6e7d0de JB |
251 | |
252 | %description -n ocaml-xen-devel | |
253 | OCaml bindings for Xen - development files. | |
254 | ||
255 | %description -n ocaml-xen-devel -l pl.UTF-8 | |
256 | Wiązania OCamla dla Xena - pliki programistyczne. | |
257 | ||
5dd334af | 258 | %package -n python-xen |
e6e7d0de JB |
259 | Summary: Xen Python modules |
260 | Summary(pl.UTF-8): Moduły Pythona dla Xena | |
5dd334af | 261 | Group: Libraries |
e6e7d0de | 262 | Requires: %{name}-libs = %{version}-%{release} |
e35fda92 | 263 | Conflicts: xen < 3.2.1-0.3 |
5dd334af JB |
264 | |
265 | %description -n python-xen | |
e6e7d0de | 266 | Xen Python modules. |
5dd334af JB |
267 | |
268 | %description -n python-xen -l pl.UTF-8 | |
e6e7d0de | 269 | Moduły Pythona dla Xena. |
5dd334af | 270 | |
263a9ffc JK |
271 | %package -n python-xen-guest |
272 | Summary: Xen Python modules for virtual machines | |
273 | Summary(pl.UTF-8): Moduły Pythona dla maszyn wirtualnych Xena | |
274 | Group: Libraries | |
275 | Requires: %{name}-libs-guest = %{version}-%{release} | |
276 | Conflicts: xen < 3.2.1-0.3 | |
277 | ||
278 | %description -n python-xen-guest | |
279 | Xen Python modules for both dom0 and domU virtual machines. | |
280 | ||
281 | %description -n python-xen-guest -l pl.UTF-8 | |
282 | Moduły Pythona dla maszyn wirtualnych dom0 i domU. | |
283 | ||
e9753e37 | 284 | %package -n bash-completion-%{name} |
e6e7d0de JB |
285 | Summary: bash-completion for Xen (xl) |
286 | Summary(pl.UTF-8): Bashowe dopełnianie poleceń dla Xena (xl) | |
e9753e37 MM |
287 | Group: Applications/Shells |
288 | Requires: %{name} = %{version}-%{release} | |
289 | Requires: bash-completion | |
290 | ||
291 | %description -n bash-completion-%{name} | |
e6e7d0de | 292 | This package provides bash-completion for Xen (xl). |
94b34ae4 JB |
293 | |
294 | %description -n bash-completion-%{name} -l pl.UTF-8 | |
e6e7d0de | 295 | Ten pakiet zapewnia bashowe dopełnianie poleceń dla Xena (xl). |
e9753e37 | 296 | |
fda6847b | 297 | %prep |
98fa2458 | 298 | %setup -q |
47d65e01 JK |
299 | %patch0 -p1 |
300 | %patch1 -p1 | |
42bff0c7 | 301 | %patch2 -p1 |
6ca9eddd | 302 | %patch3 -p1 |
53ff2d70 | 303 | %patch4 -p1 |
6ca9eddd JR |
304 | %patch5 -p1 |
305 | %patch6 -p1 | |
306 | %patch7 -p1 | |
307 | %patch8 -p1 | |
308 | %patch9 -p1 | |
309 | %patch10 -p1 | |
310 | %patch11 -p1 | |
94ddf9c9 | 311 | %patch12 -p1 |
78c13f9d | 312 | %patch13 -p1 |
7f560d13 | 313 | %patch14 -p1 |
4015585b | 314 | |
c1281a11 ER |
315 | %{__rm} -v tools/check/*.orig |
316 | ||
317 | # stubdom sources | |
318 | ln -s %{SOURCE10} %{SOURCE11} %{SOURCE12} %{SOURCE13} %{SOURCE14} stubdom | |
6ca9eddd | 319 | ln -s %{PATCH100} stubdom/grub.patches/99grub-ext4-support.patch |
c1281a11 | 320 | ln -s %{SOURCE15} tools/firmware/etherboot/ipxe.tar.gz |
fda6847b AM |
321 | |
322 | %build | |
2e8b91a6 JR |
323 | export CFLAGS="%{rpmcflags} -I/usr/include/ncurses" |
324 | export CXXFLAGS="%{rpmcflags} -I/usr/include/ncurses" | |
325 | ||
326 | %{__make} dist-xen dist-tools dist-docs \ | |
732e4a65 | 327 | %{!?with_ocaml:OCAML_TOOLS=n} \ |
2e8b91a6 JR |
328 | prefix=%{_prefix} \ |
329 | CC="%{__cc}" \ | |
04f24179 JB |
330 | CXX="%{__cxx}" \ |
331 | V=1 | |
2e8b91a6 JR |
332 | |
333 | unset CFLAGS | |
334 | unset CXXFLAGS | |
335 | %{__make} -j1 dist-stubdom \ | |
732e4a65 | 336 | %{!?with_ocaml:OCAML_TOOLS=n} \ |
403a0e9f | 337 | CC="%{__cc}" \ |
da88b5cd | 338 | CXX="%{__cxx}" |
fda6847b AM |
339 | |
340 | %install | |
341 | rm -rf $RPM_BUILD_ROOT | |
245547b2 | 342 | install -d $RPM_BUILD_ROOT/etc/{xen/examples,modules-load.d,logrotate.d} \ |
ba7770de | 343 | $RPM_BUILD_ROOT{/usr/lib/tmpfiles.d,%{systemdunitdir},/var/log/xen/console} |
adbb6385 | 344 | |
2e8b91a6 | 345 | %{__make} -j1 install-xen install-tools install-stubdom install-docs \ |
732e4a65 | 346 | %{!?with_ocaml:OCAML_TOOLS=n} \ |
2e8b91a6 | 347 | prefix=%{_prefix} \ |
9e5cb9d3 JB |
348 | DESTDIR=$RPM_BUILD_ROOT \ |
349 | HOTPLUGS=install-udev | |
403a0e9f | 350 | |
a1283e56 JR |
351 | %if "%{_lib}" == "lib64" |
352 | ln -s %{_prefix}/lib/%{name}/bin/qemu-dm $RPM_BUILD_ROOT%{_libdir}/%{name}/bin/qemu-dm | |
353 | %endif | |
354 | ||
2e8b91a6 JR |
355 | install %{SOURCE30} $RPM_BUILD_ROOT%{systemdunitdir}/proc-xen.mount |
356 | install %{SOURCE31} $RPM_BUILD_ROOT%{systemdunitdir}/var-lib-xenstored.mount | |
5db31b25 JR |
357 | install %{SOURCE32} $RPM_BUILD_ROOT%{systemdunitdir}/blktapctrl.service |
358 | install %{SOURCE33} $RPM_BUILD_ROOT/etc/sysconfig/blktapctrl | |
2e8b91a6 | 359 | install %{SOURCE34} $RPM_BUILD_ROOT%{systemdunitdir}/xenconsoled.service |
4a5ac969 | 360 | install %{SOURCE35} $RPM_BUILD_ROOT/etc/sysconfig/xenconsoled |
2e8b91a6 | 361 | install %{SOURCE36} $RPM_BUILD_ROOT%{systemdunitdir}/xenstored.service |
4a5ac969 | 362 | install %{SOURCE37} $RPM_BUILD_ROOT/etc/sysconfig/xenstored |
2e8b91a6 JR |
363 | install %{SOURCE38} $RPM_BUILD_ROOT/usr/lib/tmpfiles.d/xenstored.conf |
364 | install %{SOURCE39} $RPM_BUILD_ROOT%{systemdunitdir}/xend.service | |
365 | install %{SOURCE40} $RPM_BUILD_ROOT/usr/lib/tmpfiles.d/xend.conf | |
366 | install %{SOURCE41} $RPM_BUILD_ROOT%{systemdunitdir}/xen-watchdog.service | |
36106ee8 | 367 | install %{SOURCE42} $RPM_BUILD_ROOT/etc/modules-load.d/xen-dom0.conf |
2e8b91a6 JR |
368 | # sysvinit scripts |
369 | %{__rm} $RPM_BUILD_ROOT/etc/rc.d/init.d/* | |
370 | install %{SOURCE50} $RPM_BUILD_ROOT/etc/rc.d/init.d/xend | |
371 | install %{SOURCE51} $RPM_BUILD_ROOT/etc/rc.d/init.d/xenconsoled | |
372 | install %{SOURCE52} $RPM_BUILD_ROOT/etc/rc.d/init.d/xenstored | |
373 | install %{SOURCE53} $RPM_BUILD_ROOT/etc/rc.d/init.d/xen-watchdog | |
374 | install %{SOURCE54} $RPM_BUILD_ROOT/etc/rc.d/init.d/xendomains | |
245547b2 | 375 | install %{SOURCE55} $RPM_BUILD_ROOT/etc/logrotate.d/xen |
2e8b91a6 | 376 | |
e9753e37 | 377 | mv $RPM_BUILD_ROOT/etc/xen/{xmexample*,examples} |
fda6847b | 378 | |
c1281a11 ER |
379 | cp -p tools/blktap/README{,.blktap} |
380 | cp -p tools/xenmon/README{,.xenmon} | |
67494ff6 | 381 | |
90eccaeb ER |
382 | %py_comp $RPM_BUILD_ROOT%{py_sitedir} |
383 | %py_ocomp $RPM_BUILD_ROOT%{py_sitedir} | |
384 | ||
385 | %py_postclean | |
e9753e37 | 386 | |
86497794 | 387 | # remove unneeded files |
e9753e37 MM |
388 | %{__rm} $RPM_BUILD_ROOT/boot/xen-4.1.gz |
389 | %{__rm} $RPM_BUILD_ROOT/boot/xen-4.gz | |
8641374c | 390 | %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/xen |
e9753e37 | 391 | %{__rm} $RPM_BUILD_ROOT%{_includedir}/%{name}/COPYING |
d26491b9 | 392 | |
fda6847b AM |
393 | %clean |
394 | rm -rf $RPM_BUILD_ROOT | |
395 | ||
403a0e9f | 396 | %post |
90a21d83 | 397 | /sbin/chkconfig --add xen-watchdog |
2e8b91a6 JR |
398 | /sbin/chkconfig --add xenconsoled |
399 | /sbin/chkconfig --add xenstored | |
403a0e9f | 400 | /sbin/chkconfig --add xendomains |
5db31b25 | 401 | %systemd_post xen-watchdog.service xenconsoled.service xenstored.service |
403a0e9f | 402 | |
403a0e9f | 403 | %preun |
e9753e37 MM |
404 | if [ "$1" = "0" ]; then |
405 | %service xendomains stop | |
406 | /sbin/chkconfig --del xendomains | |
407 | ||
2e8b91a6 JR |
408 | %service xenconsoled stop |
409 | /sbin/chkconfig --del xenconsoled | |
410 | ||
411 | %service xenstored stop | |
412 | /sbin/chkconfig --del xenstored | |
90a21d83 MM |
413 | |
414 | %service xen-watchdog stop | |
415 | /sbin/chkconfig --del xen-watchdog | |
e9753e37 | 416 | fi |
5db31b25 | 417 | %systemd_preun xen-watchdog.service xenconsoled.service xenstored.service |
e9753e37 | 418 | |
5db31b25 JR |
419 | %postun |
420 | %systemd_reload | |
421 | ||
422 | %post xend | |
e9753e37 | 423 | /sbin/chkconfig --add xend |
5db31b25 | 424 | %systemd_post xend.service |
e9753e37 MM |
425 | |
426 | %preun xend | |
403a0e9f | 427 | if [ "$1" = "0" ]; then |
129858a4 | 428 | %service xend stop |
403a0e9f | 429 | /sbin/chkconfig --del xend |
e9753e37 | 430 | fi |
5db31b25 JR |
431 | %systemd_preun xend.service |
432 | ||
433 | %postun xend | |
434 | %systemd_reload | |
129858a4 | 435 | |
26412ee3 JB |
436 | %post libs -p /sbin/ldconfig |
437 | %postun libs -p /sbin/ldconfig | |
438 | ||
263a9ffc JK |
439 | %post libs-guest -p /sbin/ldconfig |
440 | %postun libs-guest -p /sbin/ldconfig | |
441 | ||
fda6847b AM |
442 | %files |
443 | %defattr(644,root,root,755) | |
e9753e37 | 444 | %doc COPYING README* docs/misc/* |
47d65e01 | 445 | %doc docs/html/* |
e9753e37 MM |
446 | %doc tools/blktap/README.blktap tools/xenmon/README.xenmon |
447 | %doc tools/ioemu-dir/*.html | |
98fa2458 AM |
448 | /boot/%{name}-syms-%{version} |
449 | /boot/%{name}-%{version}.gz | |
fda6847b | 450 | /boot/%{name}.gz |
6ca9eddd JR |
451 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/xenconsoled |
452 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/xenstored | |
453 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/xendomains | |
245547b2 | 454 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/xen |
90a21d83 | 455 | %attr(754,root,root) /etc/rc.d/init.d/xen-watchdog |
2e8b91a6 JR |
456 | %attr(754,root,root) /etc/rc.d/init.d/xenconsoled |
457 | %attr(754,root,root) /etc/rc.d/init.d/xenstored | |
e9753e37 | 458 | %attr(754,root,root) /etc/rc.d/init.d/xendomains |
36106ee8 | 459 | %config(noreplace) %verify(not md5 mtime size) /etc/modules-load.d/xen-dom0.conf |
2e8b91a6 JR |
460 | %{systemdunitdir}/proc-xen.mount |
461 | %{systemdunitdir}/var-lib-xenstored.mount | |
2e8b91a6 JR |
462 | %{systemdunitdir}/xen-watchdog.service |
463 | %{systemdunitdir}/xenconsoled.service | |
464 | %{systemdunitdir}/xenstored.service | |
403a0e9f | 465 | %dir %{_sysconfdir}/xen |
403a0e9f | 466 | %dir %{_sysconfdir}/xen/auto |
e9753e37 | 467 | %dir %{_sysconfdir}/xen/examples |
403a0e9f AM |
468 | %dir %{_sysconfdir}/xen/scripts |
469 | %attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/scripts/* | |
e9753e37 MM |
470 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/examples/* |
471 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/README* | |
472 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/cpupool | |
473 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/xl.conf | |
eb3891cc | 474 | %config(noreplace) %verify(not md5 mtime size) /etc/udev/rules.d/xen-backend.rules |
94b34ae4 JB |
475 | %attr(755,root,root) %{_bindir}/pygrub |
476 | %attr(755,root,root) %{_bindir}/qemu-img-xen | |
477 | %attr(755,root,root) %{_bindir}/qemu-nbd-xen | |
478 | %attr(755,root,root) %{_bindir}/remus | |
94b34ae4 | 479 | %attr(755,root,root) %{_bindir}/xencons |
94b34ae4 JB |
480 | %attr(755,root,root) %{_bindir}/xentrace* |
481 | %attr(755,root,root) %{_sbindir}/blktapctrl | |
482 | %attr(755,root,root) %{_sbindir}/flask-* | |
483 | %attr(755,root,root) %{_sbindir}/gdbsx | |
484 | %attr(755,root,root) %{_sbindir}/gtrace* | |
485 | %attr(755,root,root) %{_sbindir}/img2qcow | |
486 | %attr(755,root,root) %{_sbindir}/kdd | |
487 | %attr(755,root,root) %{_sbindir}/lock-util | |
488 | %attr(755,root,root) %{_sbindir}/qcow-create | |
489 | %attr(755,root,root) %{_sbindir}/qcow2raw | |
490 | %attr(755,root,root) %{_sbindir}/tap-ctl | |
491 | %attr(755,root,root) %{_sbindir}/tapdisk* | |
492 | %attr(755,root,root) %{_sbindir}/td-util | |
493 | %attr(755,root,root) %{_sbindir}/vhd-* | |
494 | %attr(755,root,root) %{_sbindir}/xen-* | |
495 | %attr(755,root,root) %{_sbindir}/xenbaked | |
496 | %attr(755,root,root) %{_sbindir}/xenconsoled | |
497 | %attr(755,root,root) %{_sbindir}/xenlockprof | |
498 | %attr(755,root,root) %{_sbindir}/xenmon.py | |
499 | %attr(755,root,root) %{_sbindir}/xenpaging | |
500 | %attr(755,root,root) %{_sbindir}/xenperf | |
501 | %attr(755,root,root) %{_sbindir}/xenpm | |
502 | %attr(755,root,root) %{_sbindir}/xenpmd | |
503 | %attr(755,root,root) %{_sbindir}/xenstored | |
504 | %attr(755,root,root) %{_sbindir}/xentop | |
505 | %attr(755,root,root) %{_sbindir}/xentrace_setmask | |
506 | %attr(755,root,root) %{_sbindir}/xenwatchdogd | |
e9753e37 MM |
507 | %attr(755,root,root) %{_sbindir}/xl |
508 | %attr(755,root,root) %{_sbindir}/xsview | |
47d65e01 JK |
509 | %dir %{_libdir}/%{name} |
510 | %dir %{_libdir}/%{name}/bin | |
511 | %attr(744,root,root) %{_libdir}/%{name}/bin/* | |
38e9ca75 | 512 | %if "%{_lib}" != "lib" |
81c76053 | 513 | %dir %{_prefix}/lib/%{name} |
2e8b91a6 JR |
514 | %dir %{_prefix}/lib/%{name}/bin |
515 | %attr(755,root,root) %{_prefix}/lib/%{name}/bin/qemu-dm | |
516 | %attr(755,root,root) %{_prefix}/lib/%{name}/bin/stubdom-dm | |
517 | %attr(755,root,root) %{_prefix}/lib/%{name}/bin/stubdompath.sh | |
38e9ca75 | 518 | %endif |
81c76053 | 519 | %dir %{_prefix}/lib/%{name}/boot |
2e8b91a6 JR |
520 | %{_prefix}/lib/%{name}/boot/ioemu-stubdom.gz |
521 | %{_prefix}/lib/%{name}/boot/pv-grub-x86_32.gz | |
10a7e15f | 522 | %ifarch %{x8664} |
2e8b91a6 | 523 | %{_prefix}/lib/%{name}/boot/pv-grub-x86_64.gz |
10a7e15f | 524 | %endif |
2e8b91a6 | 525 | %attr(744,root,root) %{_prefix}/lib/%{name}/boot/hvmloader |
47d65e01 | 526 | %{_datadir}/xen |
94b34ae4 JB |
527 | %{_mandir}/man1/xentop.1* |
528 | %{_mandir}/man1/xentrace_format.1* | |
529 | %{_mandir}/man1/xm.1* | |
530 | %{_mandir}/man5/xend-config.sxp.5* | |
531 | %{_mandir}/man5/xmdomain.cfg.5* | |
532 | %{_mandir}/man8/xentrace.8* | |
47d65e01 JK |
533 | %{_sharedstatedir}/xen |
534 | %{_sharedstatedir}/xenstored | |
47d65e01 | 535 | %dir /var/run/xenstored |
2e8b91a6 | 536 | %{systemdtmpfilesdir}/xenstored.conf |
ba7770de JR |
537 | %dir %attr(0700,root,root) /var/log/xen |
538 | %dir %attr(0700,root,root) /var/log/xen/console | |
403a0e9f | 539 | |
263a9ffc JK |
540 | %files guest |
541 | %defattr(644,root,root,755) | |
542 | %attr(755,root,root) %{_bindir}/xen-detect | |
543 | %attr(755,root,root) %{_bindir}/xenstore* | |
544 | ||
26412ee3 | 545 | %files libs |
403a0e9f | 546 | %defattr(644,root,root,755) |
94b34ae4 JB |
547 | %attr(755,root,root) %{_libdir}/libblktap.so.*.*.* |
548 | %attr(755,root,root) %ghost %{_libdir}/libblktap.so.3.0 | |
549 | %attr(755,root,root) %{_libdir}/libblktapctl.so.*.*.* | |
550 | %attr(755,root,root) %ghost %{_libdir}/libblktapctl.so.1.0 | |
551 | %attr(755,root,root) %{_libdir}/libflask.so.*.*.* | |
552 | %attr(755,root,root) %ghost %{_libdir}/libflask.so.1.0 | |
553 | %attr(755,root,root) %{_libdir}/libfsimage.so.*.*.* | |
554 | %attr(755,root,root) %ghost %{_libdir}/libfsimage.so.1.0 | |
555 | %attr(755,root,root) %{_libdir}/libvhd.so.*.*.* | |
556 | %attr(755,root,root) %ghost %{_libdir}/libvhd.so.1.0 | |
557 | %attr(755,root,root) %{_libdir}/libxenctrl.so.*.*.* | |
558 | %attr(755,root,root) %ghost %{_libdir}/libxenctrl.so.4.0 | |
559 | %attr(755,root,root) %{_libdir}/libxenguest.so.*.*.* | |
560 | %attr(755,root,root) %ghost %{_libdir}/libxenguest.so.4.0 | |
561 | %attr(755,root,root) %{_libdir}/libxenlight.so.*.*.* | |
562 | %attr(755,root,root) %ghost %{_libdir}/libxenlight.so.1.0 | |
94b34ae4 JB |
563 | %attr(755,root,root) %{_libdir}/libxlutil.so.*.*.* |
564 | %attr(755,root,root) %ghost %{_libdir}/libxlutil.so.1.0 | |
4015585b | 565 | %dir %{_libdir}/fs |
d9ee3ddc | 566 | %dir %{_libdir}/fs/ext2fs-lib |
2f3b83cd AG |
567 | %dir %{_libdir}/fs/fat |
568 | %dir %{_libdir}/fs/iso9660 | |
4015585b | 569 | %dir %{_libdir}/fs/reiserfs |
570 | %dir %{_libdir}/fs/ufs | |
20aeda6e | 571 | %dir %{_libdir}/fs/zfs |
94b34ae4 | 572 | %attr(755,root,root) %{_libdir}/fs/*/fsimage.so |
26412ee3 | 573 | |
263a9ffc JK |
574 | %files libs-guest |
575 | %defattr(644,root,root,755) | |
576 | %attr(755,root,root) %{_libdir}/libxenstore.so.*.*.* | |
577 | %attr(755,root,root) %ghost %{_libdir}/libxenstore.so.3.0 | |
578 | ||
5dd334af JB |
579 | %files devel |
580 | %defattr(644,root,root,755) | |
94b34ae4 JB |
581 | %attr(755,root,root) %{_libdir}/libblktap.so |
582 | %attr(755,root,root) %{_libdir}/libblktapctl.so | |
583 | %attr(755,root,root) %{_libdir}/libflask.so | |
584 | %attr(755,root,root) %{_libdir}/libfsimage.so | |
585 | %attr(755,root,root) %{_libdir}/libvhd.so | |
586 | %attr(755,root,root) %{_libdir}/libxenctrl.so | |
587 | %attr(755,root,root) %{_libdir}/libxenguest.so | |
588 | %attr(755,root,root) %{_libdir}/libxenlight.so | |
589 | %attr(755,root,root) %{_libdir}/libxenstore.so | |
590 | %attr(755,root,root) %{_libdir}/libxlutil.so | |
591 | %{_includedir}/_libxl_types.h | |
592 | %{_includedir}/blktaplib.h | |
593 | %{_includedir}/fsimage*.h | |
594 | %{_includedir}/libxl*.h | |
595 | %{_includedir}/xen*.h | |
596 | %{_includedir}/xs*.h | |
597 | %{_includedir}/xen | |
5dd334af JB |
598 | |
599 | %files static | |
600 | %defattr(644,root,root,755) | |
94b34ae4 JB |
601 | %{_libdir}/libblktap.a |
602 | %{_libdir}/libblktapctl.a | |
603 | %{_libdir}/libflask.a | |
604 | %{_libdir}/libvhd.a | |
605 | %{_libdir}/libxenctrl.a | |
606 | %{_libdir}/libxenguest.a | |
607 | %{_libdir}/libxenlight.a | |
608 | %{_libdir}/libxenstore.a | |
609 | %{_libdir}/libxlutil.a | |
5dd334af | 610 | |
e9753e37 MM |
611 | %files xend |
612 | %defattr(644,root,root,755) | |
5db31b25 JR |
613 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/blktapctrl |
614 | %{systemdunitdir}/blktapctrl.service | |
2e8b91a6 | 615 | %{systemdunitdir}/xend.service |
6ca9eddd | 616 | %attr(754,root,root) %{_sysconfdir}/rc.d/init.d/xend |
eb3891cc | 617 | %config(noreplace) %verify(not md5 mtime size) /etc/udev/rules.d/xend.rules |
e9753e37 MM |
618 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/xm* |
619 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/xen/xend* | |
620 | %attr(755,root,root) %{_sbindir}/xend | |
621 | %attr(755,root,root) %{_sbindir}/xm | |
622 | %dir %attr(700,root,root) /var/run/xend | |
2e8b91a6 | 623 | %{systemdtmpfilesdir}/xend.conf |
e9753e37 | 624 | |
e6e7d0de JB |
625 | %if %{with ocaml} |
626 | %files -n ocaml-xen | |
627 | %defattr(644,root,root,755) | |
628 | %doc tools/ocaml/LICENSE | |
629 | %attr(755,root,root) %{_sbindir}/oxenstored | |
630 | %dir %{_libdir}/ocaml/site-lib/eventchn | |
631 | %attr(755,root,root) %{_libdir}/ocaml/site-lib/eventchn/dlleventchn_stubs.so | |
632 | %dir %{_libdir}/ocaml/site-lib/log | |
633 | %attr(755,root,root) %{_libdir}/ocaml/site-lib/log/dllsyslog_stubs.so | |
634 | %dir %{_libdir}/ocaml/site-lib/mmap | |
635 | %attr(755,root,root) %{_libdir}/ocaml/site-lib/mmap/dllmmap_stubs.so | |
636 | %dir %{_libdir}/ocaml/site-lib/xb | |
637 | %attr(755,root,root) %{_libdir}/ocaml/site-lib/xb/dllxb_stubs.so | |
638 | %dir %{_libdir}/ocaml/site-lib/xc | |
639 | %attr(755,root,root) %{_libdir}/ocaml/site-lib/xc/dllxc_stubs.so | |
640 | %dir %{_libdir}/ocaml/site-lib/xl | |
641 | %attr(755,root,root) %{_libdir}/ocaml/site-lib/xl/dllxl_stubs.so | |
642 | ||
643 | %files -n ocaml-xen-devel | |
644 | %defattr(644,root,root,755) | |
645 | %{_libdir}/ocaml/site-lib/eventchn/META | |
646 | %{_libdir}/ocaml/site-lib/eventchn/libeventchn_stubs.a | |
647 | %{_libdir}/ocaml/site-lib/eventchn/eventchn.a | |
648 | %{_libdir}/ocaml/site-lib/eventchn/eventchn.cm[aix]* | |
649 | %{_libdir}/ocaml/site-lib/log/META | |
650 | %{_libdir}/ocaml/site-lib/log/libsyslog_stubs.a | |
651 | %{_libdir}/ocaml/site-lib/log/log.a | |
652 | %{_libdir}/ocaml/site-lib/log/*.cm[aix]* | |
653 | %{_libdir}/ocaml/site-lib/mmap/META | |
654 | %{_libdir}/ocaml/site-lib/mmap/libmmap_stubs.a | |
655 | %{_libdir}/ocaml/site-lib/mmap/mmap.a | |
656 | %{_libdir}/ocaml/site-lib/mmap/mmap.cm[aix]* | |
657 | %dir %{_libdir}/ocaml/site-lib/uuid | |
658 | %{_libdir}/ocaml/site-lib/uuid/META | |
659 | %{_libdir}/ocaml/site-lib/uuid/uuid.a | |
660 | %{_libdir}/ocaml/site-lib/uuid/uuid.cm[aix]* | |
661 | %{_libdir}/ocaml/site-lib/xb/META | |
662 | %{_libdir}/ocaml/site-lib/xb/libxb_stubs.a | |
663 | %{_libdir}/ocaml/site-lib/xb/xb.a | |
664 | %{_libdir}/ocaml/site-lib/xb/*.cm[aix]* | |
665 | %{_libdir}/ocaml/site-lib/xc/META | |
666 | %{_libdir}/ocaml/site-lib/xc/libxc_stubs.a | |
667 | %{_libdir}/ocaml/site-lib/xc/xc.a | |
668 | %{_libdir}/ocaml/site-lib/xc/xc.cm[aix]* | |
669 | %{_libdir}/ocaml/site-lib/xl/META | |
670 | %{_libdir}/ocaml/site-lib/xl/libxl_stubs.a | |
671 | %{_libdir}/ocaml/site-lib/xl/xl.a | |
672 | %{_libdir}/ocaml/site-lib/xl/xl.cm[aix]* | |
673 | %dir %{_libdir}/ocaml/site-lib/xs | |
674 | %{_libdir}/ocaml/site-lib/xs/META | |
675 | %{_libdir}/ocaml/site-lib/xs/xs.a | |
676 | %{_libdir}/ocaml/site-lib/xs/*.cm[aix]* | |
677 | %{_libdir}/ocaml/site-lib/xs/xs*.mli | |
678 | %endif | |
679 | ||
8e6e2740 ER |
680 | %files -n python-xen |
681 | %defattr(644,root,root,755) | |
5dd334af | 682 | %attr(755,root,root) %{py_sitedir}/fsimage.so |
8e6e2740 | 683 | %{py_sitedir}/grub |
263a9ffc JK |
684 | %attr(755,root,root) %{py_sitedir}/xen/lowlevel/acm.so |
685 | %attr(755,root,root) %{py_sitedir}/xen/lowlevel/checkpoint.so | |
686 | %attr(755,root,root) %{py_sitedir}/xen/lowlevel/flask.so | |
687 | %attr(755,root,root) %{py_sitedir}/xen/lowlevel/netlink.so | |
688 | %attr(755,root,root) %{py_sitedir}/xen/lowlevel/ptsname.so | |
689 | %attr(755,root,root) %{py_sitedir}/xen/lowlevel/xc.so | |
690 | %attr(755,root,root) %{py_sitedir}/xen/lowlevel/xl.so | |
e9753e37 | 691 | %{py_sitedir}/xen/remus |
8e6e2740 ER |
692 | %{py_sitedir}/xen/sv |
693 | %{py_sitedir}/xen/util | |
694 | %{py_sitedir}/xen/web | |
695 | %{py_sitedir}/xen/xend | |
696 | %{py_sitedir}/xen/xm | |
697 | %{py_sitedir}/xen/xsview | |
698 | %{py_sitedir}/xen/*.py* | |
699 | %if "%{py_ver}" > "2.4" | |
94b34ae4 JB |
700 | %{py_sitedir}/pygrub-0.3-py*.egg-info |
701 | %{py_sitedir}/xen-3.0-py*.egg-info | |
8e6e2740 | 702 | %endif |
e9753e37 | 703 | |
263a9ffc JK |
704 | %files -n python-xen-guest |
705 | %defattr(644,root,root,755) | |
706 | %dir %{py_sitedir}/xen | |
707 | %{py_sitedir}/xen/__init__.py* | |
708 | %dir %{py_sitedir}/xen/lowlevel | |
709 | %{py_sitedir}/xen/lowlevel/__init__.py* | |
710 | %attr(755,root,root) %{py_sitedir}/xen/lowlevel/xs.so | |
711 | ||
e9753e37 MM |
712 | %files -n bash-completion-%{name} |
713 | %defattr(644,root,root,755) | |
94b34ae4 | 714 | /etc/bash_completion.d/xl.sh |