Skip to content

Commit

Permalink
Fix Shared Cache Plugin out-of-tree build
Browse files Browse the repository at this point in the history
  • Loading branch information
VisualEhrmanntraut authored Dec 24, 2024
1 parent d67f08d commit 22cdb25
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions view/sharedcache/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@ cmake_minimum_required(VERSION 3.13 FATAL_ERROR)

project(sharedcache)

if((NOT BN_API_PATH) AND (NOT BN_INTERNAL_BUILD))
set(BN_API_PATH $ENV{BN_API_PATH} CACHE STRING "Path to Binary Ninja API source")
if(NOT BN_API_PATH)
message(FATAL_ERROR "Provide path to Binary Ninja API source in BN_API_PATH")
endif()
if(NOT BN_INTERNAL_BUILD)
find_path(
BN_API_PATH
NAMES binaryninjaapi.h
HINTS ../../.. binaryninjaapi $ENV{BN_API_PATH}
REQUIRED
)
add_subdirectory(${BN_API_PATH} binaryninjaapi)
endif()

if (NOT BN_INTERNAL_BUILD)
Expand Down Expand Up @@ -105,4 +108,4 @@ message("
▒▒▓ ▒ ▒ ▒▓▒ ▒ ░░ ░▒ ▒ ░ Crash on Failure: ${HARD_FAIL_MODE}
░ ▒ ▒ ░ ░▒ ░ ░ ░ ▒ Slideinfo Debug Tags: ${SLIDEINFO_DEBUG_TAGS}
░ ░ ░ ░ ░ ░ ░ REFCOUNT_DEBUG: ${BN_REF_COUNT_DEBUG}
")
")

0 comments on commit 22cdb25

Please sign in to comment.