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 gtk3 # Do not build GTK UI
10 %bcond_without spice # SPICE support
11 %bcond_with esd # EsounD audio support
12 %bcond_without oss # OSS audio support
13 %bcond_without pulseaudio # PulseAudio audio support
14 %bcond_without xen # Xen backend driver support
15 %bcond_without bluetooth # bluetooth support
16 %bcond_without brlapi # brlapi support
17 %bcond_without smartcard # smartcard-nss support
18 %bcond_without iscsi # iscsi support
19 %bcond_without seccomp # seccomp support
20 %bcond_without usbredir # usb network redirection support
21 %bcond_without system_seabios # system seabios binary
27 Summary: QEMU CPU Emulator
28 Summary(pl.UTF-8): QEMU - emulator procesora
33 Group: Applications/Emulators
34 Source0: http://wiki.qemu-project.org/download/%{name}-%{version}.tar.bz2
35 # Source0-md5: 9541063d999cf9659ed7fdce71314f31
36 Source2: %{name}.binfmt
37 # Loads kvm kernel modules at boot
38 Source3: kvm-modules-load.conf
43 Source6: ksm.sysconfig
45 Source8: ksmtuned.service
47 Source10: ksmtuned.conf
48 Source11: %{name}-guest-agent.service
49 Source12: 99-%{name}-guest-agent.rules
50 Patch0: %{name}-cflags.patch
51 Patch1: vgabios-widescreens.patch
52 Patch2: %{name}-whitelist.patch
53 Patch3: %{name}-system-libcacard.patch
55 Patch5: %{name}-xattr.patch
56 Patch6: libjpeg-boolean.patch
57 # Proof of concept, for reference, do not remove
58 Patch400: %{name}-kde_virtual_workspaces_hack.patch
59 URL: http://www.qemu-project.org/
60 %{?with_opengl:BuildRequires: OpenGL-GLX-devel}
61 %{?with_sdl:BuildRequires: SDL-devel >= 1.2.1}
62 BuildRequires: alsa-lib-devel
64 %{?with_bluetooth:BuildRequires: bluez-libs-devel}
65 %{?with_brlapi:BuildRequires: brlapi-devel}
66 %{?with_ceph:BuildRequires: ceph-devel}
67 BuildRequires: curl-devel
68 BuildRequires: cyrus-sasl-devel >= 2
69 %{?with_esd:BuildRequires: esound-devel}
70 BuildRequires: glib2-devel >= 1:2.12
71 %{?with_glusterfs:BuildRequires: glusterfs-devel >= 3.4}
72 BuildRequires: gnutls-devel
73 BuildRequires: libaio-devel
74 %{?with_smartcard:BuildRequires: libcacard-devel}
75 BuildRequires: libcap-devel
76 BuildRequires: libcap-ng-devel
77 BuildRequires: libfdt-devel
78 %{?with_rdma:BuildRequires: libibverbs-devel}
79 %{?with_iscsi:BuildRequires: libiscsi-devel}
80 BuildRequires: libjpeg-devel
81 BuildRequires: libpng-devel
82 %{?with_rdma:BuildRequires: librdmacm-devel}
83 %{?with_seccomp:BuildRequires: libseccomp-devel}
84 BuildRequires: libssh2-devel >= 1.2.8
85 # for usb passthrough, when available
86 #BuildRequires: libusb-devel >= 1.0.13
87 BuildRequires: libuuid-devel
88 BuildRequires: ncurses-devel
89 %{?with_smartcard:BuildRequires: nss-devel >= 3.12.8}
90 BuildRequires: perl-Encode
91 BuildRequires: perl-tools-pod
92 BuildRequires: pkgconfig
93 %{?with_pulseaudio:BuildRequires: pulseaudio-devel}
94 BuildRequires: rpmbuild(macros) >= 1.644
95 %{?with_system_seabios:BuildRequires: seabios}
96 BuildRequires: sed >= 4.0
98 BuildRequires: spice-protocol >= 0.12.0
99 BuildRequires: spice-server-devel >= 0.12.0
101 BuildRequires: texi2html
102 BuildRequires: texinfo
103 %{?with_usbredir:BuildRequires: usbredir-devel >= 0.6}
104 BuildRequires: vde2-devel
106 %{?with_xen:BuildRequires: xen-devel >= 3.4}
107 BuildRequires: xfsprogs-devel
108 BuildRequires: xorg-lib-libX11-devel
109 BuildRequires: zlib-devel
111 BuildRequires: gtk+2-devel >= 2:2.18.0
112 BuildRequires: vte0-devel >= 0.24.0
115 BuildRequires: gtk+3-devel >= 3.0.0
116 BuildRequires: vte-devel >= 0.32.0
118 Requires: %{name}-img = %{version}-%{release}
119 Requires: %{name}-system-alpha = %{version}-%{release}
120 Requires: %{name}-system-arm = %{version}-%{release}
121 Requires: %{name}-system-cris = %{version}-%{release}
122 Requires: %{name}-system-lm32 = %{version}-%{release}
123 Requires: %{name}-system-m68k = %{version}-%{release}
124 Requires: %{name}-system-microblaze = %{version}-%{release}
125 Requires: %{name}-system-mips = %{version}-%{release}
126 Requires: %{name}-system-moxie = %{version}-%{release}
127 Requires: %{name}-system-or32 = %{version}-%{release}
128 Requires: %{name}-system-ppc = %{version}-%{release}
129 Requires: %{name}-system-s390x = %{version}-%{release}
130 Requires: %{name}-system-sh4 = %{version}-%{release}
131 Requires: %{name}-system-sparc = %{version}-%{release}
132 Requires: %{name}-system-unicore32 = %{version}-%{release}
133 Requires: %{name}-system-x86 = %{version}-%{release}
134 Requires: %{name}-system-xtensa = %{version}-%{release}
135 Requires: %{name}-user = %{version}-%{release}
137 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
139 %define systempkg_req \
141 Requires: SDL >= 1.2.1 \
143 %if %{with usbredir} \
144 Requires: usbredir >= 0.6 \
147 Requires: gtk+2 >= 2:2.18.0 \
148 Requires: vte0 >= 0.24.0 \
151 Requires: gtk+3 >= 3.0.0 \
152 Requires: vte >= 0.32.0 \
155 # some PPC/SPARC boot image in ELF format
156 %define _noautostrip .*%{_datadir}/qemu/.*-.*
159 QEMU is a FAST! processor emulator. By using dynamic translation it
160 achieves a reasonnable speed while being easy to port on new host
161 CPUs. QEMU has two operating modes:
163 - User mode emulation. In this mode, QEMU can launch Linux processes
164 compiled for one CPU on another CPU. Linux system calls are converted
165 because of endianness and 32/64 bit mismatches. Wine (Windows
166 emulation) and DOSEMU (DOS emulation) are the main targets for QEMU.
168 - Full system emulation. In this mode, QEMU emulates a full system,
169 including a processor and various peripherials. It can also be used to
170 provide virtual hosting of several virtual PC on a single server.
172 %description -l pl.UTF-8
173 QEMU to szybki(!) emulator procesora. Poprzez użycie dynamicznego
174 tłumaczenia osiąga rozsądną szybkość i jest łatwy do przeportowania,
175 aby działał na kolejnych procesorach. QEMU ma dwa tryby pracy:
177 - Emulacja trybu użytkownika. W tym trybie QEMU może uruchamiać
178 procesy linuksowe skompilowane dla jednego procesora na innym
179 procesorze. Linuksowe wywołania systemowe są tłumaczone ze względu na
180 niezgodność kolejności bajtów w słowie i 32/64-bitowego rozmiaru
181 słowa. Wine (emulacja Windows) i DOSEMU (emulacja DOS-a) to główne
184 - Pełna emulacja systemu. W tym trybie QEMU emuluje cały system,
185 włączając w to procesor i różne urządzenia peryferyjne. Może być także
186 używane do wirtualnego hostowania kilku wirtualnych pecetów na
187 pojedynczym serwerze.
190 Summary: QEMU common files needed by all QEMU targets
191 Summary(pl.UTF-8): Wspólne pliki QEMU wymagane przez wszystkie środowiska QEMU
192 Group: Development/Tools
193 Requires(post,preun,postun): systemd-units >= 38
194 Requires(postun): /usr/sbin/groupdel
195 Requires(postun): /usr/sbin/userdel
196 Requires(pre): /bin/id
197 Requires(pre): /usr/bin/getgid
198 Requires(pre): /usr/sbin/groupadd
199 Requires(pre): /usr/sbin/useradd
200 Requires: glib2 >= 1:2.12
201 Requires: libssh2 >= 1.2.8
202 Requires: systemd-units >= 38
203 Provides: group(qemu)
205 Obsoletes: qemu-kvm-common
206 Conflicts: qemu < 1.0-2
209 QEMU is a generic and open source processor emulator which achieves a
210 good emulation speed by using dynamic translation.
212 This package provides the common files needed by all QEMU targets.
214 %description common -l pl.UTF-8
215 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
216 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
218 Ten pakiet udostępnia wspólne pliki wymagane przez wszystkie
222 Summary: QEMU command line tool for manipulating disk images
223 Summary(pl.UTF-8): Narzędzie QEMU do operacji na obrazach dysków
224 Group: Development/Tools
225 Obsoletes: qemu-kvm-img
226 Conflicts: qemu < 1.0-2
229 This package provides a command line tool for manipulating disk
232 %description img -l pl.UTF-8
233 Ten pakiet udostępnia działające z linii poleceń narzędzia do operacji
237 Summary: QEMU user mode emulation of qemu targets
238 Summary(pl.UTF-8): QEMU - emulacja trybu użytkownika środowisk qemu
239 Group: Development/Tools
240 Requires: %{name}-common = %{version}-%{release}
241 Requires(post,postun): systemd-units >= 38
242 Requires: systemd-units >= 38
243 Obsoletes: qemu-kvm-user
246 QEMU is a generic and open source processor emulator which achieves a
247 good emulation speed by using dynamic translation.
249 This package provides the user mode emulation of QEMU targets.
251 %description user -l pl.UTF-8
252 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
253 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
255 Ten pakiet udostępnia emulację trybu użytkownika środowisk QEMU.
257 %package system-alpha
258 Summary: QEMU system emulator for Alpha
259 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem Alpha
260 Group: Development/Tools
261 Requires: %{name}-common = %{version}-%{release}
263 Obsoletes: qemu-kvm-system-alpha
265 %description system-alpha
266 QEMU is a generic and open source processor emulator which achieves a
267 good emulation speed by using dynamic translation.
269 This package provides the system emulator with Alpha CPU.
271 %description system-alpha -l pl.UTF-8
272 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
273 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
275 Ten pakiet zawiera emulator systemu z procesorem Alpha.
278 Summary: QEMU system emulator for ARM
279 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem ARM
280 Group: Development/Tools
281 Requires: %{name}-common = %{version}-%{release}
283 Obsoletes: qemu-kvm-system-arm
285 %description system-arm
286 QEMU is a generic and open source processor emulator which achieves a
287 good emulation speed by using dynamic translation.
289 This package provides the system emulator for ARM.
291 %description system-arm -l pl.UTF-8
292 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
293 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
295 Ten pakiet zawiera emulator systemu z procesorem ARM.
298 Summary: QEMU system emulator for CRIS
299 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem CRIS
300 Group: Development/Tools
301 Requires: %{name}-common = %{version}-%{release}
303 Obsoletes: qemu-kvm-system-cris
305 %description system-cris
306 QEMU is a generic and open source processor emulator which achieves a
307 good emulation speed by using dynamic translation.
309 This package provides the system emulator with CRIS CPU.
311 %description system-cris -l pl.UTF-8
312 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
313 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
315 Ten pakiet zawiera emulator systemu z procesorem CRIS.
318 Summary: QEMU system emulator for LM32
319 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem LM32
320 Group: Development/Tools
321 Requires: %{name}-common = %{version}-%{release}
323 Obsoletes: qemu-kvm-system-lm32
325 %description system-lm32
326 QEMU is a generic and open source processor emulator which achieves a
327 good emulation speed by using dynamic translation.
329 This package provides the system emulator with LM32 CPU.
331 %description system-lm32 -l pl.UTF-8
332 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
333 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
335 Ten pakiet zawiera emulator systemu z procesorem LM32.
338 Summary: QEMU system emulator for m68k
339 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem m68k
340 Group: Development/Tools
341 Requires: %{name}-common = %{version}-%{release}
343 Obsoletes: qemu-kvm-system-m68k
345 %description system-m68k
346 QEMU is a generic and open source processor emulator which achieves a
347 good emulation speed by using dynamic translation.
349 This package provides the system emulator with m68k CPU.
351 %description system-m68k -l pl.UTF-8
352 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
353 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
355 Ten pakiet zawiera emulator systemu z procesorem m68k.
357 %package system-microblaze
358 Summary: QEMU system emulator for MicroBlaze
359 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem MicroBlaze
360 Group: Development/Tools
361 Requires: %{name}-common = %{version}-%{release}
363 Obsoletes: qemu-kvm-system-microblaze
365 %description system-microblaze
366 QEMU is a generic and open source processor emulator which achieves a
367 good emulation speed by using dynamic translation.
369 This package provides the system emulator with MicroBlaze CPU.
371 %description system-microblaze -l pl.UTF-8
372 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
373 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
375 Ten pakiet zawiera emulator systemu z procesorem MicroBlaze.
378 Summary: QEMU system emulator for MIPS
379 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem MIPS
380 Group: Development/Tools
381 Requires: %{name}-common = %{version}-%{release}
383 Obsoletes: qemu-kvm-system-mips
385 %description system-mips
386 QEMU is a generic and open source processor emulator which achieves a
387 good emulation speed by using dynamic translation.
389 This package provides the system emulator with MIPS CPU.
391 %description system-mips -l pl.UTF-8
392 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
393 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
395 Ten pakiet zawiera emulator systemu z procesorem MIPS.
397 %package system-moxie
398 Summary: QEMU system emulator for Moxie
399 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem Moxie
400 Group: Development/Tools
401 Requires: %{name}-common = %{version}-%{release}
404 %description system-moxie
405 QEMU is a generic and open source processor emulator which achieves a
406 good emulation speed by using dynamic translation.
408 This package provides the system emulator with Moxie CPU.
410 %description system-moxie -l pl.UTF-8
411 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
412 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
414 Ten pakiet zawiera emulator systemu z procesorem Moxie.
417 Summary: QEMU system emulator for OpenRISC
418 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem OpenRISC
419 Group: Development/Tools
420 Requires: %{name}-common = %{version}-%{release}
422 Obsoletes: qemu-kvm-system-or32
424 %description system-or32
425 QEMU is a generic and open source processor emulator which achieves a
426 good emulation speed by using dynamic translation.
428 This package provides the system emulator with OpenRISC CPU.
430 %description system-or32 -l pl.UTF-8
431 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
432 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
434 Ten pakiet zawiera emulator systemu z procesorem OpenRISC.
437 Summary: QEMU system emulator for PowerPC
438 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem PowerPC
439 Group: Development/Tools
440 Requires: %{name}-common = %{version}-%{release}
442 Obsoletes: qemu-kvm-system-ppc
444 %description system-ppc
445 QEMU is a generic and open source processor emulator which achieves a
446 good emulation speed by using dynamic translation.
448 This package provides the system emulator with PowerPC CPU.
450 %description system-ppc -l pl.UTF-8
451 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
452 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
454 Ten pakiet zawiera emulator systemu z procesorem PowerPC.
456 %package system-s390x
457 Summary: QEMU system emulator for S390
458 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem S390
459 Group: Development/Tools
460 Requires: %{name}-common = %{version}-%{release}
462 Obsoletes: qemu-kvm-system-s390x
464 %description system-s390x
465 QEMU is a generic and open source processor emulator which achieves a
466 good emulation speed by using dynamic translation.
468 This package provides the system emulator with S390 CPU.
470 %description system-s390x -l pl.UTF-8
471 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
472 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
474 Ten pakiet zawiera emulator systemu z procesorem S390.
477 Summary: QEMU system emulator for SH4
478 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem SH4
479 Group: Development/Tools
480 Requires: %{name}-common = %{version}-%{release}
482 Obsoletes: qemu-kvm-system-sh4
484 %description system-sh4
485 QEMU is a generic and open source processor emulator which achieves a
486 good emulation speed by using dynamic translation.
488 This package provides the system emulator with SH4 CPU.
490 %description system-sh4 -l pl.UTF-8
491 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
492 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
494 Ten pakiet zawiera emulator systemu z procesorem SH4.
496 %package system-sparc
497 Summary: QEMU system emulator for SPARC
498 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem SPARC
499 Group: Development/Tools
500 Requires: %{name}-common = %{version}-%{release}
502 Obsoletes: qemu-kvm-system-sparc
504 %description system-sparc
505 QEMU is a generic and open source processor emulator which achieves a
506 good emulation speed by using dynamic translation.
508 This package provides the system emulator with SPARC/SPARC64 CPU.
510 %description system-sparc -l pl.UTF-8
511 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
512 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
514 Ten pakiet zawiera emulator systemu z procesorem SPARC/SPARC64.
516 %package system-unicore32
517 Summary: QEMU system emulator for UniCore32
518 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem UniCore32
519 Group: Development/Tools
520 Requires: %{name}-common = %{version}-%{release}
522 Obsoletes: qemu-kvm-system-unicore32
524 %description system-unicore32
525 QEMU is a generic and open source processor emulator which achieves a
526 good emulation speed by using dynamic translation.
528 This package provides the system emulator with UniCore32 CPU.
530 %description system-unicore32 -l pl.UTF-8
531 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
532 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
534 Ten pakiet zawiera emulator systemu z procesorem UniCore32.
537 Summary: QEMU system emulator for x86
538 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem x86
539 Group: Development/Tools
540 Requires: %{name}-common = %{version}-%{release}
541 %{?with_system_seabios:Requires: seabios}
544 Obsoletes: qemu-kvm-system-x86
546 %description system-x86
547 QEMU is a generic and open source processor emulator which achieves a
548 good emulation speed by using dynamic translation.
550 %description system-x86 -l pl.UTF-8
551 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
552 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
554 %package system-xtensa
555 Summary: QEMU system emulator for Xtensa
556 Summary(pl.UTF-8): QEMU - emulator systemu z procesorem Xtensa
557 Group: Development/Tools
558 Requires: %{name}-common = %{version}-%{release}
560 Obsoletes: qemu-kvm-system-xtensa
562 %description system-xtensa
563 QEMU is a generic and open source processor emulator which achieves a
564 good emulation speed by using dynamic translation.
566 This package provides the system emulator with Xtensa CPU.
568 %description system-xtensa -l pl.UTF-8
569 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
570 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
572 Ten pakiet zawiera emulator systemu z procesorem Xtensa.
575 Summary: QEMU guest agent
576 Summary(pl.UTF-8): Agent gościa QEMU
578 Requires(post,preun,postun): systemd-units >= 38
579 Requires: glib2 >= 1:2.12
580 Requires: systemd-units >= 38
581 Obsoletes: qemu-kvm-guest-agent
583 %description guest-agent
584 QEMU is a generic and open source processor emulator which achieves a
585 good emulation speed by using dynamic translation.
587 This package provides an agent to run inside guests, which
588 communicates with the host over a virtio-serial channel named
589 "org.qemu.guest_agent.0".
591 This package does not need to be installed on the host OS.
593 %description guest-agent -l pl.UTF-8
594 QEMU to ogólny, mający otwarte źródła emulator procesora, osiągający
595 dobrą szybkość emulacji dzięki użyciu translacji dynamicznej.
597 Ten pakiet udostępnia agenta przeznaczonego do uruchomienia w
598 systemach-gościach, komunikującego się kanałem virtio-serial o nazwie
599 "org.qemu.guest_agent.0".
601 Ten pakiet nie musi być zainstalowany w systemie hosta.
613 %{__mv} libcacard libcacard-use-system-lib
615 # workaround for conflict with alsa/error.h
616 ln -s ../error.h qapi/error.h
620 --extra-cflags="%{rpmcflags} -I/usr/include/ncurses" \
621 --extra-ldflags="%{rpmldflags}" \
622 --prefix=%{_prefix} \
623 --sysconfdir=%{_sysconfdir} \
625 --host-cc="%{__cc}" \
628 %{__enable_disable bluetooth bluez} \
629 %{__enable_disable brlapi} \
635 %{__enable_disable glusterfs} \
636 %{__enable_disable iscsi libiscsi} \
637 %{__enable_disable glx} \
638 %{__enable_disable ceph rbd} \
639 %{__enable_disable rdma} \
640 %{__enable_disable sdl} \
641 %{__enable_disable seccomp} \
642 %{__enable_disable spice} \
643 %{__enable_disable smartcard smartcard-nss} \
645 %{__enable_disable usbredir usb-redir} \
654 %{__enable_disable xen} \
655 --audio-drv-list="alsa%{?with_iss:,oss}%{?with_sdl:,sdl}%{?with_esd:,esd}%{?with_pulseaudio:,pa}" \
656 --interp-prefix=%{_libdir}/qemu/lib-%%M \
657 %if %{without gtk2} && %{without gtk3}
660 --with-gtkabi="%{?with_gtk2:2.0}%{!?with_gtk2:3.0}"
663 # note: CONFIG_QEMU_HELPERDIR is used when compiling, libexecdir when installing;
664 # --libexecdir in configure is nop
667 CONFIG_QEMU_HELPERDIR="%{_libdir}" \
668 %{!?with_smartcard:CONFIG_USB_SMARTCARD=n}
670 # rebuild patched vesa tables with additional widescreen modes.
671 %{__make} -C roms/vgabios stdvga-bios
673 %{__cc} %{SOURCE7} %{rpmcflags} -o ksmctl
676 rm -rf $RPM_BUILD_ROOT
677 install -d $RPM_BUILD_ROOT{%{systemdunitdir},/usr/lib/binfmt.d} \
678 $RPM_BUILD_ROOT/etc/{sysconfig,udev/rules.d,modules-load.d} \
679 $RPM_BUILD_ROOT{%{_sysconfdir}/sasl,%{_sbindir}}
682 %{!?with_smartcard:CONFIG_USB_SMARTCARD=n} \
683 DESTDIR=$RPM_BUILD_ROOT \
684 libexecdir=%{_libdir}
686 install -d $RPM_BUILD_ROOT%{_sysconfdir}
687 cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/qemu-ifup
692 install -p qemu.sasl $RPM_BUILD_ROOT%{_sysconfdir}/sasl/qemu.conf
694 %ifarch %{ix86} %{x8664}
695 install -p scripts/kvm/kvm_stat $RPM_BUILD_ROOT%{_bindir}
696 install -p %{SOURCE3} $RPM_BUILD_ROOT/etc/modules-load.d/kvm.conf
697 install -p %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/udev/rules.d
700 install -p %{SOURCE5} $RPM_BUILD_ROOT%{systemdunitdir}/ksm.service
701 install -p %{SOURCE6} $RPM_BUILD_ROOT/etc/sysconfig/ksm
702 install -p ksmctl $RPM_BUILD_ROOT%{_sbindir}
704 install -p %{SOURCE8} $RPM_BUILD_ROOT%{systemdunitdir}/ksmtuned.service
705 install -p %{SOURCE9} $RPM_BUILD_ROOT%{_sbindir}/ksmtuned
706 install -p %{SOURCE10} $RPM_BUILD_ROOT%{_sysconfdir}/ksmtuned.conf
708 # For the qemu-guest-agent subpackage install the systemd
709 # service and udev rules.
710 install -p %{SOURCE11} $RPM_BUILD_ROOT%{systemdunitdir}
711 install -p %{SOURCE12} $RPM_BUILD_ROOT%{_sysconfdir}/udev/rules.d
714 %ifnarch %{ix86} %{x8664}
723 %ifnarch sparc sparc64
730 test $i = dummy && continue
731 grep /$i:\$ %{SOURCE2} > $RPM_BUILD_ROOT/usr/lib/binfmt.d/$i.conf
735 %{__rm} $RPM_BUILD_ROOT%{_docdir}/qemu/qemu-{doc,tech}.html
736 %{__rm} $RPM_BUILD_ROOT%{_docdir}/qemu/qmp-commands.txt
738 # install patched vesa tables with additional widescreen modes.
739 cp -p roms/vgabios/VGABIOS-lgpl-latest.stdvga.bin $RPM_BUILD_ROOT%{_datadir}/%{name}/vgabios-stdvga.bin
741 %if %{with system_seabios}
742 ln -sf /usr/share/seabios/bios.bin $RPM_BUILD_ROOT%{_datadir}/%{name}/bios.bin
743 for f in $RPM_BUILD_ROOT%{_datadir}/%{name}/*.aml ; do
745 if [ -e "/usr/share/seabios/$bn" ] ; then
746 ln -sf "/usr/share/seabios/$bn" "$f"
751 %if %{with gtk2} || %{with gtk3}
752 %{__mv} $RPM_BUILD_ROOT%{_localedir}/{de_DE,de}
753 %{__mv} $RPM_BUILD_ROOT%{_localedir}/{fr_FR,fr}
760 rm -rf $RPM_BUILD_ROOT
764 %groupadd -g 276 qemu
765 %useradd -u 276 -g qemu -G kvm -c "QEMU User" qemu
768 %systemd_post ksm.service
769 %systemd_post ksmtuned.service
772 %systemd_preun ksm.service
773 %systemd_preun ksmtuned.service
776 if [ "$1" = "0" ]; then
783 %triggerpostun common -- qemu-common < 1.6.1-4
784 %systemd_trigger ksm.service
785 %systemd_trigger ksmtuned.service
788 %systemd_service_restart systemd-binfmt.service
791 %systemd_service_restart systemd-binfmt.service
797 %systemd_preun qemu-guest-agent.service
803 %defattr(644,root,root,755)
805 %files common -f %{name}.lang
806 %defattr(644,root,root,755)
807 %doc README qemu-doc.html qemu-tech.html qmp-commands.txt
808 %attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/qemu-ifup
809 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/qemu/target-*.conf
810 %config(noreplace) %verify(not md5 mtime size) /etc/ksmtuned.conf
811 %config(noreplace) %verify(not md5 mtime size) /etc/sasl/qemu.conf
812 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/ksm
813 %{systemdunitdir}/ksm.service
814 %{systemdunitdir}/ksmtuned.service
815 %dir %{_sysconfdir}/qemu
816 %attr(755,root,root) %{_bindir}/virtfs-proxy-helper
817 %attr(755,root,root) %{_bindir}/qemu-nbd
818 %attr(755,root,root) %{_libdir}/qemu-bridge-helper
819 %attr(755,root,root) %{_sbindir}/ksmctl
820 %attr(755,root,root) %{_sbindir}/ksmtuned
821 %{_mandir}/man1/qemu.1*
822 %{_mandir}/man1/virtfs-proxy-helper.1*
823 %{_mandir}/man8/qemu-nbd.8*
825 %dir %{_datadir}/qemu
826 %{_datadir}/%{name}/keymaps
827 %{_datadir}/%{name}/qemu-icon.bmp
829 # various bios images
830 # all should be probably moved to the right system subpackage
831 %{_datadir}/%{name}/QEMU,tcx.bin
832 %{_datadir}/%{name}/bamboo.dtb
833 %{_datadir}/%{name}/efi-e1000.rom
834 %{_datadir}/%{name}/efi-eepro100.rom
835 %{_datadir}/%{name}/efi-ne2k_pci.rom
836 %{_datadir}/%{name}/efi-pcnet.rom
837 %{_datadir}/%{name}/efi-rtl8139.rom
838 %{_datadir}/%{name}/efi-virtio.rom
839 %{_datadir}/%{name}/kvmvapic.bin
840 %{_datadir}/%{name}/linuxboot.bin
841 %{_datadir}/%{name}/multiboot.bin
842 %{_datadir}/%{name}/openbios-ppc
843 %{_datadir}/%{name}/openbios-sparc*
844 %{_datadir}/%{name}/palcode-clipper
845 %{_datadir}/%{name}/petalogix-ml605.dtb
846 %{_datadir}/%{name}/petalogix-s3adsp1800.dtb
847 %{_datadir}/%{name}/ppc_rom.bin
848 %{_datadir}/%{name}/pxe-e1000.rom
849 %{_datadir}/%{name}/pxe-eepro100.rom
850 %{_datadir}/%{name}/pxe-ne2k_pci.rom
851 %{_datadir}/%{name}/pxe-pcnet.rom
852 %{_datadir}/%{name}/pxe-rtl8139.rom
853 %{_datadir}/%{name}/pxe-virtio.rom
854 %{_datadir}/%{name}/qemu_logo_no_text.svg
855 %{_datadir}/%{name}/s390-ccw.img
856 %{_datadir}/%{name}/s390-zipl.rom
857 %{_datadir}/%{name}/sgabios.bin
858 %{_datadir}/%{name}/slof.bin
859 %{_datadir}/%{name}/spapr-rtas.bin
860 %{_datadir}/%{name}/vgabios-cirrus.bin
861 %{_datadir}/%{name}/vgabios-qxl.bin
862 %{_datadir}/%{name}/vgabios-stdvga.bin
863 %{_datadir}/%{name}/vgabios-vmware.bin
864 %{_datadir}/%{name}/vgabios.bin
867 %defattr(644,root,root,755)
868 %attr(755,root,root) %{_bindir}/qemu-img
869 %{_mandir}/man1/qemu-img.1*
872 %defattr(644,root,root,755)
873 /usr/lib/binfmt.d/qemu-*.conf
874 %attr(755,root,root) %{_bindir}/qemu-alpha
875 %attr(755,root,root) %{_bindir}/qemu-arm
876 %attr(755,root,root) %{_bindir}/qemu-armeb
877 %attr(755,root,root) %{_bindir}/qemu-cris
878 %attr(755,root,root) %{_bindir}/qemu-i386
879 %attr(755,root,root) %{_bindir}/qemu-io
880 %attr(755,root,root) %{_bindir}/qemu-m68k
881 %attr(755,root,root) %{_bindir}/qemu-microblaze
882 %attr(755,root,root) %{_bindir}/qemu-microblazeel
883 %attr(755,root,root) %{_bindir}/qemu-mips
884 %attr(755,root,root) %{_bindir}/qemu-mipsel
885 %attr(755,root,root) %{_bindir}/qemu-mips64
886 %attr(755,root,root) %{_bindir}/qemu-mips64el
887 %attr(755,root,root) %{_bindir}/qemu-mipsn32
888 %attr(755,root,root) %{_bindir}/qemu-mipsn32el
889 %attr(755,root,root) %{_bindir}/qemu-or32
890 %attr(755,root,root) %{_bindir}/qemu-ppc
891 %attr(755,root,root) %{_bindir}/qemu-ppc64
892 %attr(755,root,root) %{_bindir}/qemu-ppc64abi32
893 %attr(755,root,root) %{_bindir}/qemu-s390x
894 %attr(755,root,root) %{_bindir}/qemu-sh4
895 %attr(755,root,root) %{_bindir}/qemu-sh4eb
896 %attr(755,root,root) %{_bindir}/qemu-sparc
897 %attr(755,root,root) %{_bindir}/qemu-sparc32plus
898 %attr(755,root,root) %{_bindir}/qemu-sparc64
899 %attr(755,root,root) %{_bindir}/qemu-unicore32
900 %attr(755,root,root) %{_bindir}/qemu-x86_64
903 %defattr(644,root,root,755)
904 %attr(755,root,root) %{_bindir}/qemu-system-alpha
907 %defattr(644,root,root,755)
908 %attr(755,root,root) %{_bindir}/qemu-system-arm
911 %defattr(644,root,root,755)
912 %attr(755,root,root) %{_bindir}/qemu-system-cris
915 %defattr(644,root,root,755)
916 %attr(755,root,root) %{_bindir}/qemu-system-lm32
919 %defattr(644,root,root,755)
920 %attr(755,root,root) %{_bindir}/qemu-system-m68k
922 %files system-microblaze
923 %defattr(644,root,root,755)
924 %attr(755,root,root) %{_bindir}/qemu-system-microblaze
925 %attr(755,root,root) %{_bindir}/qemu-system-microblazeel
928 %defattr(644,root,root,755)
929 %attr(755,root,root) %{_bindir}/qemu-system-mips
930 %attr(755,root,root) %{_bindir}/qemu-system-mipsel
931 %attr(755,root,root) %{_bindir}/qemu-system-mips64
932 %attr(755,root,root) %{_bindir}/qemu-system-mips64el
935 %defattr(644,root,root,755)
936 %attr(755,root,root) %{_bindir}/qemu-system-moxie
939 %defattr(644,root,root,755)
940 %attr(755,root,root) %{_bindir}/qemu-system-or32
943 %defattr(644,root,root,755)
944 %attr(755,root,root) %{_bindir}/qemu-system-ppc
945 %attr(755,root,root) %{_bindir}/qemu-system-ppc64
946 %attr(755,root,root) %{_bindir}/qemu-system-ppcemb
949 %defattr(644,root,root,755)
950 %attr(755,root,root) %{_bindir}/qemu-system-s390x
953 %defattr(644,root,root,755)
954 %attr(755,root,root) %{_bindir}/qemu-system-sh4
955 %attr(755,root,root) %{_bindir}/qemu-system-sh4eb
958 %defattr(644,root,root,755)
959 %attr(755,root,root) %{_bindir}/qemu-system-sparc
960 %attr(755,root,root) %{_bindir}/qemu-system-sparc64
962 %files system-unicore32
963 %defattr(644,root,root,755)
964 %attr(755,root,root) %{_bindir}/qemu-system-unicore32
967 %defattr(644,root,root,755)
968 %attr(755,root,root) %{_bindir}/qemu-system-i386
969 %attr(755,root,root) %{_bindir}/qemu-system-x86_64
970 %ifarch %{ix86} %{x8664}
971 %config(noreplace) %verify(not md5 mtime size) /etc/modules-load.d/kvm.conf
972 %config(noreplace) %verify(not md5 mtime size) /etc/udev/rules.d/80-kvm.rules
973 %attr(755,root,root) %{_bindir}/kvm_stat
975 %{_datadir}/%{name}/bios.bin
976 %{_datadir}/%{name}/acpi-dsdt.aml
977 %{_datadir}/%{name}/q35-acpi-dsdt.aml
980 %defattr(644,root,root,755)
981 %attr(755,root,root) %{_bindir}/qemu-system-xtensa
982 %attr(755,root,root) %{_bindir}/qemu-system-xtensaeb
985 %defattr(644,root,root,755)
986 %config(noreplace) %verify(not md5 mtime size) /etc/udev/rules.d/99-qemu-guest-agent.rules
987 %{systemdunitdir}/qemu-guest-agent.service
988 %attr(755,root,root) %{_bindir}/qemu-ga