From c0ecbcf6c35bfc05553aab297024a1e2e7b93355 Mon Sep 17 00:00:00 2001 From: Wenhua Huang Date: Wed, 24 Sep 2025 19:14:34 +0800 Subject: [PATCH] Fix compile failure on loongarch --- clamav.spec | 17 ++++++++++++++++- vendor.tar.gz | 3 +++ 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 vendor.tar.gz diff --git a/clamav.spec b/clamav.spec index 306a7f8..1c3bdc9 100644 --- a/clamav.spec +++ b/clamav.spec @@ -4,7 +4,7 @@ Name: clamav Summary: End-user tools for the Clam Antivirus scanner Version: 1.0.9 -Release: 2 +Release: 3 License: GPL-2.0-only URL: https://www.clamav.net/ @@ -24,6 +24,13 @@ Source13: clamd.scan.upstart Source14: clamd@scan.service Source15: clamd@.service Source16: clamav-types.h +# tar zxvf clamav-1.0.9.tar.gz +# cd clamav-1.0.9/ +# cargo update -p tempfile +# cd libclamav_rust/.cargo +# rm -fr vendor; cargo vendor +# cd ../..; tar zcvf vendor.tar.gz Cargo.lock libclamav_rust/.cargo/vendor +Source17: vendor.tar.gz Patch0001: clamav-rustflags.patch Patch0002: clamav-default_confs.patch @@ -183,6 +190,11 @@ The clamav-milter package contains files which are needed to run the clamav-milt %prep %autosetup -n %{name}-%{version} -p1 +%ifarch loongarch64 +rm -fr $RPM_BUILD_DIR/%{name}-%{version}/libclamav_rust/.cargo/vendor/ +tar -zxf %{SOURCE17} -C $RPM_BUILD_DIR/%{name}-%{version} +%endif + install -d libclamunrar{,_iface} touch libclamunrar/{Makefile.in,all,install} @@ -392,6 +404,9 @@ exit 0 %changelog +* Wed Sep 24 2025 huangwenhua - 1.0.9-3 +- Fix compile failure on loongarch by updating vendor + * Thu Jun 26 2025 yaoxin <1024769339@qq.com> - 1.0.9-2 - Fix clamav downgrade failure diff --git a/vendor.tar.gz b/vendor.tar.gz new file mode 100644 index 0000000..ea16636 --- /dev/null +++ b/vendor.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:63e302cbbbd09ed292181a586f368a8b60b1ab86ae440fd4d3183ef952025375 +size 33789533 -- Gitee