From b86c8992ce89039e018102a601602b6714459b3c Mon Sep 17 00:00:00 2001 From: Stan Cox Date: Tue, 4 Jun 2019 21:09:10 -0400 Subject: [PATCH] Use PRIx64 to fix i386 build --- dyninst-10.1.0-result.patch | 28 ++++++++++++++++++++++++++++ dyninst.spec | 15 ++++++++++----- 2 files changed, 38 insertions(+), 5 deletions(-) create mode 100644 dyninst-10.1.0-result.patch diff --git a/dyninst-10.1.0-result.patch b/dyninst-10.1.0-result.patch new file mode 100644 index 0000000..2738cf2 --- /dev/null +++ b/dyninst-10.1.0-result.patch @@ -0,0 +1,28 @@ +--- dyninst-10.1.0/dyninst-10.1.0/instructionAPI/h/Result.h.sv 2018-11-09 11:48:08.000000000 -0500 ++++ dyninst-10.1.0/dyninst-10.1.0/instructionAPI/h/Result.h 2018-12-04 22:12:47.369579566 -0500 +@@ -449,10 +449,10 @@ + snprintf(hex, 20, "%x", val.s32val); + break; + case u64: +- snprintf(hex, 20, "%lx", val.u64val); ++ snprintf(hex, 20, "%" PRIx64, val.u64val); + break; + case s64: +- snprintf(hex, 20, "%lx", val.s64val); ++ snprintf(hex, 20, "%" PRIx64, val.s64val); + break; + case sp_float: + snprintf(hex, 20, "%f", val.floatval); +@@ -464,10 +464,10 @@ + snprintf(hex, 20, "%x", val.bitval); + break; + case u48: +- snprintf(hex, 20, "%lx", val.s48val); ++ snprintf(hex, 20, "%" PRIx64, val.s48val); + break; + case s48: +- snprintf(hex, 20, "%lx", val.s48val); ++ snprintf(hex, 20, "%" PRIx64, val.s48val); + break; + case m512: + snprintf(hex, 20, "%p", val.m512val); diff --git a/dyninst.spec b/dyninst.spec index 318e72e..5d5e5dd 100644 --- a/dyninst.spec +++ b/dyninst.spec @@ -1,7 +1,7 @@ Summary: An API for Run-time Code Generation License: LGPLv2+ Name: dyninst -Release: 1%{?dist} +Release: 2%{?dist} URL: http://www.dyninst.org Version: 10.1.0 ExclusiveArch: %{ix86} x86_64 ppc64le aarch64 @@ -9,8 +9,9 @@ ExclusiveArch: %{ix86} x86_64 ppc64le aarch64 Source0: https://github.com/dyninst/dyninst/archive/v%{version}/dyninst-%{version}.tar.gz Source1: https://github.com/dyninst/testsuite/archive/v%{version}/testsuite-%{version}.tar.gz -Patch1: testsuite-10.1.0-gettid.patch -Patch2: testsuite-10.1.0-386.patch +Patch1: dyninst-10.1.0-result.patch +Patch2: testsuite-10.1.0-gettid.patch +Patch3: testsuite-10.1.0-386.patch %global dyninst_base dyninst-%{version} %global testsuite_base testsuite-%{version} @@ -81,8 +82,9 @@ making sure that dyninst works properly. %setup -q -n %{name}-%{version} -c %setup -q -T -D -a 1 -%patch1 -p1 -bgettid -%patch2 -p1 -b.386 +%patch1 -p1 -b.result +%patch2 -p1 -b.gettid +%patch3 -p1 -b.386 # cotire seems to cause non-deterministic gcc errors # https://bugzilla.redhat.com/show_bug.cgi?id=1420551 @@ -185,6 +187,9 @@ echo "%{_libdir}/dyninst" > %{buildroot}/etc/ld.so.conf.d/%{name}-%{_arch}.conf %attr(644,root,root) %{_libdir}/dyninst/testsuite/*.a %changelog +* Tue Jun 04 2019 Stan Cox - 10.1.0-2 +- Use PRIx64 to fix i386 build + * Wed May 29 2019 Stan Cox - 10.1.0-1 - Update to 10.1.0