-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
42 lines (33 loc) · 1.14 KB
/
CMakeLists.txt
File metadata and controls
42 lines (33 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
cmake_minimum_required(VERSION 3.16)
project( ACGPlugin DESCRIPTION "An plugin for MetaCG's CaGe tool, to track argument flow across a callgraph'")
include(FetchContent)
set(CMAKE_CXX_STANDARD 23)
set(METACG_BUILD_GRAPH_TOOLS ON)
FetchContent_Declare(
metacg
GIT_REPOSITORY https://github.com/TimHeldmann/MetaCG.git
GIT_TAG 8118279394a540ffce8ea9369b9235d6e80fd865
)
FetchContent_MakeAvailable(metacg)
find_package(
LLVM
REQUIRED
CONFIG
)
set(METAVIRT_LOG_LEVEL
"0"
CACHE STRING "MetaVirt log level from 0 (least verbose) to 4 (most verbose)"
)
FetchContent_Declare(
metavirt
GIT_REPOSITORY https://github.com/ahueck/llvm-metavirt.git
GIT_TAG devel
GIT_SHALLOW 1
FIND_PACKAGE_ARGS
)
FetchContent_MakeAvailable(metavirt)
add_library(acg-plugin SHARED src/ACGPlugin.cpp)
target_include_directories(acg-plugin PRIVATE include ${LLVM_INCLUDE_DIRS})
target_include_directories(acg-plugin PRIVATE $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/include>)
target_link_libraries(acg-plugin PRIVATE cage-plugin-interface)
target_link_libraries(acg-plugin PRIVATE metavirt::Types)