Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions cmake/External.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# ------------------------------------------------------------------------------

# Copy the configuration
configure_file(${CMAKE_SOURCE_DIR}/cmake/extern/ArduinoJson.txt.in
configure_file(${CMAKE_INSTALL_PREFIX}/cmake/extern/ArduinoJson.txt.in
${EXTERNAL_LIBRARY_DIR}/arduinojson/CMakeLists.txt)

# Configure the Cmake build
Expand Down Expand Up @@ -38,7 +38,7 @@ include_directories(${ARDUINO_JSON_SOURCE_DIR})
# ------------------------------------------------------------------------------

# Copy the configuration
configure_file(${CMAKE_SOURCE_DIR}/cmake/extern/BCL.txt.in
configure_file(${CMAKE_INSTALL_PREFIX}/cmake/extern/BCL.txt.in
${EXTERNAL_LIBRARY_DIR}/bcl/CMakeLists.txt)

# Configure the Cmake build
Expand Down Expand Up @@ -81,7 +81,7 @@ include_directories(${EXTERNAL_LIBRARY_DIR}/bcl/src/src)
# ------------------------------------------------------------------------------

# Copy the configuration
configure_file(${CMAKE_SOURCE_DIR}/cmake/extern/BIP66.txt.in
configure_file(${CMAKE_INSTALL_PREFIX}/cmake/extern/BIP66.txt.in
${EXTERNAL_LIBRARY_DIR}/bip66/CMakeLists.txt)

# Configure the Cmake build
Expand Down Expand Up @@ -115,7 +115,7 @@ include_directories(${EXTERNAL_LIBRARY_DIR}/bip66/src/)
# ------------------------------------------------------------------------------

# Copy the configuration
configure_file(${CMAKE_SOURCE_DIR}/cmake/extern/uECC.txt.in
configure_file(${CMAKE_INSTALL_PREFIX}/cmake/extern/uECC.txt.in
${EXTERNAL_LIBRARY_DIR}/uecc/CMakeLists.txt)

# Configure the Cmake build
Expand Down Expand Up @@ -158,4 +158,8 @@ set(EXTERNAL_LIBRARY_SOURCE
${UECC_SOURCE}
CACHE INTERNAL "External Lib Binary Files")

set(EXTERNAL_LIBRARY_INCLUDE
${ARDUINO_JSON_SOURCE_DIR}
CACHE INTERNAL "External Lib Include Dirs")

# ------------------------------------------------------------------------------
3 changes: 2 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ project(ark_cpp_crypto C CXX)
# External Libraries
# ------------------------------------------------------------------------------

include(${CMAKE_SOURCE_DIR}/cmake/External.cmake)
include(${CMAKE_INSTALL_PREFIX}/cmake/External.cmake)

# ------------------------------------------------------------------------------

Expand Down Expand Up @@ -128,6 +128,7 @@ add_library(${PROJECT_NAME} STATIC
# ------------------------------------------------------------------------------

set(ARK_CPP_CRYPTO_INCLUDE_DIRS
${EXTERNAL_LIBRARY_INCLUDE}
${PROJECT_SOURCE_DIR}
${PROJECT_SOURCE_DIR}/include/cpp-crypto
${PROJECT_SOURCE_DIR}/lib/
Expand Down