Skip to content

Commit

Permalink
Merge pull request iovisor#795 from mslusarz/install-perf_reader.h
Browse files Browse the repository at this point in the history
perf_reader: install perf_reader.h
  • Loading branch information
drzaeus77 committed Nov 2, 2016
2 parents ac584d0 + b667e02 commit 5496aaf
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/cc/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ target_link_libraries(bcc-static b_frontend clang_frontend bcc-loader-static ${c

install(TARGETS bcc-shared LIBRARY COMPONENT libbcc
DESTINATION ${CMAKE_INSTALL_LIBDIR})
install(FILES bpf_common.h bpf_module.h bcc_syms.h libbpf.h COMPONENT libbcc
install(FILES bpf_common.h bpf_module.h bcc_syms.h libbpf.h perf_reader.h COMPONENT libbcc
DESTINATION include/bcc)
install(DIRECTORY compat/linux/ COMPONENT libbcc
DESTINATION include/bcc/compat/linux
Expand Down
15 changes: 15 additions & 0 deletions src/cc/perf_reader.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,15 @@
* limitations under the License.
*/

#ifndef PERF_READER_H
#define PERF_READER_H

#include "libbpf.h"

#ifdef __cplusplus
extern "C" {
#endif

struct perf_reader;

struct perf_reader * perf_reader_new(perf_reader_cb cb, perf_reader_raw_cb raw_cb, void *cb_cookie);
Expand All @@ -22,3 +31,9 @@ int perf_reader_mmap(struct perf_reader *reader, unsigned type, unsigned long sa
int perf_reader_poll(int num_readers, struct perf_reader **readers, int timeout);
int perf_reader_fd(struct perf_reader *reader);
void perf_reader_set_fd(struct perf_reader *reader, int fd);

#ifdef __cplusplus
}
#endif

#endif

0 comments on commit 5496aaf

Please sign in to comment.