mirror of
https://codeberg.org/WinDurango/WinDurango.git
synced 2026-04-18 02:23:34 -04:00
48 lines
1.7 KiB
CMake
48 lines
1.7 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)
|
|
|
|
FetchContent_Declare(concurrencpp GIT_REPOSITORY https://github.com/Cherrytree56567/concurrencpp.git GIT_TAG master)
|
|
FetchContent_MakeAvailable(concurrencpp)
|
|
|
|
add_compile_definitions(NOMINMAX)
|
|
|
|
set(FILES
|
|
src/kernelx.cpp
|
|
src/dllmain.cpp
|
|
src/Hooks.cpp
|
|
src/CurrentApp.cpp
|
|
include/WinDurango.KernelX/CurrentApp.h
|
|
include/WinDurango.KernelX/kernelx.h
|
|
include/WinDurango.KernelX/Logan.h
|
|
include/WinDurango.KernelX/Hooks.h
|
|
)
|
|
|
|
add_library(WinDurango.KernelX SHARED ${FILES} "include/WinDurango.KernelX/EraCoreApplication.h" "src/EraCoreApplication.cpp" "include/WinDurango.KernelX/EraCoreWindow.h" "src/EraCoreWindow.cpp" "include/WinDurango.KernelX/MMDeviceEnumerator.h" "src/MMDeviceEnumerator.cpp")
|
|
|
|
target_link_libraries(WinDurango.KernelX PRIVATE
|
|
WinDurango.Common
|
|
WinDurango.Implementation.WinRT
|
|
concurrencpp::concurrencpp
|
|
"${CMAKE_SOURCE_DIR}/vcpkg_installed/vcpkg/pkgs/detours_x64-windows/lib/detours.lib"
|
|
)
|
|
|
|
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
|
|
${CMAKE_SOURCE_DIR}/vcpkg_installed/vcpkg/pkgs/detours_x64-windows/include/detours
|
|
)
|
|
|
|
target_compile_definitions(WinDurango.KernelX PUBLIC NOMINMAX)
|
|
|
|
set_target_properties(WinDurango.KernelX PROPERTIES
|
|
OUTPUT_NAME "kernelx"
|
|
) |