acaringi / rpms / bcc

Forked from rpms/bcc 5 years ago
Clone
Blob Blame History Raw
From 9adafa085c720d99aff2025d613d7d18e2508624 Mon Sep 17 00:00:00 2001
From: Augusto Caringi <acaringi@redhat.com>
Date: Tue, 30 Oct 2018 23:59:41 +0100
Subject: [PATCH] Set additional headers for installation

These headers can be required by other tools (bpftrace) depending on bcc
tools.
---
 src/cc/CMakeLists.txt | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/cc/CMakeLists.txt b/src/cc/CMakeLists.txt
index fda165d..3401593 100644
--- a/src/cc/CMakeLists.txt
+++ b/src/cc/CMakeLists.txt
@@ -39,6 +39,8 @@ set(bcc_sym_sources bcc_syms.cc bcc_elf.c bcc_perf_map.c bcc_proc.c)
 set(bcc_common_headers libbpf.h perf_reader.h)
 set(bcc_table_headers file_desc.h table_desc.h table_storage.h)
 set(bcc_api_headers bpf_common.h bpf_module.h bcc_exception.h bcc_syms.h)
+set(bcc_other_headers common.h syms.h ns_guard.h)
+set(bcc_frontends_clang_headers frontends/clang/kbuild_helper.h)
 
 if(ENABLE_CLANG_JIT)
 add_library(bcc-shared SHARED
@@ -98,6 +100,8 @@ set(bcc-lua-static ${bcc-lua-static} ${bcc_common_libs_for_lua})
 install(TARGETS bcc-shared LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
 install(FILES ${bcc_table_headers} DESTINATION include/bcc)
 install(FILES ${bcc_api_headers} DESTINATION include/bcc)
+install(FILES ${bcc_other_headers} DESTINATION include/bcc)
+install(FILES ${bcc_frontends_clang_headers} DESTINATION include/bcc/frontends/clang)
 install(DIRECTORY compat/linux/ DESTINATION include/bcc/compat/linux FILES_MATCHING PATTERN "*.h")
 install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libbcc.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
 endif(ENABLE_CLANG_JIT)
-- 
2.17.2