Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -441,8 +441,17 @@ if(BUILD_UNIVERSAL_DDPROF)
endif()
endif()

set(_install_targets ddprof dd_profiling-static dd_profiling-shared)
if(USE_LOADER)
# Install the embedded profiling library so the loader can dlopen it from a
# standard path instead of extracting the copy baked into the loader to /tmp.
# The /tmp fallback loses file capabilities (CAP_PERFMON) on the ddprof
# binary, which breaks perf_event_open.
list(APPEND _install_targets dd_profiling-embedded)
endif()

install(
TARGETS ddprof dd_profiling-static dd_profiling-shared
TARGETS ${_install_targets}
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
Expand Down