From c2dfeb4e11bcf61b781836889c66d6697444313c Mon Sep 17 00:00:00 2001 From: U2FsdGVkX1 Date: Fri, 15 Dec 2023 12:37:26 +0800 Subject: [PATCH] Add riscv64 support --- add-riscv64-support-for-isomd5sum.patch | 14 ++++++++++++++ isomd5sum.spec | 15 +++++++++++++-- 2 files changed, 27 insertions(+), 2 deletions(-) create mode 100644 add-riscv64-support-for-isomd5sum.patch diff --git a/add-riscv64-support-for-isomd5sum.patch b/add-riscv64-support-for-isomd5sum.patch new file mode 100644 index 0000000..1d36946 --- /dev/null +++ b/add-riscv64-support-for-isomd5sum.patch @@ -0,0 +1,14 @@ +diff --git a/Makefile b/Makefile +--- a/Makefile ++++ b/Makefile +@@ -4,7 +4,7 @@ PYTHONINCLUDE := $(shell $(PYTHON)-config --includes) + + VERSION=1.2.3 + +-ifneq (,$(filter sparc64 ppc64 ppc64le x86_64 s390x aarch64,$(shell uname -m))) ++ifneq (,$(filter sparc64 ppc64 ppc64le x86_64 s390x aarch64 riscv64,$(shell uname -m))) + LIBDIR = lib64 + else + LIBDIR = lib +-- +2.40.1 \ No newline at end of file diff --git a/isomd5sum.spec b/isomd5sum.spec index 1586446..c136754 100644 --- a/isomd5sum.spec +++ b/isomd5sum.spec @@ -1,4 +1,4 @@ -%define anolis_release 5 +%define anolis_release 6 Summary: Utilities for working with md5sum implanted in ISO images Name: isomd5sum Version: 1.2.3 @@ -12,7 +12,9 @@ BuildRequires: gcc BuildRequires: popt-devel BuildRequires: python3-devel BuildRequires: make + Patch001: add-loongarch64-support-for-isomd5sum.patch +Patch002: add-riscv64-support-for-isomd5sum.patch %description The isomd5sum package contains utilities for implanting and verifying @@ -36,8 +38,14 @@ an md5sum implanted into an ISO9660 image. %prep -%autosetup -p1 +%autosetup -N +%ifarch loongarch64 +%patch -P1 -p1 +%endif +%ifarch riscv64 +%patch -P2 -p1 +%endif %build CFLAGS="$RPM_OPT_FLAGS -Wno-strict-aliasing"; export CFLAGS @@ -64,6 +72,9 @@ PYTHON=%{__python3} make DESTDIR=$RPM_BUILD_ROOT install-bin install-devel insta %{python3_sitearch}/pyisomd5sum.so %changelog +* Fri Nov 3 2023 Guoguo - 1.2.3-6 +- add riscv64 support for isomd5sum + * Mon Aug 28 2023 Wenlong Zhang - 1.2.3-5 - add loongarch64 support for isomd5sum -- Gitee