File kvmtool.spec of Package kvmtool
#
# spec file for package kvmtool
#
# Copyright (c) 2021 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: kvmtool
Version: 0.1~20211013.39181fc
Release: 0
Summary: Linux Native KVM Tool
License: GPL-2.0-only
URL: https://git.kernel.org/cgit/linux/kernel/git/will/kvmtool.git/
Source: %{name}-%{version}.tar.xz
Patch0: nonexec-stack.patch
BuildRequires: glibc-devel-static
BuildRequires: libaio-devel
BuildRequires: pkgconfig
BuildRequires: pkgconfig(zlib)
%if 0%{?suse_version} <= 1500
BuildRequires: gcc11
%endif
# Excluded arches that are known to fail to build (2016-08-01)
ExclusiveArch: %{ix86} x86_64
%description
kvmtool is a lightweight tool for hosting KVM guests. As a pure virtualization
tool it only supports guests using the same architecture, though it supports
running 32-bit guests on those 64-bit architectures that allow this. It also
is not ready for use in production environments and not actively maintained any
more.
%prep
%autosetup -p1
%build
CC=gcc
test -x "$(type -p gcc)" && CC="`readlink -f $_`"
test -x "$(type -p gcc-10)" && CC="`readlink -f $_`"
test -x "$(type -p gcc-11)" && CC="`readlink -f $_`"
%make_build prefix=%{_prefix} "CC=${CC}" V=1
%install
%make_install prefix=%{_prefix} "CC=${CC}" V=1
%files
%{_bindir}/lkvm
%license COPYING
%doc README
%changelog