blob: 4c0ace9093181bea12196893d2d04d91c3d6d021 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
cmake_minimum_required(VERSION 3.15 FATAL_ERROR)
file(GLOB BN_BASE_SOURCES CONFIGURE_DEPENDS *.cpp *.h)
add_library(binaryninjabase OBJECT ${BN_BASE_SOURCES})
set_target_properties(binaryninjabase PROPERTIES LINKER_LANGUAGE CXX)
target_include_directories(binaryninjabase
PUBLIC ${PROJECT_SOURCE_DIR})
set_target_properties(binaryninjabase PROPERTIES
CXX_STANDARD 20
CXX_VISIBILITY_PRESET hidden
CXX_STANDARD_REQUIRED ON
VISIBILITY_INLINES_HIDDEN ON
POSITION_INDEPENDENT_CODE ON)
if(BN_REF_COUNT_DEBUG)
target_compile_definitions(binaryninjabase PUBLIC BN_REF_COUNT_DEBUG)
endif()
if(CMAKE_BUILD_TYPE MATCHES Debug OR CMAKE_BUILD_TYPE MATCHES RelWithDebInfo)
target_compile_definitions(binaryninjabase PRIVATE BN_ENABLE_LOG_TRACE)
endif()
|