From 3890a70cb4eb87e3441206b912b5d76a6977e247 Mon Sep 17 00:00:00 2001 From: Jeremy Rifkin <51220084+jeremy-rifkin@users.noreply.github.com> Date: Fri, 13 Sep 2024 08:19:24 -0500 Subject: [PATCH 1/4] Bump to v0.7.1 --- CHANGELOG.md | 21 +++++++++++++++++++++ CMakeLists.txt | 2 +- README.md | 14 +++++++------- 3 files changed, 29 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2a371a2..cafd0ca 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ # Changelog - [Changelog](#changelog) +- [v0.7.1](#v071) - [v0.7.0](#v070) - [v0.6.3](#v063) - [v0.6.2](#v062) @@ -20,6 +21,26 @@ - [v0.1.1](#v011) - [v0.1](#v01) +# v0.7.1 + +Added +- Better support for finding libunwind on macos https://github.com/jeremy-rifkin/cpptrace/pull/162 +- Support for libbacktrace under mingw https://github.com/jeremy-rifkin/cpptrace/pull/166 + +Fixed +- Computation of object address for safe object frames https://github.com/jeremy-rifkin/cpptrace/issues/169 +- Nested microfmt in cpptrace's namespace due to an ODR problem with libassert + https://github.com/jeremy-rifkin/libassert/issues/103 +- Compilation on iOS https://github.com/jeremy-rifkin/cpptrace/pull/167 +- Compilation on old MSVC https://github.com/jeremy-rifkin/cpptrace/pull/165 +- Dbghelp use on 32 bit https://github.com/jeremy-rifkin/cpptrace/issues/170 +- Warning in brand new cmake due to FetchContent_Populate being deprecated + +Other changes +- Bumped the buffer size for execinfo and CaptureStackBackTrace to 400 frames +- Switched to execinfo.h for unwinding on clang/apple clang on macos due to `_Unwind` not working with `-fno-exceptions` + https://github.com/jeremy-rifkin/cpptrace/issues/161 + # v0.7.0 Added diff --git a/CMakeLists.txt b/CMakeLists.txt index e8645f7..9b017db 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -9,7 +9,7 @@ set(package_name "cpptrace") project( cpptrace - VERSION 0.7.0 + VERSION 0.7.1 DESCRIPTION "Simple, portable, and self-contained stacktrace library for C++11 and newer " HOMEPAGE_URL "https://github.com/jeremy-rifkin/cpptrace" LANGUAGES C CXX diff --git a/README.md b/README.md index 614495d..ebfe37e 100644 --- a/README.md +++ b/README.md @@ -134,7 +134,7 @@ include(FetchContent) FetchContent_Declare( cpptrace GIT_REPOSITORY https://github.com/jeremy-rifkin/cpptrace.git - GIT_TAG v0.7.0 # + GIT_TAG v0.7.1 # ) FetchContent_MakeAvailable(cpptrace) target_link_libraries(your_target cpptrace::cpptrace) @@ -793,7 +793,7 @@ include(FetchContent) FetchContent_Declare( cpptrace GIT_REPOSITORY https://github.com/jeremy-rifkin/cpptrace.git - GIT_TAG v0.7.0 # + GIT_TAG v0.7.1 # ) FetchContent_MakeAvailable(cpptrace) target_link_libraries(your_target cpptrace::cpptrace) @@ -809,7 +809,7 @@ information. ```sh git clone https://github.com/jeremy-rifkin/cpptrace.git -git checkout v0.7.0 +git checkout v0.7.1 mkdir cpptrace/build cd cpptrace/build cmake .. -DCMAKE_BUILD_TYPE=Release @@ -852,7 +852,7 @@ you when installing new libraries. ```ps1 git clone https://github.com/jeremy-rifkin/cpptrace.git -git checkout v0.7.0 +git checkout v0.7.1 mkdir cpptrace/build cd cpptrace/build cmake .. -DCMAKE_BUILD_TYPE=Release @@ -870,7 +870,7 @@ To install just for the local user (or any custom prefix): ```sh git clone https://github.com/jeremy-rifkin/cpptrace.git -git checkout v0.7.0 +git checkout v0.7.1 mkdir cpptrace/build cd cpptrace/build cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=$HOME/wherever @@ -953,7 +953,7 @@ make install cd ~/scratch/cpptrace-test git clone https://github.com/jeremy-rifkin/cpptrace.git cd cpptrace -git checkout v0.7.0 +git checkout v0.7.1 mkdir build cd build cmake .. -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=On -DCPPTRACE_USE_EXTERNAL_LIBDWARF=On -DCMAKE_PREFIX_PATH=~/scratch/cpptrace-test/resources -DCMAKE_INSTALL_PREFIX=~/scratch/cpptrace-test/resources @@ -973,7 +973,7 @@ cpptrace and its dependencies. Cpptrace is available through conan at https://conan.io/center/recipes/cpptrace. ``` [requires] -cpptrace/0.7.0 +cpptrace/0.7.1 [generators] CMakeDeps CMakeToolchain From 06eb15bda66c5d060f45740b179e80be8e355645 Mon Sep 17 00:00:00 2001 From: Jeremy Rifkin <51220084+jeremy-rifkin@users.noreply.github.com> Date: Fri, 13 Sep 2024 08:21:28 -0500 Subject: [PATCH 2/4] Some changelog corrections for v0.7.1 --- CHANGELOG.md | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cafd0ca..098f188 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -29,17 +29,15 @@ Added Fixed - Computation of object address for safe object frames https://github.com/jeremy-rifkin/cpptrace/issues/169 -- Nested microfmt in cpptrace's namespace due to an ODR problem with libassert - https://github.com/jeremy-rifkin/libassert/issues/103 +- Nested microfmt in cpptrace's namespace due to an ODR problem with libassert https://github.com/jeremy-rifkin/libassert/issues/103 - Compilation on iOS https://github.com/jeremy-rifkin/cpptrace/pull/167 - Compilation on old MSVC https://github.com/jeremy-rifkin/cpptrace/pull/165 - Dbghelp use on 32 bit https://github.com/jeremy-rifkin/cpptrace/issues/170 -- Warning in brand new cmake due to FetchContent_Populate being deprecated +- Warning in brand new cmake due to `FetchContent_Populate` being deprecated https://github.com/jeremy-rifkin/cpptrace/issues/171 Other changes - Bumped the buffer size for execinfo and CaptureStackBackTrace to 400 frames -- Switched to execinfo.h for unwinding on clang/apple clang on macos due to `_Unwind` not working with `-fno-exceptions` - https://github.com/jeremy-rifkin/cpptrace/issues/161 +- Switched to execinfo.h for unwinding on clang/apple clang on macos due to `_Unwind` not working with `-fno-exceptions` https://github.com/jeremy-rifkin/cpptrace/issues/161 # v0.7.0 From 54a3e6fdf7837c44d20436c77d3469f4524bf6a1 Mon Sep 17 00:00:00 2001 From: Sofie Date: Tue, 17 Sep 2024 15:25:23 +0200 Subject: [PATCH 3/4] fix: mangled url for FetchContent in cmake 3.16 (#176) Fixes #174 Seems to be that older versions of CMake has a tendency to mangle URLs as per described in https://stackoverflow.com/questions/74996365/ --- CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 9b017db..8b35119 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -422,9 +422,9 @@ if(CPPTRACE_GET_SYMBOLS_WITH_LIBDWARF) set(ZSTD_LEGACY_SUPPORT OFF) FetchContent_Declare( zstd - URL "${CPPTRACE_ZSTD_URL}" - DOWNLOAD_EXTRACT_TIMESTAMP TRUE SOURCE_SUBDIR build/cmake + DOWNLOAD_EXTRACT_TIMESTAMP TRUE + URL "${CPPTRACE_ZSTD_URL}" ) FetchContent_MakeAvailable(zstd) endif() From ce8214bb16c7cedb3707fbf82c88fd603b9a41af Mon Sep 17 00:00:00 2001 From: Patrick Quist Date: Mon, 30 Sep 2024 07:25:58 +0200 Subject: [PATCH 4/4] getpagesize() was removed from OSX (and posix) (#177) --- src/from_current.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/from_current.cpp b/src/from_current.cpp index 308735f..47610fb 100644 --- a/src/from_current.cpp +++ b/src/from_current.cpp @@ -107,7 +107,11 @@ namespace cpptrace { } #else int get_page_size() { - return getpagesize(); + #if defined(_SC_PAGESIZE) + return sysconf(_SC_PAGESIZE); + #else + return getpagesize(); + #endif } constexpr auto memory_readonly = PROT_READ; constexpr auto memory_readwrite = PROT_READ | PROT_WRITE;