kata_integration: add kata-mirco-kernel spec file
Signed-off-by: jikui <jikui2@huawei.com>
This commit is contained in:
parent
944b8726ed
commit
c6eb20d05e
@ -1,6 +1,6 @@
|
|||||||
%global debug_package %{nil}
|
%global debug_package %{nil}
|
||||||
%define VERSION v1.0.0
|
%define VERSION v1.0.0
|
||||||
%define RELEASE 5
|
%define RELEASE 6
|
||||||
|
|
||||||
Name: kata-integration
|
Name: kata-integration
|
||||||
Version: %{VERSION}
|
Version: %{VERSION}
|
||||||
@ -28,6 +28,12 @@ This is a usefult tool for building Kata Container components.
|
|||||||
%doc
|
%doc
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Aug 24 2021 jikui<jikui2@huawei.com> - 1.0.0-6
|
||||||
|
- Type:enhancement
|
||||||
|
- ID:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:add kata-mirco-kernel spec file
|
||||||
|
|
||||||
* Wed Aug 25 2021 Wei Gao<gaowei66@huawei.com> - 1.0.0-5
|
* Wed Aug 25 2021 Wei Gao<gaowei66@huawei.com> - 1.0.0-5
|
||||||
- Type:bugfix
|
- Type:bugfix
|
||||||
- ID:NA
|
- ID:NA
|
||||||
|
|||||||
65
kata-micro-kernel.spec
Normal file
65
kata-micro-kernel.spec
Normal file
@ -0,0 +1,65 @@
|
|||||||
|
%global debug_package %{nil}
|
||||||
|
|
||||||
|
%define VERSION 5.10.0
|
||||||
|
%define RELEASE 1
|
||||||
|
|
||||||
|
Name: kata-micro-kernel
|
||||||
|
Version: %{VERSION}
|
||||||
|
Release: %{RELEASE}
|
||||||
|
Summary: Micro kernel for kata-containers
|
||||||
|
License: GPLv2
|
||||||
|
URL: http://www.kernel.org/
|
||||||
|
Source0: kernel.tar.gz
|
||||||
|
Source1: kata_integration-v1.0.0.tar.gz
|
||||||
|
|
||||||
|
BuildRoot: %_topdir/BUILDROOT
|
||||||
|
BuildRequires: automake gcc bc glibc-devel glibc-static glib2-devel glib2
|
||||||
|
BuildRequires: patch elfutils-libelf-devel bison flex
|
||||||
|
|
||||||
|
%description
|
||||||
|
This is a micro kernel for kata-containers.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -T -c -a 0 -n kernel
|
||||||
|
%setup -T -c -a 1 -n kata_integration
|
||||||
|
|
||||||
|
# extract the kata_integration.tar.gz file
|
||||||
|
cd %{_builddir}/kata_integration
|
||||||
|
# apply kata_integration patches
|
||||||
|
sh apply-patches
|
||||||
|
|
||||||
|
# build kernel
|
||||||
|
cd %{_builddir}/kernel
|
||||||
|
mv kernel linux
|
||||||
|
cd %{_builddir}/kernel/linux/
|
||||||
|
%ifarch %{ix86} x86_64
|
||||||
|
cp %{_builddir}/kata_integration/hack/config-kata-x86_64 ./.config
|
||||||
|
%else
|
||||||
|
cp %{_builddir}/kata_integration/hack/config-kata-arm64 ./.config
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%build
|
||||||
|
cd %{_builddir}/kernel/linux/
|
||||||
|
make %{?_smp_mflags}
|
||||||
|
|
||||||
|
%install
|
||||||
|
mkdir -p -m 755 %{buildroot}/var/lib/kata
|
||||||
|
%ifarch %{ix86} x86_64
|
||||||
|
install -p -m 640 -D %{_builddir}/kernel/linux/arch/x86_64/boot/bzImage %{buildroot}/var/lib/kata/kernel
|
||||||
|
%else
|
||||||
|
install -p -m 640 -D %{_builddir}/kernel/linux/arch/arm64/boot/Image %{buildroot}/var/lib/kata/kernel
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%clean
|
||||||
|
|
||||||
|
%files
|
||||||
|
/var/lib/kata/kernel
|
||||||
|
|
||||||
|
%doc
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Fri Aug 20 2021 jikui<jikui2@huawei.com> - 5.10.0-1
|
||||||
|
- Type:requirement
|
||||||
|
- ID:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:init kata-micro-kernel package
|
||||||
Loading…
x
Reference in New Issue
Block a user