Explicitly include time.h when building the testsuite

This commit is contained in:
Stan Cox 2022-08-03 11:45:04 -04:00
parent 6d48c36717
commit c69dd4f6e2
3 changed files with 22 additions and 5 deletions

12
cmdline.patch Normal file
View File

@ -0,0 +1,12 @@
# c++/12/bits/basic_string.h in libstdc++-devel-12.1.1-3 no longer includes <ext/atomicity.h>
# atomicity.h includes gthr -> gthr-default -> pthread .h -> time.h -> struct-tm.h
# so explicitly include time.h
--- testsuite-12.1.0/src/CmdLine.C
+++ testsuite-12.1.0/src/CmdLine.C
@@ -38,5 +38,3 @@
-#if defined(os_windows_test)
#include <time.h>
-#endif

View File

@ -3,8 +3,8 @@ Remove extraneous error messages of the form:
err message: invalid DWARF
which are repeated in some circumstances without adding useful context
--- dyninst-12.0.1/symtabAPI/src/dwarfWalker.C
+++ dyninst-12.0.1/symtabAPI/src/dwarfWalker.C
--- dyninst-12.1.0/symtabAPI/src/dwarfWalker.C
+++ dyninst-12.1.0/symtabAPI/src/dwarfWalker.C
@@ -1858,1 +1858,1 @@
- cerr << "err message: " << dwarf_errmsg(dwarf_errno()) << endl;
+ dwarf_printf("(0x%lx) Error while decoding location: %s\n", id(), dwarf_errmsg(dwarf_errno()));

View File

@ -2,7 +2,7 @@ Summary: An API for Run-time Code Generation
License: LGPLv2+
Name: dyninst
Group: Development/Libraries
Release: 3%{?dist}
Release: 4%{?dist}
URL: http://www.dyninst.org
Version: 12.1.0
ExclusiveArch: %{ix86} x86_64 ppc64le aarch64
@ -11,7 +11,8 @@ 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/%{__testsuite_version}/testsuite-%{__testsuite_version}.tar.gz
Patch2: dwarf-error.patch
Patch1: dwarf-error.patch
Patch2: cmdline.patch
%global dyninst_base dyninst-%{version}
%global testsuite_base testsuite-%{__testsuite_version}
@ -80,10 +81,11 @@ making sure that dyninst works properly.
%setup -q -T -D -a 1
pushd %{dyninst_base}
%patch2 -p1 -b .dwerr
%patch1 -p1 -b .dwerr
popd
pushd %{testsuite_base}
%patch2 -p1 -b .cmdline
popd
# cotire seems to cause non-deterministic gcc errors
@ -190,6 +192,9 @@ find %{buildroot}%{_libdir}/dyninst/testsuite/ \
%attr(644,root,root) %{_libdir}/dyninst/testsuite/*.a
%changelog
* Wed Aug 03 2022 Stan Cox <scox@redhat.com> - 12.1.0-4
- Explicitly include time.h as <string> no longer pulls it in
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 12.1.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild