mirror of
https://github.com/WinDurango/WinDurango.git
synced 2026-01-31 00:55:17 +01:00
43 lines
1.1 KiB
CMake
43 lines
1.1 KiB
CMake
cmake_minimum_required(VERSION 4.0)
|
|
project(WinDurango.KernelX VERSION 1.0.0)
|
|
|
|
set(VERSION_SUFFIX "-dev.1") # used for non-stable versions, otherwise blank
|
|
set(CMAKE_CXX_STANDARD 20)
|
|
|
|
include(FetchContent)
|
|
|
|
# Safetyhook
|
|
FetchContent_Declare(
|
|
safetyhook
|
|
GIT_REPOSITORY "https://github.com/cursey/safetyhook.git"
|
|
GIT_TAG "origin/main"
|
|
)
|
|
FetchContent_MakeAvailable(safetyhook)
|
|
|
|
set(FILES
|
|
src/kernelx.cpp
|
|
src/dllmain.cpp
|
|
src/Hooks.cpp
|
|
include/WinDurango.KernelX/kernelx.h
|
|
include/WinDurango.KernelX/Logan.h
|
|
include/WinDurango.KernelX/Hooks.h
|
|
)
|
|
|
|
add_library(WinDurango.KernelX SHARED ${FILES})
|
|
|
|
target_link_libraries(WinDurango.KernelX PRIVATE WinDurango.Common WinDurango.Implementation.WinRT)
|
|
|
|
target_link_options(WinDurango.KernelX
|
|
PUBLIC
|
|
$<$<CXX_COMPILER_ID:MSVC>:/FORCE:MULTIPLE>
|
|
)
|
|
|
|
target_include_directories(WinDurango.KernelX PUBLIC
|
|
${CMAKE_CURRENT_SOURCE_DIR}/include/WinDurango.KernelX/
|
|
${CMAKE_SOURCE_DIR}/projects/WinDurango.Common/include
|
|
${CMAKE_SOURCE_DIR}/projects/WinDurango.Implementation.WinRT/include
|
|
)
|
|
|
|
set_target_properties(WinDurango.KernelX PROPERTIES
|
|
OUTPUT_NAME "kernelx"
|
|
) |