!85 Update to StratoVirt 2.2.0
From: @yezengruan Reviewed-by: @kevinzhu1 Signed-off-by: @kevinzhu1
This commit is contained in:
commit
abe66b9172
Binary file not shown.
@ -6,16 +6,18 @@
|
||||
|
||||
Name: stratovirt
|
||||
Version: 2.2.0
|
||||
Release: 10
|
||||
Release: 11
|
||||
Summary: StratoVirt is an opensource VMM(Virtual Machine Manager) which aims to perform next generation virtualization.
|
||||
|
||||
License: MulanPSL-2.0
|
||||
URL: https://gitee.com/openeuler/StratoVirt
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
URL: https://gitee.com/openeuler/stratovirt
|
||||
Source0: https://gitee.com/openeuler/stratovirt/releases/download/v%{version}/%{name}-%{version}.tar.gz
|
||||
|
||||
|
||||
ExclusiveArch: x86_64 aarch64
|
||||
|
||||
Patch001: util-byte_code-Fix-UT-failure-under-high-version-rus.patch
|
||||
|
||||
Requires: pixman
|
||||
Requires: pixman-devel
|
||||
|
||||
@ -90,7 +92,7 @@ sed -i 's/rustflags = \[/&"-Clink-arg=-lpixman-1", /' ./.cargo/config
|
||||
%{_cargo} build --release -Z avoid-dev-deps --target=%{rust_gnu_target} --all-features
|
||||
|
||||
%check
|
||||
RUST_BACKTRACE=1 cargo test --all -- --nocapture --test-threads=1
|
||||
RUST_BACKTRACE=1 cargo test --workspace --exclude mod_test -- --nocapture --test-threads=1
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
@ -104,6 +106,9 @@ install -D -m555 ./target/%{rust_musl_target}/release/stratovirt %{buildroot}%{_
|
||||
install -D -m555 ./target/%{rust_musl_target}/release/vhost_user_fs %{buildroot}%{_libdir}/stratovirt/static
|
||||
|
||||
%changelog
|
||||
* Mon Mar 06 2023 zhukeqian <zhukeqian1@huawei.com> - 2.2.0-11
|
||||
- Update to StratoVirt 2.2.0
|
||||
|
||||
* Thu Dec 01 2022 yezengruan <yezengruan@huawei.com> - 2.2.0-10
|
||||
- Update to StratoVirt 2.2.0-rc6
|
||||
|
||||
|
||||
39
util-byte_code-Fix-UT-failure-under-high-version-rus.patch
Normal file
39
util-byte_code-Fix-UT-failure-under-high-version-rus.patch
Normal file
@ -0,0 +1,39 @@
|
||||
From 8604dc722c504d943791a2b4039308bb05cbb728 Mon Sep 17 00:00:00 2001
|
||||
From: Keqian Zhu <zhukeqian1@huawei.com>
|
||||
Date: Wed, 1 Mar 2023 09:17:04 +0800
|
||||
Subject: [PATCH] util/byte_code: Fix UT failure under high version rustc
|
||||
|
||||
The memory layout of high version rustc is different, use
|
||||
repr C to fix the layout.
|
||||
|
||||
Signed-off-by: Keqian Zhu <zhukeqian1@huawei.com>
|
||||
---
|
||||
util/src/byte_code.rs | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/util/src/byte_code.rs b/util/src/byte_code.rs
|
||||
index cd460459..0bdfe086 100644
|
||||
--- a/util/src/byte_code.rs
|
||||
+++ b/util/src/byte_code.rs
|
||||
@@ -75,6 +75,7 @@ impl ByteCode for i128 {}
|
||||
mod test {
|
||||
use super::*;
|
||||
|
||||
+ #[repr(C)]
|
||||
#[allow(dead_code)]
|
||||
#[derive(Copy, Clone, Default)]
|
||||
struct TestData {
|
||||
@@ -105,9 +106,9 @@ mod test {
|
||||
};
|
||||
|
||||
let mut target = Vec::new();
|
||||
+ target.extend_from_slice(b"bytecode");
|
||||
target.extend_from_slice(&[0x79, 0x56, 0x34, 0x12]);
|
||||
target.extend_from_slice(&[0_u8; 4]);
|
||||
- target.extend_from_slice(b"bytecode");
|
||||
assert_eq!(data.as_bytes().to_vec(), target);
|
||||
|
||||
// Convert failed because byte stream's length is not equal to size of struct.
|
||||
--
|
||||
2.33.0
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user