[packages/linux-kvm] Up to 3.18.0
arekm
arekm at pld-linux.org
Sun Aug 23 12:38:54 CEST 2026
commit aede8b720fe0be6245a6f52b7d8b685e47777dec
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date: Sun Aug 23 12:38:45 2026 +0200
Up to 3.18.0
fix-types.patch | 49 ------------------------------------------
linux-kvm.spec | 66 +++++++++++++++++++++++++++++++++++++++++----------------
2 files changed, 48 insertions(+), 67 deletions(-)
---
diff --git a/linux-kvm.spec b/linux-kvm.spec
index e9ec04e..3eae4b1 100644
--- a/linux-kvm.spec
+++ b/linux-kvm.spec
@@ -1,19 +1,37 @@
-# TODO: use linux tarball when kernel 3.1 is released
-%define rel 32
-%define snap 20110726
+%define rel 1
+%define snap 20260806
+%define gitcommit f67bc0bdae9433a9cfd05e65ea2c1bb6102566d9
+#
+# kvmtool has no switches for the framebuffer backends, so these bconds only
+# gate the BuildRequires - a backend found in the buildroot is used anyway.
+%bcond_with gtk3 # GTK+ 3 guest framebuffer window
+%bcond_with sdl # SDL guest framebuffer window
+%bcond_with vnc # VNC server with the guest framebuffer
+#
Summary: Native Linux KVM tool
Summary(pl.UTF-8): Natywne narzędzie KVM dla Linuksa
Name: linux-kvm
-Version: 3.1
+Version: 3.18.0
Release: 0.%{snap}.%{rel}
License: GPL v2
Group: Applications/System
-# git://github.com/penberg/linux-kvm.git
-Source0: %{name}-%{version}-%{snap}.tar.bz2
-# Source0-md5: b0b94a75d915f70ae14a089ddc7d7abb
-Patch0: fix-types.patch
+Source0: https://git.kernel.org/pub/scm/linux/kernel/git/will/kvmtool.git/snapshot/kvmtool-%{gitcommit}.tar.gz
+# Source0-md5: 48030699462c21f9da09677ad2731219
+URL: https://git.kernel.org/pub/scm/linux/kernel/git/will/kvmtool.git/
BuildRequires: binutils-devel
BuildRequires: glibc-devel(ix86)
+BuildRequires: glibc-static
+BuildRequires: libaio-devel
+BuildRequires: zlib-devel
+%if %{with gtk3}
+BuildRequires: gtk+3-devel
+%endif
+%if %{with sdl}
+BuildRequires: SDL-devel
+%endif
+%if %{with vnc}
+BuildRequires: libvncserver-devel
+%endif
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
@@ -27,28 +45,40 @@ emulation.
Celem tego narzędzia jest dostarczenie czystej, lekkiej, napisanej od
zera implementacji hosta KVM, potrafiącego uruchamiać obrazy gościa
Linuksa (tylko hobby, nie będzie duża i profesjonalna jak QEMU) bez
-zależności oD BIOS-u i z minimalną emulacją tradycyjnych urządzeń.
+zależności od BIOS-u i z minimalną emulacją tradycyjnych urządzeń.
%prep
-%setup -q -n %{name}
-%patch -P0 -p1
+%setup -q -n kvmtool-%{gitcommit}
%build
-%{__make} -C tools/kvm \
- CC="%{__cc} %{rpmcppflags} %{rpmcflags} %{rpmldflags}" \
- WERROR=0 \
+# CFLAGS must not be passed on the command line - that would drop the include
+# paths and defines the Makefile appends to it; CPPFLAGS ends up in CFLAGS.
+%{__make} \
+ CC="%{__cc}" \
+ CPPFLAGS="%{rpmcppflags} %{rpmcflags}" \
+ LDFLAGS="%{rpmldflags}" \
V=1
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_sbindir}
+install -d $RPM_BUILD_ROOT%{_mandir}/man1
-install tools/kvm/kvm $RPM_BUILD_ROOT%{_sbindir}
+%{__make} install \
+ CC="%{__cc}" \
+ CPPFLAGS="%{rpmcppflags} %{rpmcflags}" \
+ LDFLAGS="%{rpmldflags}" \
+ DESTDIR=$RPM_BUILD_ROOT \
+ prefix=%{_prefix}
+
+cp -p Documentation/kvmtool.1 $RPM_BUILD_ROOT%{_mandir}/man1
+ln -sf kvmtool.1 $RPM_BUILD_ROOT%{_mandir}/man1/lkvm.1
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
-%doc tools/kvm/Documentation/* tools/kvm/README
-%attr(755,root,root) %{_sbindir}/kvm
+%doc README Documentation/*.txt
+%attr(755,root,root) %{_bindir}/lkvm
+%{_mandir}/man1/kvmtool.1*
+%{_mandir}/man1/lkvm.1*
diff --git a/fix-types.patch b/fix-types.patch
deleted file mode 100644
index 9065e3c..0000000
--- a/fix-types.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-diff -ur linux-kvm/tools/kvm/builtin-run.c linux-kvm-bioscall/tools/kvm/builtin-run.c
---- linux-kvm/tools/kvm/builtin-run.c 2011-07-26 08:46:14.000000000 +0200
-+++ linux-kvm-bioscall/tools/kvm/builtin-run.c 2017-03-13 19:08:42.249902232 +0100
-@@ -4,6 +4,7 @@
- #include <unistd.h>
- #include <stdlib.h>
- #include <termios.h>
-+#include <sys/sysmacros.h>
- #include <sys/utsname.h>
- #include <sys/types.h>
- #include <sys/stat.h>
-diff -ur linux-kvm/tools/kvm/include/kvm/e820.h linux-kvm-bioscall/tools/kvm/include/kvm/e820.h
---- linux-kvm/tools/kvm/include/kvm/e820.h 2011-07-26 08:46:14.000000000 +0200
-+++ linux-kvm-bioscall/tools/kvm/include/kvm/e820.h 2017-03-13 19:13:40.660703177 +0100
-@@ -2,6 +2,7 @@
- #define KVM_E820_H
-
- #include <linux/types.h>
-+#include "kvm/bios.h"
-
- #define SMAP 0x534d4150 /* ASCII "SMAP" */
-
-@@ -13,6 +14,6 @@
- u32 edx;
- };
-
--void e820_query_map(struct e820_query *query);
-+bioscall void e820_query_map(struct e820_query *query);
-
- #endif /* KVM_E820_H */
-diff -ur linux-kvm/tools/kvm/include/kvm/vesa.h linux-kvm-bioscall/tools/kvm/include/kvm/vesa.h
---- linux-kvm/tools/kvm/include/kvm/vesa.h 2011-07-26 08:46:14.000000000 +0200
-+++ linux-kvm-bioscall/tools/kvm/include/kvm/vesa.h 2017-03-13 19:14:29.819084291 +0100
-@@ -2,6 +2,7 @@
- #define KVM__VESA_H
-
- #include <linux/types.h>
-+#include "kvm/bios.h"
-
- #define VESA_WIDTH 640
- #define VESA_HEIGHT 480
-@@ -14,6 +15,6 @@
- struct int10_args;
-
- struct framebuffer *vesa__init(struct kvm *self);
--void int10_handler(struct int10_args *args);
-+bioscall void int10_handler(struct int10_args *args);
-
- #endif
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/linux-kvm.git/commitdiff/aede8b720fe0be6245a6f52b7d8b685e47777dec
More information about the pld-cvs-commit
mailing list