mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-29 14:20:29 +00:00
[llvm-exegesis] Check for libpfm headers.
HAVE_LIBPFM is only defined if the libpfm headers are present. llvm-svn: 329261
This commit is contained in:
parent
c1b8b371a8
commit
9d7dd3b74c
@ -87,7 +87,17 @@ if( NOT PURE_WINDOWS )
|
||||
endif()
|
||||
check_library_exists(dl dlopen "" HAVE_LIBDL)
|
||||
check_library_exists(rt clock_gettime "" HAVE_LIBRT)
|
||||
check_library_exists(pfm pfm_initialize "" HAVE_LIBPFM)
|
||||
endif()
|
||||
|
||||
# Check for libpfm.
|
||||
check_library_exists(pfm pfm_initialize "" HAVE_LIBPFM_INITIALIZE)
|
||||
if(HAVE_LIBPFM_INITIALIZE)
|
||||
check_include_file(perfmon/perf_event.h HAVE_PERFMON_PERF_EVENT_H)
|
||||
check_include_file(perfmon/pfmlib.h HAVE_PERFMON_PFMLIB_H)
|
||||
check_include_file(perfmon/pfmlib_perf_event.h HAVE_PERFMON_PFMLIB_PERF_EVENT_H)
|
||||
if(HAVE_PERFMON_PERF_EVENT_H AND HAVE_PERFMON_PFMLIB_H AND HAVE_PERFMON_PFMLIB_PERF_EVENT_H)
|
||||
set(HAVE_LIBPFM 1)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(HAVE_LIBPTHREAD)
|
||||
|
Loading…
Reference in New Issue
Block a user