30 lines
763 B
CMake
30 lines
763 B
CMake
cmake_minimum_required(VERSION 3.16)
|
|
project(shrap)
|
|
|
|
set(CMAKE_CXX_STANDARD 20)
|
|
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
|
|
set(SQLITE_OMIT_LOAD_EXTENSION ON CACHE BOOL "Disable SQLite load_extension()" FORCE)
|
|
|
|
include(FetchContent)
|
|
FetchContent_Declare(
|
|
SQLiteCpp
|
|
GIT_REPOSITORY https://github.com/SRombauts/SQLiteCpp
|
|
GIT_TAG 3.3.3
|
|
)
|
|
FetchContent_MakeAvailable(SQLiteCpp)
|
|
|
|
FetchContent_Declare(
|
|
blake3
|
|
GIT_REPOSITORY https://github.com/BLAKE3-team/BLAKE3.git
|
|
GIT_TAG 1.8.3
|
|
)
|
|
FetchContent_Populate(blake3)
|
|
|
|
add_subdirectory(${blake3_SOURCE_DIR}/c ${blake3_BINARY_DIR})
|
|
|
|
add_executable(${PROJECT_NAME} src/main.cc)
|
|
|
|
target_link_libraries(${PROJECT_NAME} PRIVATE blake3 SQLiteCpp)
|
|
|
|
set_target_properties(${PROJECT_NAME} PROPERTIES LINK_FLAGS "-static")
|