stratovirt/stratovirt.spec
Jie Yang 2d9d03c21a Update version to 2.0.0-6
Signed-off-by: Jie Yang <yangjieyj.yang@huawei.com>
(cherry picked from commit 6158eab66897bf7fb11ce7ae8c3b568f8de0e2dd)
2021-08-30 21:19:11 +08:00

151 lines
5.5 KiB
RPMSpec

#needsrootforbuild
%global __cargo_skip_build 0
%global _debugsource_packages 1
%global _debuginfo_subpackages 1
%define _unpackaged_files_terminate_build 0
Name: stratovirt
Version: 2.0.0
Release: 6
Summary: StratoVirt is an opensource VMM(Virtual Machine Manager) which aims to perform next generation virtualization.
License: Mulan PSL v2
URL: https://gitee.com/openeuler/StratoVirt
Source0: %{name}-%{version}.tar.gz
Patch001: fix-spelling-errors-in-project.patch
Patch002: migration-fix-an-error-during-migration-interface-on.patch
Patch003: migration-fix-an-errors-during-the-PL011-device-stat.patch
Patch004: machine-standard_vm-fix-inappropriate-file-open-perm.patch
Patch005: kernel_config-update-kernel-config-5.10-on-aarch64-p.patch
Patch006: syscall-add-syscall-newfstatat-in-x86_64-unknown-lin.patch
Patch007: vfio-fix-the-problem-of-dma-mapping-failed.patch
Patch008: virtio-fix-dev_id-initialization-for-virtio-pci-and-.patch
Patch009: docs-fix-some-statement.patch
Patch010: machine_manager-add-autodeflate-for-balloon.patch
Patch011: migration-add-dev_id-into-VirtioPciState-when-save-a.patch
Patch012: machine-fix-more-than-one-pcie-root-ports-with-same-.patch
Patch013: migration-move-function-transport_reset-to-save-stat.patch
Patch014: vfio-adding-ram-device-region-to-vfio-bar-region.patch
Patch015: machine_manager-move-argument-serial-from-drive-to-d.patch
Patch016: machine_manager-add-multifunction-for-devices.patch
Patch017: machine-add-init_multifunction-function-to-init-mult.patch
Patch018: machine-add-realization-for-multifunction.patch
ExclusiveArch: x86_64 aarch64
%ifarch aarch64
Requires: dtc
BuildRequires: dtc-devel
%endif
BuildRequires: rust
BuildRequires: cargo
BuildRequires: rust-packaging
BuildRequires: gcc
%description
Based on Rust programming language, StratoVirt is lightweight, efficient and safe. StratoVirt reduces memory resource consumption and improves VM startup speed while retains isolation capability and security capability of traditional virtualization. StratoVirt works with iSulad and Kata container, and can be integrated in Kubernetes ecosystem perfectly. The current version can be applied to microservices or serverless scenarios. StratoVirt reserves interface and design for importing more features, even standard virtualization.
Summary: %{summary}
%files -n stratovirt
%{_bindir}/stratovirt
%{_bindir}/ozone
%prep
%autosetup -p1
%cargo_prep
%cargo_generate_buildrequires
%build
%ifarch aarch64
sed -i '/\[build\]/a target="aarch64-unknown-linux-musl"' ./.cargo/config
%endif
%ifarch x86_64
sed -i '/\[build\]/a target="x86_64-unknown-linux-musl"' ./.cargo/config
%endif
sed -i '/\[source.crates-io\]/{n;d}' ./.cargo/config
sed -i '/\[source.local-registry\]/{n;d}' ./.cargo/config
sed -i '/\[source.local-registry\]/a directory = "vendor"' ./.cargo/config
%ifarch aarch64
sed -i 's/rustflags = \[/rustflags = \["-Clink-arg=-lgcc", /g' ./.cargo/config
%endif
%cargo_build -a
%install
%cargo_install -a
chmod 555 ${RPM_BUILD_ROOT}/usr/bin/stratovirt
chmod 555 ${RPM_BUILD_ROOT}/usr/bin/ozone
%changelog
* Mon Aug 30 2021 Jie Yang <yangjieyj.yang@huawei.com> - 2.0.0-6
- docs: fix some statement
- machine_manager: add autodeflate for balloon
- migration: add dev_id into VirtioPciState when save and restore device state
- machine: fix more than one pcie-root-ports with same id
- migration: move function "transport_reset" to save state stage for vhost vsock device
- vfio: adding ram device region to vfio bar region
- machine_manager: move argument "serial" from -drive to -device virtio-blk-pci/device
- machine_manager: add multifunction for devices
- machine: add init_multifunction function to init multifunction
- machine: add realization for multifunction
* Thu Aug 24 2021 Ming Yang <yangming73@huawei.com> - 2.0.0-5
- add ozone in rpm package.
* Fri Aug 20 2021 Jie Yang <yangjieyj.yang@huawei.com> - 2.0.0-3
- virtio: fix dev_id initialization for virtio-pci and vfio device on aarch64 platform
- vfio: fix the problem of dma mapping failed
- syscall: add syscall "newfstatat" in x86_64-unknown-linux-gnu target
- kernel_config: update kernel config 5.10 on aarch64 platform
- machine/standard_vm: fix inappropriate file open permissions
- migration: fix an errors during the PL011 device state restore
- migration: fix an error during migration interface on aarch64
- fix spelling errors in project
* Wed Aug 18 2021 Xinle.Guo <guoxinle1@huawei.com> - 2.0.0-2
- switch stratovirt permission from 550 to 555
* Fri Aug 13 2021 Jie Yang <yangjieyj.yang@huawei.com> - 2.0.0-1
- add ACPI support
- add PCIe/PCI support
- add support for UEFI boot
- add virtio pci support
- provide standard type machine on x86_64 and aarch64
- add hot boot feature
- add VFIO support
- add initial support for being managed by libvirt
* Tue Jul 27 2021 XuFei <xufei30@huawei.com> - 0.3.0-5
- add fdt patches for musl compilation
* Wed Jun 16 2021 XuFei <xufei30@huawei.com> - 0.3.0-4
- add gcc dependency package
* Sun May 28 2021 XuFei <xufei30@huawei.com> - 0.3.0-3
- modify docs
- modify testcases
- clear clippy warnings for updating rust 1.51.0
* Sun Apr 25 2021 LiangZhang <zhangliang5@huawei.com> - 0.3.0-2
- add hydropper to package
* Sun Apr 25 2021 LiangZhang <zhangliang5@huawei.com> - 0.3.0-1
- update package to 0.3.0
* Wed Jan 13 2021 LiangZhang <zhangliang5@huawei.com> - 0.1.0-3
- update package to latest source
* Wed Jan 13 2021 XuFei <xufei30@huawei.com> - 0.1.0-2
- modify summary and description for spec
* Thu Jul 16 2020 Xu Yandong <xuyandong2@huawei.com> - 0.1.0-1
- initial package