Skip to content

Commit ef4bf3a

Browse files
fixing an issue with pthread (#71)
* fixing in issue with pthread * fixing in issue with libstdc++ and pthread
1 parent c5fa0b9 commit ef4bf3a

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.49.10
1+
0.49.11

tools/oneprof/CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,10 @@ CheckForMetricsLibrary()
4444
# Loader
4545

4646
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DTOOL_NAME=oneprof_tool")
47+
#Folloing is fixing an issue with libstdc++, depending on libpthread, but not linked against libpthread.
48+
#Details: https://stackoverflow.com/questions/51209268/using-stdthread-in-a-library-loaded-with-dlopen-leads-to-a-sigsev
49+
#Bug submission: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67791 (fixed from gcc 10.5 and later)
50+
add_link_options(-Wl,--no-as-needed -lpthread -Wl,--as-needed)
4751
add_executable(oneprof "${PROJECT_SOURCE_DIR}/../../loader/loader.cc")
4852
target_include_directories(oneprof
4953
PRIVATE "${PROJECT_SOURCE_DIR}/../../utils")

0 commit comments

Comments
 (0)