]> git.pld-linux.org Git - packages/qemu.git/commitdiff
- fixed build with PREEMPT_RT
authorsparky <sparky@pld-linux.org>
Wed, 22 Feb 2006 23:37:43 +0000 (23:37 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
- no kqemu on ppc

Changed files:
    qemu.spec -> 1.47

qemu.spec

index c5d224cdbf2e14f4da3b5525df424ff70f6f1057..c7d946c52e9357209f34f1481ee440e61aa89dad 100644 (file)
--- a/qemu.spec
+++ b/qemu.spec
@@ -52,7 +52,7 @@ BuildRequires:        kernel-module-build >= 2.6.7
 BuildRequires: rpmbuild(macros) >= 1.217
 BuildRequires: sed >= 4.0
 Requires:      SDL >= 1.2.1
-ExclusiveArch: %{ix86} %{x8664} ppc
+ExclusiveArch: %{ix86} %{x8664} %{!?with_kqemu:ppc}
 # sparc is currently unsupported (missing cpu_get_real_ticks() impl in vl.c)
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -160,6 +160,7 @@ kqemu - modu
 %build
 %if %{with kernel}
 cd kqemu
+mv -f kqemu-linux.c{,.orig}
 for cfg in %{?with_dist_kernel:%{?with_smp:smp} up}%{!?with_dist_kernel:nondist}; do
        if [ ! -r "%{_kernelsrcdir}/config-$cfg" ]; then
                exit 1
@@ -175,6 +176,13 @@ for cfg in %{?with_dist_kernel:%{?with_smp:smp} up}%{!?with_dist_kernel:nondist}
        touch o/include/config/MARKER
        ln -sf %{_kernelsrcdir}/scripts o/scripts
 %endif
+       if grep -q "^CONFIG_PREEMPT_RT=y$" o/.config; then
+               sed 's/SPIN_LOCK_UNLOCKED/SPIN_LOCK_UNLOCKED(kqemu_lock)/' \
+                       kqemu-linux.c.orig > kqemu-linux.c
+       else
+               cat kqemu-linux.c.orig > kqemu-linux.c
+       fi
+
        %{__make} -C %{_kernelsrcdir} modules \
                CC="%{__cc}" CPP="%{__cpp}" \
                M=$PWD O=$PWD/o \
This page took 0.273478 seconds and 4 git commands to generate.