summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorrose <47357290+rompse@users.noreply.github.com>2021-09-30 16:00:17 -0400
committerrose <47357290+rompse@users.noreply.github.com>2021-09-30 16:00:17 -0400
commit11b350aa1984cc19a2993fd5a60b5eabe28dc8bc (patch)
tree8036264c4670601ef17faa82a75fa1628c23c259 /examples
parented2115cda93742733ac6f3239947681963be87c8 (diff)
Fix CMake recursive subdirectories & triage build
Diffstat (limited to 'examples')
-rw-r--r--examples/CMakeLists.txt1
-rw-r--r--examples/triage/CMakeLists.txt11
-rw-r--r--examples/workflows/inliner/CMakeLists.txt10
-rw-r--r--examples/workflows/objectivec/CMakeLists.txt10
-rw-r--r--examples/workflows/tailcall/CMakeLists.txt10
5 files changed, 5 insertions, 37 deletions
diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt
index 4aa55dc8..b2f7e515 100644
--- a/examples/CMakeLists.txt
+++ b/examples/CMakeLists.txt
@@ -6,6 +6,7 @@ add_subdirectory(mlil_parser)
add_subdirectory(print_syscalls)
if(NOT HEADLESS)
add_subdirectory(uinotification)
+ add_subdirectory(triage)
endif()
if(NOT DEMO AND NOT PERSONAL)
add_subdirectory(workflows/inliner)
diff --git a/examples/triage/CMakeLists.txt b/examples/triage/CMakeLists.txt
index 05dd03ce..4eb6ef5f 100644
--- a/examples/triage/CMakeLists.txt
+++ b/examples/triage/CMakeLists.txt
@@ -1,12 +1,8 @@
cmake_minimum_required(VERSION 3.9 FATAL_ERROR)
-option(QT6 "Target Qt 6" OFF)
-
project(triage)
-if(NOT QT6)
- set(CMAKE_OSX_ARCHITECTURES x86_64)
-endif()
+find_package(Qt6 COMPONENTS Core Gui Widgets REQUIRED)
file(GLOB SOURCES
*.cpp
@@ -18,8 +14,9 @@ else()
add_library(triage SHARED ${SOURCES})
endif()
-target_link_libraries(triage binaryninjaapi binaryninjaui)
-
+target_link_libraries(triage binaryninjaapi binaryninjaui
+ Qt6::Core Qt6::Gui Qt6::Widgets)
+
set_target_properties(triage PROPERTIES
CXX_STANDARD 17
CXX_VISIBILITY_PRESET hidden
diff --git a/examples/workflows/inliner/CMakeLists.txt b/examples/workflows/inliner/CMakeLists.txt
index 59611afb..c42d580e 100644
--- a/examples/workflows/inliner/CMakeLists.txt
+++ b/examples/workflows/inliner/CMakeLists.txt
@@ -2,16 +2,6 @@ cmake_minimum_required(VERSION 3.9 FATAL_ERROR)
project(workflow_inliner)
-if((NOT BN_API_PATH) AND (NOT BN_INTERNAL_BUILD))
- set(BN_API_PATH $ENV{BN_API_PATH})
- if(NOT BN_API_PATH)
- message(FATAL_ERROR "Provide path to Binary Ninja API source in BN_API_PATH")
- endif()
-endif()
-if(NOT BN_INTERNAL_BUILD)
- add_subdirectory(${BN_API_PATH} ${PROJECT_BINARY_DIR}/api)
-endif()
-
file(GLOB SOURCES
*.cpp
*.c
diff --git a/examples/workflows/objectivec/CMakeLists.txt b/examples/workflows/objectivec/CMakeLists.txt
index e807235c..f5f8ea5e 100644
--- a/examples/workflows/objectivec/CMakeLists.txt
+++ b/examples/workflows/objectivec/CMakeLists.txt
@@ -2,16 +2,6 @@ cmake_minimum_required(VERSION 3.9 FATAL_ERROR)
project(workflow_objectivec)
-if((NOT BN_API_PATH) AND (NOT BN_INTERNAL_BUILD))
- set(BN_API_PATH $ENV{BN_API_PATH})
- if(NOT BN_API_PATH)
- message(FATAL_ERROR "Provide path to Binary Ninja API source in BN_API_PATH")
- endif()
-endif()
-if(NOT BN_INTERNAL_BUILD)
- add_subdirectory(${BN_API_PATH} ${PROJECT_BINARY_DIR}/api)
-endif()
-
file(GLOB SOURCES
*.cpp
*.c
diff --git a/examples/workflows/tailcall/CMakeLists.txt b/examples/workflows/tailcall/CMakeLists.txt
index d1d547a4..fa322684 100644
--- a/examples/workflows/tailcall/CMakeLists.txt
+++ b/examples/workflows/tailcall/CMakeLists.txt
@@ -2,16 +2,6 @@ cmake_minimum_required(VERSION 3.9 FATAL_ERROR)
project(workflow_tailcall)
-if((NOT BN_API_PATH) AND (NOT BN_INTERNAL_BUILD))
- set(BN_API_PATH $ENV{BN_API_PATH})
- if(NOT BN_API_PATH)
- message(FATAL_ERROR "Provide path to Binary Ninja API source in BN_API_PATH")
- endif()
-endif()
-if(NOT BN_INTERNAL_BUILD)
- add_subdirectory(${BN_API_PATH} ${PROJECT_BINARY_DIR}/api)
-endif()
-
file(GLOB SOURCES
*.cpp
*.c