From 7f5abfc0a5a7be1fbe8cce02ac1c21e86716bed6 Mon Sep 17 00:00:00 2001 From: Jan Palus Date: Sun, 26 Apr 2020 00:00:57 +0200 Subject: [PATCH] add support for aarch64 --- aarch64.patch | 13 +++++++++++++ rpm.spec | 10 ++++++++++ 2 files changed, 23 insertions(+) create mode 100644 aarch64.patch diff --git a/aarch64.patch b/aarch64.patch new file mode 100644 index 0000000..8013c2a --- /dev/null +++ b/aarch64.patch @@ -0,0 +1,13 @@ +--- rpm-4.16.0/installplatform.orig 2020-10-24 21:48:07.586493242 +0200 ++++ rpm-4.16.0/installplatform 2020-10-24 21:48:23.069703643 +0200 +@@ -207,6 +207,10 @@ + LIB=${LIB}x32 + fi + ++ if [ "$OS" = "linux" ] && [ "$CANONARCH" = "aarch64" ]; then ++ LIB=${LIB}64 ++ fi ++ + PPD="${DESTDIR}/${platformdir}/${ARCH}-${OS}" + [ -d $PPD ] || mkdir -p $PPD + diff --git a/rpm.spec b/rpm.spec index b938093..37fc0b2 100644 --- a/rpm.spec +++ b/rpm.spec @@ -72,6 +72,7 @@ Patch17: python-internal-build.patch Patch18: rpmversion.patch Patch19: pkgconfig.patch Patch20: uname-deps.patch +Patch21: aarch64.patch URL: https://rpm.org/ BuildRequires: db-devel >= %{db_ver} BuildRequires: autoconf >= 2.63 @@ -555,6 +556,9 @@ Dokumentacja API RPM-a oraz przewodniki w formacie HTML generowane ze %patch18 -p1 %patch19 -p1 %patch20 -p1 +%ifarch aarch64 +%patch21 -p1 +%endif install %{SOURCE15} scripts/perl.prov.in @@ -665,7 +669,10 @@ rm $RPM_BUILD_ROOT%{_rpmlibdir}/platform/ppc-linux/macros rm $RPM_BUILD_ROOT%{_rpmlibdir}/platform/ppc*series-linux/macros %endif +%ifnarch aarch64 rm $RPM_BUILD_ROOT%{_rpmlibdir}/platform/aarch64-linux/macros +%endif + rm $RPM_BUILD_ROOT%{_rpmlibdir}/platform/alpha*-linux/macros rm $RPM_BUILD_ROOT%{_rpmlibdir}/platform/arm*-linux/macros rm $RPM_BUILD_ROOT%{_rpmlibdir}/platform/ia64-linux/macros @@ -811,6 +818,9 @@ find %{_rpmlibdir} -name '*-linux' -type l | xargs rm -f %ifarch alpha %{_rpmlibdir}/platform/alpha* %endif +%ifarch aarch64 +%{_rpmlibdir}/platform/aarch64* +%endif %ifarch ia64 %{_rpmlibdir}/platform/ia64* %endif -- 2.43.0