3 %bcond_without sdl # SDL UI and audio support
4 %bcond_without glx # OpenGL/GLX support
5 %bcond_without ceph # Ceph/RBD support
6 %bcond_without glusterfs # GlusterFS backend
7 %bcond_without rdma # RDMA-based migration support
8 %bcond_with gtk2 # GTK+ 2.x instead of 3.x
9 %bcond_without spice # SPICE support
10 %bcond_with esd # EsounD audio support
11 %bcond_without oss # OSS audio support
12 %bcond_without pulseaudio # PulseAudio audio support
13 %bcond_without xen # Xen backend driver support
15 Summary: QEMU CPU Emulator
16 Summary(pl.UTF-8): QEMU - emulator procesora
21 Group: Applications/Emulators
22 Source0: http://wiki.qemu-project.org/download/%{name}-%{version}.tar.bz2
23 # Source0-md5: 32893941d40d052a5e649efcf06aca06
25 # Loads kvm kernel modules at boot
26 Source3: kvm-modules-load.conf
31 Source6: ksm.sysconfig
33 Source8: ksmtuned.service
35 Source10: ksmtuned.conf
36 Source11: qemu-guest-agent.service
37 Source12: 99-qemu-guest-agent.rules
38 Patch0: %{name}-cflags.patch
39 Patch1: vgabios-widescreens.patch
40 Patch2: %{name}-whitelist.patch
41 Patch3: %{name}-system-libcacard.patch
42 # Proof of concept, for reference, do not remove
43 Patch4: %{name}-kde_virtual_workspaces_hack.patch
44 URL: http://www.qemu-project.org/
45 %{?with_opengl:BuildRequires: OpenGL-GLX-devel}
46 %{?with_sdl:BuildRequires: SDL-devel >= 1.2.1}
47 BuildRequires: alsa-lib-devel
49 BuildRequires: bluez-libs-devel
50 BuildRequires: brlapi-devel
51 %{?with_ceph:BuildRequires: ceph-devel}
52 BuildRequires: curl-devel
53 BuildRequires: cyrus-sasl-devel >= 2
54 %{?with_esd:BuildRequires: esound-devel}
55 BuildRequires: glib2-devel >= 1:2.12
56 %{?with_glusterfs:BuildRequires: glusterfs-devel >= 3.4}
57 BuildRequires: gnutls-devel
58 BuildRequires: libaio-devel
59 BuildRequires: libcacard-devel
60 BuildRequires: libcap-devel
61 BuildRequires: libcap-ng-devel
62 BuildRequires: libfdt-devel
63 %{?with_rdma:BuildRequires: libibverbs-devel}
64 BuildRequires: libiscsi-devel
65 BuildRequires: libjpeg-devel
66 BuildRequires: libpng-devel
67 %{?with_rdma:BuildRequires: librdmacm-devel}
68 BuildRequires: libseccomp-devel
69 BuildRequires: libssh2-devel >= 1.2.8
70 # for usb passthrough, when available
71 #BuildRequires: libusb-devel >= 1.0.13
72 BuildRequires: libuuid-devel
73 BuildRequires: ncurses-devel
74 BuildRequires: nss-devel >= 3.12.8
75 BuildRequires: perl-Encode
76 BuildRequires: perl-tools-pod
77 BuildRequires: pkgconfig
78 %{?with_pulseaudio:BuildRequires: pulseaudio-devel}
79 BuildRequires: rpmbuild(macros) >= 1.644
80 BuildRequires: sed >= 4.0
82 BuildRequires: spice-protocol >= 0.12.0
83 BuildRequires: spice-server-devel >= 0.12.0
85 BuildRequires: texi2html
86 BuildRequires: texinfo
87 BuildRequires: usbredir-devel >= 0.6
88 BuildRequires: vde2-devel
90 %{?with_xen:BuildRequires: xen-devel >= 3.4}
91 BuildRequires: xfsprogs-devel
92 BuildRequires: xorg-lib-libX11-devel
93 BuildRequires: zlib-devel
95 BuildRequires: gtk+2-devel >= 2:2.18.0
96 BuildRequires: vte0-devel >= 0.24.0
98 BuildRequires: gtk+3-devel >= 3.0.0
99 BuildRequires: vte-devel >= 0.32.0
101 Requires: %{name}-img = %{version}-%{release}
102 Requires: %{name}-system-alpha = %{version}-%{release}
103 Requires: %{name}-system-arm = %{version}-%{release}
104 Requires: %{name}-system-cris = %{version}-%{release}
105 Requires: %{name}-system-lm32 = %{version}-%{release}
106 Requires: %{name}-system-m68k = %{version}-%{release}
107 Requires: %{name}-system-microblaze = %{version}-%{release}
108 Requires: %{name}-system-mips = %{version}-%{release}
109 Requires: %{name}-system-moxie = %{version}-%{release}
110 Requires: %{name}-system-or32 = %{version}-%{release}
111 Requires: %{name}-system-ppc = %{version}-%{release}
112 Requires: %{name}-system-s390x = %{version}-%{release}
113 Requires: %{name}-system-sh4 = %{version}-%{release}
114 Requires: %{name}-system-sparc = %{version}-%{release}
115 Requires: %{name}-system-unicore32 = %{version}-%{release}
116 Requires: %{name}-system-x86 = %{version}-%{release}
117 Requires: %{name}-system-xtensa = %{version}-%{release}
118 Requires: %{name}-user = %{version}-%{release}
120 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
122 %define systempkg_req \
123 Requires: SDL >= 1.2.1 \
124 Requires: usbredir >= 0.6 \
126 Requires: gtk+2 >= 2:2.18.0 \
127 Requires: vte0 >= 0.24.0 \
129 Requires: gtk+3 >= 3.0.0 \
130 Requires: vte >= 0.32.0 \
133 # some PPC/SPARC boot image in ELF format
134 %define _noautostrip .*%{_datadir}/qemu/.*-.*
137 QEMU is a FAST! processor emulator. By using dynamic translation it
138 achieves a reasonnable speed while being easy to port on new host
139 CPUs. QEMU has two operating modes:
141 - User mode emulation. In this mode, QEMU can launch Linux processes
142 compiled for one CPU on another CPU. Linux system calls are converted
143 because of endianness and 32/64 bit mismatches. Wine (Windows
144 emulation) and DOSEMU (DOS emulation) are the main targets for QEMU.
146 - Full system emulation. In this mode, QEMU emulates a full system,
147 including a processor and various peripherials. It can also be used to
148 provide virtual hosting of several virtual PC on a single server.
150 %description -l pl.UTF-8
151 QEMU to szybki(!) emulator procesora. Poprzez użycie dynamicznego
152 tłumaczenia osiąga rozsądną szybkość i jest łatwy do przeportowania,
153 aby działał na kolejnych procesorach. QEMU ma dwa tryby pracy:
155 - Emulacja trybu użytkownika. W tym trybie QEMU może uruchamiać
156 procesy linuksowe skompilowane dla jednego procesora na innym
157 procesorze. Linuksowe wywołania systemowe są tłumaczone ze względu na
158 niezgodność kolejności bajtów w słowie i 32/64-bitowego rozmiaru
159 słowa. Wine (emulacja Windows) i DOSEMU (emulacja DOS-a) to główne
162 - Pełna emulacja systemu. W tym trybie QEMU emuluje cały system,
163 włączając w to procesor i różne urządzenia peryferyjne. Może być także
164 używane do wirtualnego hostowania kilku wirtualnych pecetów na
165 pojedynczym serwerze.
168 Summary: QEMU common files needed by all QEMU targets
169 Summary(pl.UTF-8): Wspólne pliki QEMU wymagane przez wszystkie środowiska QEMU
170 Group: Development/Tools
171 Requires(post,preun,postun): systemd-units >= 38
172 Requires(postun): /usr/sbin/groupdel
173 Requires(postun): /usr/sbin/userdel
174 Requires(pre): /bin/id
175 Requires(pre): /usr/bin/getgid
176 Requires(pre): /usr/sbin/groupadd
177 Requires(pre): /usr/sbin/useradd
178 Requires: glib2 >= 1:2.12
179 Requires: libssh2 >= 1.2.8
180 Requires: systemd-units >= 38
181 Provides: group(qemu)
183 Obsoletes: qemu-kvm-common
184 Conflicts: qemu < 1.0-2
187 QEMU is a generic and open source processor emulator which achieves a
188 good emulation speed by using dynamic translation.
190 This package provides the common files needed by all QEMU targets.
192 %description common -l pl.UTF-8
193 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
194 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
196 Ten pakiet udostępnia wspólne pliki wymagane przez wszystkie
200 Summary: QEMU command line tool for manipulating disk images
201 Summary(pl.UTF-8): Narzędzie QEMU do operacji na obrazach dysków
202 Group: Development/Tools
203 Conflicts: qemu < 1.0-2
204 Obsoletes: qemu-kvm-img
207 This package provides a command line tool for manipulating disk
210 %description img -l pl.UTF-8
211 Ten pakiet udostępnia działające z linii poleceń narzędzia do operacji
215 Summary: QEMU user mode emulation of qemu targets
216 Summary(pl.UTF-8): QEMU - emulacja trybu użytkownika środowisk qemu
217 Group: Development/Tools
218 Requires: %{name}-common = %{version}-%{release}
219 Requires(post,postun): systemd-units >= 38
220 Requires: systemd-units >= 38
221 Obsoletes: qemu-kvm-user
224 QEMU is a generic and open source processor emulator which achieves a
225 good emulation speed by using dynamic translation.
227 This package provides the user mode emulation of QEMU targets.
229 %description user -l pl.UTF-8
230 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
231 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
233 Ten pakiet udostępnia emulację trybu użytkownika środowisk QEMU.
235 %package system-alpha
236 Summary: QEMU system emulator for Alpha
237 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem Alpha
238 Group: Development/Tools
239 Requires: %{name}-common = %{version}-%{release}
241 Obsoletes: qemu-kvm-system-alpha
243 %description system-alpha
244 QEMU is a generic and open source processor emulator which achieves a
245 good emulation speed by using dynamic translation.
247 This package provides the system emulator with Alpha CPU.
249 %description system-alpha -l pl.UTF-8
250 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
251 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
253 Ten pakiet zawiera emulator systemu z procesorem Alpha.
256 Summary: QEMU system emulator for ARM
257 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem ARM
258 Group: Development/Tools
259 Requires: %{name}-common = %{version}-%{release}
261 Obsoletes: qemu-kvm-system-arm
263 %description system-arm
264 QEMU is a generic and open source processor emulator which achieves a
265 good emulation speed by using dynamic translation.
267 This package provides the system emulator for ARM.
269 %description system-arm -l pl.UTF-8
270 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
271 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
273 Ten pakiet zawiera emulator systemu z procesorem ARM.
276 Summary: QEMU system emulator for CRIS
277 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem CRIS
278 Group: Development/Tools
279 Requires: %{name}-common = %{version}-%{release}
281 Obsoletes: qemu-kvm-system-cris
283 %description system-cris
284 QEMU is a generic and open source processor emulator which achieves a
285 good emulation speed by using dynamic translation.
287 This package provides the system emulator with CRIS CPU.
289 %description system-cris -l pl.UTF-8
290 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
291 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
293 Ten pakiet zawiera emulator systemu z procesorem CRIS.
296 Summary: QEMU system emulator for LM32
297 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem LM32
298 Group: Development/Tools
299 Requires: %{name}-common = %{version}-%{release}
301 Obsoletes: qemu-kvm-system-lm32
303 %description system-lm32
304 QEMU is a generic and open source processor emulator which achieves a
305 good emulation speed by using dynamic translation.
307 This package provides the system emulator with LM32 CPU.
309 %description system-lm32 -l pl.UTF-8
310 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
311 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
313 Ten pakiet zawiera emulator systemu z procesorem LM32.
316 Summary: QEMU system emulator for m68k
317 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem m68k
318 Group: Development/Tools
319 Requires: %{name}-common = %{version}-%{release}
321 Obsoletes: qemu-kvm-system-m68k
323 %description system-m68k
324 QEMU is a generic and open source processor emulator which achieves a
325 good emulation speed by using dynamic translation.
327 This package provides the system emulator with m68k CPU.
329 %description system-m68k -l pl.UTF-8
330 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
331 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
333 Ten pakiet zawiera emulator systemu z procesorem m68k.
335 %package system-microblaze
336 Summary: QEMU system emulator for MicroBlaze
337 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem MicroBlaze
338 Group: Development/Tools
339 Requires: %{name}-common = %{version}-%{release}
341 Obsoletes: qemu-kvm-system-microblaze
343 %description system-microblaze
344 QEMU is a generic and open source processor emulator which achieves a
345 good emulation speed by using dynamic translation.
347 This package provides the system emulator with MicroBlaze CPU.
349 %description system-microblaze -l pl.UTF-8
350 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
351 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
353 Ten pakiet zawiera emulator systemu z procesorem MicroBlaze.
356 Summary: QEMU system emulator for MIPS
357 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem MIPS
358 Group: Development/Tools
359 Requires: %{name}-common = %{version}-%{release}
361 Obsoletes: qemu-kvm-system-mips
363 %description system-mips
364 QEMU is a generic and open source processor emulator which achieves a
365 good emulation speed by using dynamic translation.
367 This package provides the system emulator with MIPS CPU.
369 %description system-mips -l pl.UTF-8
370 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
371 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
373 Ten pakiet zawiera emulator systemu z procesorem MIPS.
375 %package system-moxie
376 Summary: QEMU system emulator for Moxie
377 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem Moxie
378 Group: Development/Tools
379 Requires: %{name}-common = %{version}-%{release}
382 %description system-moxie
383 QEMU is a generic and open source processor emulator which achieves a
384 good emulation speed by using dynamic translation.
386 This package provides the system emulator with Moxie CPU.
388 %description system-moxie -l pl.UTF-8
389 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
390 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
392 Ten pakiet zawiera emulator systemu z procesorem Moxie.
395 Summary: QEMU system emulator for OpenRISC
396 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem OpenRISC
397 Group: Development/Tools
398 Requires: %{name}-common = %{version}-%{release}
400 Obsoletes: qemu-kvm-system-or32
402 %description system-or32
403 QEMU is a generic and open source processor emulator which achieves a
404 good emulation speed by using dynamic translation.
406 This package provides the system emulator with OpenRISC CPU.
408 %description system-or32 -l pl.UTF-8
409 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
410 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
412 Ten pakiet zawiera emulator systemu z procesorem OpenRISC.
415 Summary: QEMU system emulator for PowerPC
416 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem PowerPC
417 Group: Development/Tools
418 Requires: %{name}-common = %{version}-%{release}
420 Obsoletes: qemu-kvm-system-ppc
422 %description system-ppc
423 QEMU is a generic and open source processor emulator which achieves a
424 good emulation speed by using dynamic translation.
426 This package provides the system emulator with PowerPC CPU.
428 %description system-ppc -l pl.UTF-8
429 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
430 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
432 Ten pakiet zawiera emulator systemu z procesorem PowerPC.
434 %package system-s390x
435 Summary: QEMU system emulator for S390
436 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem S390
437 Group: Development/Tools
438 Requires: %{name}-common = %{version}-%{release}
440 Obsoletes: qemu-kvm-system-s390x
442 %description system-s390x
443 QEMU is a generic and open source processor emulator which achieves a
444 good emulation speed by using dynamic translation.
446 This package provides the system emulator with S390 CPU.
448 %description system-s390x -l pl.UTF-8
449 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
450 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
452 Ten pakiet zawiera emulator systemu z procesorem S390.
455 Summary: QEMU system emulator for SH4
456 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem SH4
457 Group: Development/Tools
458 Requires: %{name}-common = %{version}-%{release}
460 Obsoletes: qemu-kvm-system-sh4
462 %description system-sh4
463 QEMU is a generic and open source processor emulator which achieves a
464 good emulation speed by using dynamic translation.
466 This package provides the system emulator with SH4 CPU.
468 %description system-sh4 -l pl.UTF-8
469 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
470 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
472 Ten pakiet zawiera emulator systemu z procesorem SH4.
474 %package system-sparc
475 Summary: QEMU system emulator for SPARC
476 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem SPARC
477 Group: Development/Tools
478 Requires: %{name}-common = %{version}-%{release}
480 Obsoletes: qemu-kvm-system-sparc
482 %description system-sparc
483 QEMU is a generic and open source processor emulator which achieves a
484 good emulation speed by using dynamic translation.
486 This package provides the system emulator with SPARC/SPARC64 CPU.
488 %description system-sparc -l pl.UTF-8
489 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
490 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
492 Ten pakiet zawiera emulator systemu z procesorem SPARC/SPARC64.
494 %package system-unicore32
495 Summary: QEMU system emulator for UniCore32
496 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem UniCore32
497 Group: Development/Tools
498 Requires: %{name}-common = %{version}-%{release}
500 Obsoletes: qemu-kvm-system-unicore32
502 %description system-unicore32
503 QEMU is a generic and open source processor emulator which achieves a
504 good emulation speed by using dynamic translation.
506 This package provides the system emulator with UniCore32 CPU.
508 %description system-unicore32 -l pl.UTF-8
509 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
510 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
512 Ten pakiet zawiera emulator systemu z procesorem UniCore32.
515 Summary: QEMU system emulator for x86
516 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem x86
517 Group: Development/Tools
518 Requires: %{name}-common = %{version}-%{release}
521 Obsoletes: qemu-kvm-system-x86
523 %description system-x86
524 QEMU is a generic and open source processor emulator which achieves a
525 good emulation speed by using dynamic translation.
527 %description system-x86 -l pl.UTF-8
528 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
529 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
531 %package system-xtensa
532 Summary: QEMU system emulator for Xtensa
533 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem Xtensa
534 Group: Development/Tools
535 Requires: %{name}-common = %{version}-%{release}
537 Obsoletes: qemu-kvm-system-xtensa
539 %description system-xtensa
540 QEMU is a generic and open source processor emulator which achieves a
541 good emulation speed by using dynamic translation.
543 This package provides the system emulator with Xtensa CPU.
545 %description system-xtensa -l pl.UTF-8
546 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
547 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
549 Ten pakiet zawiera emulator systemu z procesorem Xtensa.
552 Summary: QEMU guest agent
553 Summary(pl.UTF-8): Agent gościa QEMU
555 Requires(post,preun,postun): systemd-units >= 38
556 Requires: glib2 >= 1:2.12
557 Requires: systemd-units >= 38
558 Obsoletes: qemu-kvm-guest-agent
560 %description guest-agent
561 QEMU is a generic and open source processor emulator which achieves
562 a good emulation speed by using dynamic translation.
564 This package provides an agent to run inside guests, which
565 communicates with the host over a virtio-serial channel named
566 "org.qemu.guest_agent.0".
568 This package does not need to be installed on the host OS.
570 %description guest-agent -l pl.UTF-8
571 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
572 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
574 Ten pakiet udostępnia agenta przeznaczonego do uruchomienia w
575 systemach-gościach, komunikującego się kanałem virtio-serial o nazwie
576 "org.qemu.guest_agent.0".
578 Ten pakiet nie musi być zainstalowany w systemie hosta.
587 %{__mv} libcacard libcacard-use-system-lib
589 # workaround for conflict with alsa/error.h
590 ln -s ../error.h qapi/error.h
594 --extra-cflags="%{rpmcflags} -I/usr/include/ncurses" \
595 --extra-ldflags="%{rpmldflags}" \
596 --prefix=%{_prefix} \
597 --sysconfdir=%{_sysconfdir} \
599 --host-cc="%{__cc}" \
609 %{__enable_disable glusterfs} \
611 %{__enable_disable glx} \
612 %{__enable_disable ceph rbd} \
613 %{__enable_disable rdma} \
614 %{__enable_disable sdl} \
616 %{__enable_disable spice} \
617 --enable-smartcard-nss \
628 %{__enable_disable xen} \
629 --audio-drv-list="alsa%{?with_iss:,oss}%{?with_sdl:,sdl}%{?with_esd:,esd}%{?with_pulseaudio:,pa}" \
630 --interp-prefix=%{_libdir}/qemu/lib-%%M \
631 --with-gtkabi="%{?with_gtk2:2.0}%{!?with_gtk2:3.0}"
633 # note: CONFIG_QEMU_HELPERDIR is used when compiling, libexecdir when installing;
634 # --libexecdir in configure is nop
637 CONFIG_QEMU_HELPERDIR="%{_libdir}"
639 # rebuild patched vesa tables with additional widescreen modes.
640 %{__make} -C roms/vgabios stdvga-bios
642 %{__cc} %{SOURCE7} %{rpmcflags} -o ksmctl
645 rm -rf $RPM_BUILD_ROOT
646 install -d $RPM_BUILD_ROOT{%{systemdunitdir},/usr/lib/binfmt.d} \
647 $RPM_BUILD_ROOT/etc/{sysconfig,udev/rules.d,modules-load.d} \
648 $RPM_BUILD_ROOT{%{_sysconfdir}/sasl,%{_sbindir}}
651 DESTDIR=$RPM_BUILD_ROOT \
652 libexecdir=%{_libdir}
654 install -d $RPM_BUILD_ROOT%{_sysconfdir}
655 cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/qemu-ifup
660 install -p qemu.sasl $RPM_BUILD_ROOT%{_sysconfdir}/sasl/qemu.conf
662 %ifarch %{ix86} %{x8664}
663 install scripts/kvm/kvm_stat $RPM_BUILD_ROOT%{_bindir}
664 install -p %{SOURCE3} $RPM_BUILD_ROOT/etc/modules-load.d/kvm.conf
665 install -p %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/udev/rules.d
668 install -p %{SOURCE5} $RPM_BUILD_ROOT%{systemdunitdir}/ksm.service
669 install -p %{SOURCE6} $RPM_BUILD_ROOT/etc/sysconfig/ksm
670 install -p ksmctl $RPM_BUILD_ROOT%{_sbindir}
672 install -p %{SOURCE8} $RPM_BUILD_ROOT%{systemdunitdir}/ksmtuned.service
673 install -p %{SOURCE9} $RPM_BUILD_ROOT%{_sbindir}/ksmtuned
674 install -p %{SOURCE10} $RPM_BUILD_ROOT%{_sysconfdir}/ksmtuned.conf
676 # For the qemu-guest-agent subpackage install the systemd
677 # service and udev rules.
678 install -p %{SOURCE11} $RPM_BUILD_ROOT%{systemdunitdir}
679 install -p %{SOURCE12} $RPM_BUILD_ROOT%{_sysconfdir}/udev/rules.d
682 %ifnarch %{ix86} %{x8664}
691 %ifnarch sparc sparc64
698 test $i = dummy && continue
699 grep /$i:\$ %{SOURCE2} > $RPM_BUILD_ROOT/usr/lib/binfmt.d/$i.conf
703 %{__rm} $RPM_BUILD_ROOT%{_docdir}/qemu/qemu-{doc,tech}.html
704 %{__rm} $RPM_BUILD_ROOT%{_docdir}/qemu/qmp-commands.txt
706 # install patched vesa tables with additional widescreen modes.
707 cp -p roms/vgabios/VGABIOS-lgpl-latest.stdvga.bin $RPM_BUILD_ROOT%{_datadir}/%{name}/vgabios-stdvga.bin
709 %{__mv} $RPM_BUILD_ROOT%{_datadir}/locale/{de_DE,de}
710 %{__mv} $RPM_BUILD_ROOT%{_datadir}/locale/{fr_FR,fr}
714 rm -rf $RPM_BUILD_ROOT
718 %groupadd -g 276 qemu
719 %useradd -u 276 -g qemu -G kvm -c "QEMU User" qemu
722 %systemd_post ksm.service
723 %systemd_post ksmtuned.service
726 %systemd_preun ksm.service
727 %systemd_preun ksmtuned.service
730 if [ "$1" = "0" ]; then
737 %triggerpostun common -- qemu-common < 1.6.1-4
738 %systemd_trigger ksm.service
739 %systemd_trigger ksmtuned.service
742 %systemd_service_restart systemd-binfmt.service
745 %systemd_service_restart systemd-binfmt.service
751 %systemd_preun qemu-guest-agent.service
757 %defattr(644,root,root,755)
759 %files common -f %{name}.lang
760 %defattr(644,root,root,755)
761 %doc README qemu-doc.html qemu-tech.html qmp-commands.txt
762 %attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/qemu-ifup
763 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/qemu/target-*.conf
764 %config(noreplace) %verify(not md5 mtime size) /etc/ksmtuned.conf
765 %config(noreplace) %verify(not md5 mtime size) /etc/sasl/qemu.conf
766 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/ksm
767 %{systemdunitdir}/ksm.service
768 %{systemdunitdir}/ksmtuned.service
769 %dir %{_sysconfdir}/qemu
770 %attr(755,root,root) %{_bindir}/virtfs-proxy-helper
771 %attr(755,root,root) %{_bindir}/qemu-nbd
772 %attr(755,root,root) %{_libdir}/qemu-bridge-helper
773 %attr(755,root,root) %{_sbindir}/ksmctl
774 %attr(755,root,root) %{_sbindir}/ksmtuned
775 %{_mandir}/man1/qemu.1*
776 %{_mandir}/man1/virtfs-proxy-helper.1*
777 %{_mandir}/man8/qemu-nbd.8*
779 %dir %{_datadir}/qemu
780 %{_datadir}/%{name}/keymaps
781 %{_datadir}/%{name}/qemu-icon.bmp
782 # various bios images
783 %{_datadir}/%{name}/*.aml
784 %{_datadir}/%{name}/*.bin
785 %{_datadir}/%{name}/*.rom
786 %{_datadir}/%{name}/*.dtb
787 %{_datadir}/%{name}/qemu_logo_no_text.svg
788 %{_datadir}/%{name}/openbios-ppc
789 %{_datadir}/%{name}/openbios-sparc*
790 %{_datadir}/%{name}/palcode-clipper
791 %{_datadir}/%{name}/s390-ccw.img
794 %defattr(644,root,root,755)
795 %attr(755,root,root) %{_bindir}/qemu-img
796 %{_mandir}/man1/qemu-img.1*
799 %defattr(644,root,root,755)
800 /usr/lib/binfmt.d/qemu-*.conf
801 %attr(755,root,root) %{_bindir}/qemu-alpha
802 %attr(755,root,root) %{_bindir}/qemu-arm
803 %attr(755,root,root) %{_bindir}/qemu-armeb
804 %attr(755,root,root) %{_bindir}/qemu-cris
805 %attr(755,root,root) %{_bindir}/qemu-i386
806 %attr(755,root,root) %{_bindir}/qemu-io
807 %attr(755,root,root) %{_bindir}/qemu-m68k
808 %attr(755,root,root) %{_bindir}/qemu-microblaze
809 %attr(755,root,root) %{_bindir}/qemu-microblazeel
810 %attr(755,root,root) %{_bindir}/qemu-mips
811 %attr(755,root,root) %{_bindir}/qemu-mipsel
812 %attr(755,root,root) %{_bindir}/qemu-mips64
813 %attr(755,root,root) %{_bindir}/qemu-mips64el
814 %attr(755,root,root) %{_bindir}/qemu-mipsn32
815 %attr(755,root,root) %{_bindir}/qemu-mipsn32el
816 %attr(755,root,root) %{_bindir}/qemu-or32
817 %attr(755,root,root) %{_bindir}/qemu-ppc
818 %attr(755,root,root) %{_bindir}/qemu-ppc64
819 %attr(755,root,root) %{_bindir}/qemu-ppc64abi32
820 %attr(755,root,root) %{_bindir}/qemu-s390x
821 %attr(755,root,root) %{_bindir}/qemu-sh4
822 %attr(755,root,root) %{_bindir}/qemu-sh4eb
823 %attr(755,root,root) %{_bindir}/qemu-sparc
824 %attr(755,root,root) %{_bindir}/qemu-sparc32plus
825 %attr(755,root,root) %{_bindir}/qemu-sparc64
826 %attr(755,root,root) %{_bindir}/qemu-unicore32
827 %attr(755,root,root) %{_bindir}/qemu-x86_64
830 %defattr(644,root,root,755)
831 %attr(755,root,root) %{_bindir}/qemu-system-alpha
834 %defattr(644,root,root,755)
835 %attr(755,root,root) %{_bindir}/qemu-system-arm
838 %defattr(644,root,root,755)
839 %attr(755,root,root) %{_bindir}/qemu-system-cris
842 %defattr(644,root,root,755)
843 %attr(755,root,root) %{_bindir}/qemu-system-lm32
846 %defattr(644,root,root,755)
847 %attr(755,root,root) %{_bindir}/qemu-system-m68k
849 %files system-microblaze
850 %defattr(644,root,root,755)
851 %attr(755,root,root) %{_bindir}/qemu-system-microblaze
852 %attr(755,root,root) %{_bindir}/qemu-system-microblazeel
855 %defattr(644,root,root,755)
856 %attr(755,root,root) %{_bindir}/qemu-system-mips
857 %attr(755,root,root) %{_bindir}/qemu-system-mipsel
858 %attr(755,root,root) %{_bindir}/qemu-system-mips64
859 %attr(755,root,root) %{_bindir}/qemu-system-mips64el
862 %defattr(644,root,root,755)
863 %attr(755,root,root) %{_bindir}/qemu-system-moxie
866 %defattr(644,root,root,755)
867 %attr(755,root,root) %{_bindir}/qemu-system-or32
870 %defattr(644,root,root,755)
871 %attr(755,root,root) %{_bindir}/qemu-system-ppc
872 %attr(755,root,root) %{_bindir}/qemu-system-ppc64
873 %attr(755,root,root) %{_bindir}/qemu-system-ppcemb
876 %defattr(644,root,root,755)
877 %attr(755,root,root) %{_bindir}/qemu-system-s390x
880 %defattr(644,root,root,755)
881 %attr(755,root,root) %{_bindir}/qemu-system-sh4
882 %attr(755,root,root) %{_bindir}/qemu-system-sh4eb
885 %defattr(644,root,root,755)
886 %attr(755,root,root) %{_bindir}/qemu-system-sparc
887 %attr(755,root,root) %{_bindir}/qemu-system-sparc64
889 %files system-unicore32
890 %defattr(644,root,root,755)
891 %attr(755,root,root) %{_bindir}/qemu-system-unicore32
894 %defattr(644,root,root,755)
895 %attr(755,root,root) %{_bindir}/qemu-system-i386
896 %attr(755,root,root) %{_bindir}/qemu-system-x86_64
897 %ifarch %{ix86} %{x8664}
898 %config(noreplace) %verify(not md5 mtime size) /etc/modules-load.d/kvm.conf
899 %config(noreplace) %verify(not md5 mtime size) /etc/udev/rules.d/80-kvm.rules
900 %attr(755,root,root) %{_bindir}/kvm_stat
904 %defattr(644,root,root,755)
905 %attr(755,root,root) %{_bindir}/qemu-system-xtensa
906 %attr(755,root,root) %{_bindir}/qemu-system-xtensaeb
909 %config(noreplace) %verify(not md5 mtime size) /etc/udev/rules.d/99-qemu-guest-agent.rules
910 %{systemdunitdir}/qemu-guest-agent.service
911 %attr(755,root,root) %{_bindir}/qemu-ga