[packages/rpm] - fix _host/_build/_target for x32

baggins baggins at pld-linux.org
Sat May 30 14:38:35 CEST 2026


commit 675e8040c9561fa013e9f0d8cb4f0e9f3ca281a2
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Sat May 30 14:38:16 2026 +0200

    - fix _host/_build/_target for x32

 rpm.spec | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)
---
diff --git a/rpm.spec b/rpm.spec
index af10ff4..c7da316 100644
--- a/rpm.spec
+++ b/rpm.spec
@@ -675,10 +675,16 @@ ln -s ../rpmpgp_legacy-1.1 rpmio/rpmpgp_legacy
 %endif
 
 # rpm checks for CPU type at runtime, but it looks better
+%ifarch x32
+_HOST="x86_64-%{_target_vendor}-%{_target_os}-gnux32"
+%else
+_HOST="%{_target_cpu}-%{_target_vendor}-%{_target_os}"
+%endif
 %{__sed} -i \
-	-e 's|@host@|%{_target_cpu}-%{_target_vendor}-%{_target_os}|' \
-	-e 's|@host_cpu@|%{_target_cpu}|' \
-	-e 's|@host_os@|%{_target_os}|' \
+	-e "s|@host@|$_HOST|" \
+	-e "s|@host_cpu@|%{_target_cpu}|" \
+	-e "s|@host_vendor@|%{_target_vendor}|" \
+	-e "s|@host_os@|%{_target_os}|" \
 	macros.in
 
 # Use fully qualified names for CC and CXX
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/rpm.git/commitdiff/675e8040c9561fa013e9f0d8cb4f0e9f3ca281a2



More information about the pld-cvs-commit mailing list