From 2400b67a65eb644aede8c0f514098a3ab1a995f0 Mon Sep 17 00:00:00 2001 From: happy_orange Date: Thu, 28 Jul 2022 05:11:09 -0400 Subject: [PATCH] fix build error because of the tbb update to 2021.5.0 --- 0000-modify-the-file-for-tbb-verison.h.patch | 30 ++++++++++++++++++++ dyninst.spec | 11 ++++++- 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 0000-modify-the-file-for-tbb-verison.h.patch diff --git a/0000-modify-the-file-for-tbb-verison.h.patch b/0000-modify-the-file-for-tbb-verison.h.patch new file mode 100644 index 0000000..45ba374 --- /dev/null +++ b/0000-modify-the-file-for-tbb-verison.h.patch @@ -0,0 +1,30 @@ +From a5369fa056bb08ce8430ee2ad097b8eee7894778 Mon Sep 17 00:00:00 2001 +From: root +Date: Thu, 28 Jul 2022 04:24:03 -0400 +Subject: [PATCH] modify the file for tbb verison.h + +--- + cmake/Modules/FindTBB.cmake | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/cmake/Modules/FindTBB.cmake b/cmake/Modules/FindTBB.cmake +index 93a9b8c..b48d614 100644 +--- a/cmake/Modules/FindTBB.cmake ++++ b/cmake/Modules/FindTBB.cmake +@@ -151,10 +151,11 @@ find_path(TBB_INCLUDE_DIRS tbb/tbb.h + # Set version strings + # + if(TBB_INCLUDE_DIRS) +- # Starting in 2020.1.1, tbb_stddef.h is replaced by version.h ++ # Starting in 2020.1.1, tbb_stddef.h is replaced by version.h. ++ # But in 2021.1.1 the tbb/version.h is link to oneapi/tbb/version.h + set(_version_files + "${TBB_INCLUDE_DIRS}/tbb/tbb_stddef.h" +- "${TBB_INCLUDE_DIRS}/tbb/version.h" ++ "${TBB_INCLUDE_DIRS}/oneapi/tbb/version.h" + ) + foreach(f IN ITEMS ${_version_files}) + if(EXISTS ${f}) +-- +2.27.0 + diff --git a/dyninst.spec b/dyninst.spec index b32f4c7..2750c96 100644 --- a/dyninst.spec +++ b/dyninst.spec @@ -1,4 +1,4 @@ -%define anolis_release 1 +%define anolis_release 2 Summary: An API for Run-time Code Generation License: LGPLv2+ Name: dyninst @@ -12,6 +12,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 +Patch1000: 0000-modify-the-file-for-tbb-verison.h.patch + %global dyninst_base dyninst-%{version} %global testsuite_base testsuite-%{__testsuite_version} @@ -78,6 +80,10 @@ making sure that dyninst works properly. %setup -q -n %{name}-%{version} -c %setup -q -T -D -a 1 +pushd %{name}-%{version} +%patch1000 -p1 +popd + # cotire seems to cause non-deterministic gcc errors sed -i.cotire -e 's/USE_COTIRE true/USE_COTIRE false/' \ %{dyninst_base}/cmake/shared.cmake @@ -181,5 +187,8 @@ find %{buildroot}%{_libdir}/dyninst/testsuite/ \ %attr(644,root,root) %{_libdir}/dyninst/testsuite/*.a %changelog +* Thu Jul 28 2022 happy_orange - 12.1.0-2 +- Fix build error because the tbb update to 2021.5.0 + * Mon May 16 2022 Chunmei Xu - 12.1.0-1 - init from upstream -- Gitee