From 953f700eca6e251f75108b9407f9197d55cb2010 Mon Sep 17 00:00:00 2001 From: ZhouZhifa Date: Thu, 20 Jul 2023 07:00:26 +0000 Subject: [PATCH] mips: Fix building error: plt.c:241:7: error: 'struct ltelf' has no member named 'relplt_count' Signed-off-by: ZhouZhifa --- ltrace.spec | 6 +++++- ...uct-ltelf-has-no-member-named-relplt_count.patch | 13 +++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 mips-fix-build-error-struct-ltelf-has-no-member-named-relplt_count.patch diff --git a/ltrace.spec b/ltrace.spec index 452c868..8967fd1 100644 --- a/ltrace.spec +++ b/ltrace.spec @@ -1,6 +1,6 @@ name: ltrace Version: 0.7.91 -Release: 33 +Release: 34 Summary: Trace the Library and System Calls a Program Makes License: GPLv2+ @@ -34,6 +34,7 @@ Patch9004: Initialize-nrhs-to-avoid-gcc-warning.patch # patch for arches Patch8000: ltrace-0.7.91-add-support-for-loongarch.patch Patch8001: ltrace-0.7.91-add-initial-riscv64-support.patch +Patch8002: mips-fix-build-error-struct-ltelf-has-no-member-named-relplt_count.patch BuildRequires: elfutils-devel dejagnu libselinux-devel autoconf automake libtool @@ -79,6 +80,9 @@ autoreconf -i %{_mandir}/man5/ltrace.conf.5* %changelog +* Thu Jul 20 2023 ZhouZhifa - 0.7.91-34 +- Fix mips building error: plt.c:241:7: error: 'struct ltelf' has no member named 'relplt_count' + * Fri Jul 07 2023 laokz - 0.7.91-33 - Backport riscv64 patch diff --git a/mips-fix-build-error-struct-ltelf-has-no-member-named-relplt_count.patch b/mips-fix-build-error-struct-ltelf-has-no-member-named-relplt_count.patch new file mode 100644 index 0000000..051a547 --- /dev/null +++ b/mips-fix-build-error-struct-ltelf-has-no-member-named-relplt_count.patch @@ -0,0 +1,13 @@ +diff -Naur ltrace-0.7.91/sysdeps/linux-gnu/mips/plt.c 2_ltrace-0.7.91/sysdeps/linux-gnu/mips/plt.c +--- ltrace-0.7.91/sysdeps/linux-gnu/mips/plt.c 2013-11-05 01:21:10.000000000 +0000 ++++ 2_ltrace-0.7.91/sysdeps/linux-gnu/mips/plt.c 2023-07-20 06:18:31.271902535 +0000 +@@ -236,9 +236,6 @@ + } + } + +- /* Tell the generic code how many dynamic trace:able symbols +- * we've got. */ +- lte->relplt_count = lte->dynsym_count - lte->arch.mips_gotsym; + return 0; + } + -- Gitee