From 09cbffaa0b05bd6aaa6c545e7cfaf3741dc2c463 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20R=C4=99korajski?= Date: Tue, 27 Oct 2020 22:04:15 +0100 Subject: [PATCH] - make sure to pick the right color for x32 --- x32.patch | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/x32.patch b/x32.patch index 5be418e..2afb1fd 100644 --- a/x32.patch +++ b/x32.patch @@ -22,6 +22,18 @@ diff -ur rpm-4.15.1.orig/build/rpmfc.c rpm-4.15.1/build/rpmfc.c if (fcolor & RPMFC_INCLUDE) break; } +@@ -1152,7 +1152,10 @@ + color = RPMFC_ELF64; + break; + case ELFCLASS32: +- color = RPMFC_ELF32; ++ if (ehdr.e_machine == EM_X86_64) ++ color = RPMFC_ELFX32; ++ else ++ color = RPMFC_ELF32; + break; + } + elf_end(elf); diff -ur rpm-4.15.1.orig/build/rpmfc.h rpm-4.15.1/build/rpmfc.h --- rpm-4.15.1.orig/build/rpmfc.h 2019-06-26 16:17:31.397985717 +0200 +++ rpm-4.15.1/build/rpmfc.h 2019-12-29 13:45:05.936980833 +0100 -- 2.43.0