[Heaptrack] [Bug 441125] Fails to build on CentOS 7.2

2021-08-20 Thread Milian Wolff
https://bugs.kde.org/show_bug.cgi?id=441125

Milian Wolff  changed:

   What|Removed |Added

 Resolution|--- |FIXED
  Latest Commit|https://invent.kde.org/sdk/ |https://invent.kde.org/sdk/
   |heaptrack/commit/925ca2f84f |heaptrack/commit/6cf21c2817
   |1446c49885916ea991ccb9139fb |374bbc850c9c93614b7dd73acf1
   |fcf |fa4
 Status|REOPENED|RESOLVED

--- Comment #5 from Milian Wolff  ---
Git commit 6cf21c2817374bbc850c9c93614b7dd73acf1fa4 by Milian Wolff.
Committed on 20/08/2021 at 15:22.
Pushed by mwolff into branch 'master'.

Include cinttypes before libunwind.h

This should fix compilation on Centos 7 with older compilers

M  +3-3src/track/trace_libunwind.cpp

https://invent.kde.org/sdk/heaptrack/commit/6cf21c2817374bbc850c9c93614b7dd73acf1fa4

-- 
You are receiving this mail because:
You are watching all bug changes.

[Heaptrack] [Bug 441125] Fails to build on CentOS 7.2

2021-08-20 Thread Milian Wolff
https://bugs.kde.org/show_bug.cgi?id=441125

--- Comment #4 from Milian Wolff  ---
the default compiler is too old, you will have to update to a newer one through
devtoolset e.g.

-- 
You are receiving this mail because:
You are watching all bug changes.

[Heaptrack] [Bug 441125] Fails to build on CentOS 7.2

2021-08-19 Thread bugzilla_noreply
https://bugs.kde.org/show_bug.cgi?id=441125

ol...@gmx.de changed:

   What|Removed |Added

 Resolution|FIXED   |---
 Status|RESOLVED|REOPENED
 Ever confirmed|0   |1

--- Comment #3 from ol...@gmx.de ---
Thanks for the fixes! Did some tests just now:

- the change in trace_libunwind.cpp doesn't work yet; apparently cinttypes must
be included before libunwind.h.
I guess that libunwind.h includes inttypes.h on its own and therefore any later
inclusion of that file is ignored.


- with the default CentOS 7.2 compiler (g++ 4.8.5) there are several build
errors:

1)
/work/og/inst/heaptrack/src/track/libheaptrack.cpp:170:61: error: parameter
packs not expanded with ‘...’:
  - this looks like https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47226, ie. a
GCC bug


2)
/work/og/inst/heaptrack/src/analyze/accumulatedtracedata.cpp: In lambda
function:
/work/og/inst/heaptrack/src/analyze/accumulatedtracedata.cpp:219:61: error: no
matching function for call to ‘Suppression::Suppression()’
return Suppression {pattern, 0, 0};
 ^
  - incomplete C++11 support, I guess?


AFAIK GCC 4.8.5 only has partial support for C++11. I have now used GCC 7.3.1
from RedHats "Developer Toolset 7" suite instead, and after making the change
in trace_libunwind.cpp it compiles fine, and "heaptrack ls" works.

Personally I think it is not worth the trouble to support GCC 4.8.5.
I haven't found a good way though to enforce a good compiler though, apart from
a hardcoded version check like this:

if (CMAKE_COMPILER_IS_GNUCC)
if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS 7.3)
message(FATAL_ERROR "Require at least GCC 7.3")
endif()
endif()

-- 
You are receiving this mail because:
You are watching all bug changes.

[Heaptrack] [Bug 441125] Fails to build on CentOS 7.2

2021-08-19 Thread Milian Wolff
https://bugs.kde.org/show_bug.cgi?id=441125

--- Comment #2 from Milian Wolff  ---
Git commit af26c60e7e9bc60e7ceb73a09f0151eb81d3881f by Milian Wolff.
Committed on 19/08/2021 at 06:56.
Pushed by mwolff into branch 'master'.

Include cinttypes to ensure PRIxPTR is accessible

IIUC, then we don't need to set __STDC_FORMAT_MACROS as that's
handled by C++ and the cinttypes header for us.

M  +2-1src/track/trace_libunwind.cpp

https://invent.kde.org/sdk/heaptrack/commit/af26c60e7e9bc60e7ceb73a09f0151eb81d3881f

-- 
You are receiving this mail because:
You are watching all bug changes.

[Heaptrack] [Bug 441125] Fails to build on CentOS 7.2

2021-08-19 Thread Milian Wolff
https://bugs.kde.org/show_bug.cgi?id=441125

Milian Wolff  changed:

   What|Removed |Added

 Status|REPORTED|RESOLVED
  Latest Commit||https://invent.kde.org/sdk/
   ||heaptrack/commit/925ca2f84f
   ||1446c49885916ea991ccb9139fb
   ||fcf
 Resolution|--- |FIXED

--- Comment #1 from Milian Wolff  ---
Git commit 925ca2f84f1446c49885916ea991ccb9139fbfcf by Milian Wolff.
Committed on 19/08/2021 at 08:07.
Pushed by mwolff into branch 'master'.

Add copy of dwarf.h with support for DWARF5

The newer libbacktrace version we are shipping is using newer
defines from that header which are not yet available on the dwarf.h
shipped with Centos 7. Thankfully, this header is nicely portable
and self-contained, and licensing (LGPL2.1) should allow shipping
it with our source code too.

Obviously, this now means we'll have to update both, libbacktrace
and libdwarf. But I plan to port heaptrack to use elfutils soon
anyways. At that point, we will be able to remove both again.

M  +1-83rdparty/libbacktrace/CMakeLists.txt
A  +1590 -03rdparty/libdwarf/dwarf.h  *
M  +0-1README.md
M  +1-1tools/Dockerfile

The files marked with a * at the end have a non valid license. Please read:
https://community.kde.org/Policies/Licensing_Policy and use the headers which
are listed at that page.


https://invent.kde.org/sdk/heaptrack/commit/925ca2f84f1446c49885916ea991ccb9139fbfcf

-- 
You are receiving this mail because:
You are watching all bug changes.