mirror of
https://github.com/chiteroman/PlayIntegrityFix.git
synced 2025-01-18 19:12:38 +02:00
Refactor CMake
This commit is contained in:
parent
32270b2a9c
commit
f3c2e39438
@ -1,15 +1,37 @@
|
|||||||
cmake_minimum_required(VERSION 3.22.1)
|
cmake_minimum_required(VERSION 3.22.1)
|
||||||
|
|
||||||
project("playintegrityfix")
|
project("playintegrityfix")
|
||||||
|
|
||||||
find_package(cxx REQUIRED CONFIG)
|
find_package(cxx REQUIRED CONFIG)
|
||||||
|
|
||||||
link_libraries(cxx::cxx)
|
if (${ANDROID_ABI} STREQUAL "arm64-v8a")
|
||||||
|
set(ARCH "arm64")
|
||||||
add_library(${CMAKE_PROJECT_NAME} SHARED main.cpp cJSON/cJSON.c)
|
elseif (${ANDROID_ABI} STREQUAL "armeabi-v7a")
|
||||||
|
set(ARCH "arm")
|
||||||
target_include_directories(${CMAKE_PROJECT_NAME} PRIVATE cJSON)
|
endif ()
|
||||||
|
|
||||||
target_link_libraries(${CMAKE_PROJECT_NAME} PRIVATE log dobby_static)
|
file(GLOB SHADOWHOOK_SRC
|
||||||
|
shadowhook/*.c
|
||||||
add_subdirectory(Dobby)
|
shadowhook/arch/${ARCH}/*.c
|
||||||
|
shadowhook/common/*.c
|
||||||
|
shadowhook/third_party/xdl/*.c
|
||||||
|
)
|
||||||
|
|
||||||
|
add_library(${CMAKE_PROJECT_NAME} SHARED
|
||||||
|
main.cpp
|
||||||
|
cJSON/cJSON.c
|
||||||
|
${SHADOWHOOK_SRC}
|
||||||
|
)
|
||||||
|
|
||||||
|
target_include_directories(${CMAKE_PROJECT_NAME} PRIVATE
|
||||||
|
cJSON
|
||||||
|
shadowhook/shadowhook/src/main/cpp
|
||||||
|
shadowhook/arch/${ARCH}
|
||||||
|
shadowhook/include
|
||||||
|
shadowhook/common
|
||||||
|
shadowhook/third_party/bsd
|
||||||
|
shadowhook/third_party/lss
|
||||||
|
shadowhook/third_party/xdl
|
||||||
|
)
|
||||||
|
|
||||||
|
target_link_libraries(${CMAKE_PROJECT_NAME} PRIVATE log cxx::cxx)
|
||||||
|
Loading…
Reference in New Issue
Block a user