]> git.pld-linux.org Git - packages/qemu.git/blame - qemu.spec
- release 2
[packages/qemu.git] / qemu.spec
CommitLineData
6aef4654 1#
0b920c52 2# TODO:
98a1a188 3# - update patches
0b920c52 4#
6aef4654 5# Conditional build:
161ffd93 6%bcond_with cflags_passing # with passing rpmcflags to Makefiles
b4d7fbfb 7%bcond_with dosguest # add special patch when use with DOS as guest os
a6d3659e 8%bcond_with nosdlgui # do not use SDL gui (use X11 instead)
007877cb 9
cd19124e 10Summary: QEMU CPU Emulator
eec0535a 11Summary(pl.UTF-8): QEMU - emulator procesora
7b81d160 12Name: qemu
13Version: 0.12.2
f2e75702 14Release: 2
5a2da1d0
JB
15License: GPL
16Group: Applications/Emulators
c4b12b8b 17# Source0Download: http://fabrice.bellard.free.fr/qemu/download.html
7b81d160 18Source0: http://download.savannah.gnu.org/releases/qemu/%{name}-%{version}.tar.gz
19# Source0-md5: 1d7c2d95acb6d0789de86508c608e26d
20Patch0: %{name}-ncurses.patch
21Patch6: %{name}-nosdlgui.patch
81a493f2 22# Proof of concept, for reference, do not remove
7b81d160 23Patch8: %{name}-kde_virtual_workspaces_hack.patch
24#Patch12: %{name}-0.7.2-dyngen-check-stack-clobbers.patch
25Patch13: %{name}-dosguest.patch
26Patch14: %{name}-ppc_old_binutils.patch
27Patch15: %{name}-isa-bios-ram.patch
c9c22e78
ER
28# below one fixes problems with passing ram size to bios/bootloader
29# which affects coreboot/linuxbios
7b81d160 30Patch16: %{name}-piix-ram-size.patch
98a1a188 31URL: http://www.nongnu.org/qemu/
867764ba 32BuildRequires: SDL-devel >= 1.2.1
b0b3ca8d 33BuildRequires: alsa-lib-devel
b99b1652
AM
34BuildRequires: bluez-libs-devel
35BuildRequires: gnutls-devel
98a1a188 36BuildRequires: ncurses-devel
995bac8b 37BuildRequires: perl-Encode
2fb8ea02 38BuildRequires: perl-tools-pod
ba84a935 39BuildRequires: pkgconfig
8bb1261c 40BuildRequires: sed >= 4.0
a1146336 41BuildRequires: texi2html
cad677a4 42BuildRequires: which
ba84a935 43BuildRequires: xorg-lib-libX11-devel
8bb1261c 44Requires: SDL >= 1.2.1
2ef13cb9 45# sparc is currently unsupported (missing cpu_get_real_ticks() impl in vl.c)
007877cb 46ExclusiveArch: %{ix86} %{x8664} %{?with_userspace:ppc}
cd19124e 47BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
48
98a1a188
AM
49# some PPC/SPARC boot image in ELF format
50%define _noautostrip .*%{_datadir}/qemu/openbios-.*
a154aede 51
cd19124e 52%description
53QEMU is a FAST! processor emulator. By using dynamic translation it
54achieves a reasonnable speed while being easy to port on new host
55CPUs. QEMU has two operating modes:
56
57- User mode emulation. In this mode, QEMU can launch Linux processes
58 compiled for one CPU on another CPU. Linux system calls are converted
59 because of endianness and 32/64 bit mismatches. Wine (Windows
60 emulation) and DOSEMU (DOS emulation) are the main targets for QEMU.
61
62- Full system emulation. In this mode, QEMU emulates a full system,
8799423b
ER
63 including a processor and various peripherials. It can also be used to
64 provide virtual hosting of several virtual PC on a single server.
cd19124e 65
27b30e9c
JR
66%description -l pl.UTF-8
67QEMU to szybki(!) emulator procesora. Poprzez użycie dynamicznego
68tłumaczenia osiąga rozsądną szybkość i jest łatwy do przeportowania,
69aby działał na kolejnych procesorach. QEMU ma dwa tryby pracy:
5a2da1d0 70
27b30e9c 71- Emulacja trybu użytkownika. W tym trybie QEMU może uruchamiać
5a2da1d0 72 procesy linuksowe skompilowane dla jednego procesora na innym
27b30e9c
JR
73 procesorze. Linuksowe wywołania systemowe są tłumaczone ze względu na
74 niezgodność kolejności bajtów w słowie i 32/64-bitowego rozmiaru
75 słowa. Wine (emulacja Windows) i DOSEMU (emulacja DOS-a) to główne
5a2da1d0
JB
76 cele QEMU.
77
27b30e9c
JR
78- Pełna emulacja systemu. W tym trybie QEMU emuluje cały system,
79 włączając w to procesor i różne urządzenia peryferyjne. Może być także
80 używane do wirtualnego hostowania kilku wirtualnych pecetów na
8799423b 81 pojedynczym serwerze.
5a2da1d0 82
cd19124e 83%prep
c21a255a 84%setup -q
a9a35ffb 85%patch0 -p1
8d073aaa 86%{?with_nosdlgui:%patch6 -p1}
7b81d160 87#patch8 -p1
0b920c52
88
89%{__sed} -i -e 's/sdl_static=yes/sdl_static=no/' configure
8bb1261c 90%{__sed} -i 's/.*MAKE) -C kqemu$//' Makefile
cd19124e 91
c3048014 92# cannot use optflags on x86 - they cause "no register to spill" errors
0b920c52
93%if %{with cflags_passing}
94%{__sed} -i -e 's/-Wall -O2 -g/-Wall %{rpmcflags}/' Makefile Makefile.target
57d8430f
KK
95%else
96%{__sed} -i 's/-Wall -O2 -g/-Wall -O2/' Makefile Makefile.target
0b920c52 97%endif
c3048014 98
80bac37e 99%build
c3048014 100# --extra-cflags don't work (overridden by CFLAGS in Makefile*)
0b920c52 101# they can be passed if the cflags_passing bcond is used
8bd2aee2 102./configure \
103 --prefix=%{_prefix} \
98a1a188
AM
104 --cc="%{__cc}" \
105 --host-cc="%{__cc}" \
c33439fc 106 --make="%{__make}" \
b99b1652 107 --enable-mixemu \
98a1a188 108 --audio-drv-list="alsa" \
7b81d160 109 --interp-prefix=%{_libdir}/%{name}
8bb1261c 110%{__make}
cd19124e 111
112%install
113rm -rf $RPM_BUILD_ROOT
5a2da1d0 114
cd19124e 115%{__make} install \
116 DESTDIR=$RPM_BUILD_ROOT
ac6e5743 117
a91fea76 118install -d $RPM_BUILD_ROOT%{_sysconfdir}
119cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/qemu-ifup
ac6e5743 120#!/bin/sh
a91fea76 121
ac6e5743 122EOF
a62a2d89 123
c33439fc
ER
124# already packaged
125rm -rf $RPM_BUILD_ROOT%{_docdir}/qemu/qemu-{doc,tech}.html
126
cd19124e 127%clean
128rm -rf $RPM_BUILD_ROOT
129
130%files
131%defattr(644,root,root,755)
867764ba 132%doc README qemu-doc.html qemu-tech.html
a91fea76 133%attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/qemu-ifup
003e2129 134%attr(755,root,root) %{_bindir}/*
135%{_datadir}/qemu
cd19124e 136%{_mandir}/man1/qemu.1*
867764ba 137%{_mandir}/man1/qemu-img.1*
98a1a188 138%{_mandir}/man8/qemu-nbd.8*
This page took 0.05251 seconds and 4 git commands to generate.