mirror of
https://github.com/Neo-Desktop/WindowsXPKg
synced 2025-12-08 19:25:13 +02:00
remove bink generation script
add runtime json parsing add cmake.cpm update cmake to reflect this fix compilation errors ** breaks 2k3 key generation, work in progress
This commit is contained in:
@@ -10,22 +10,22 @@ if (!OPENSSL_FOUND)
|
||||
message(FATAL_ERROR "OpenSSL Development Libraries Not Found")
|
||||
endif()
|
||||
|
||||
# generate bink.h
|
||||
add_custom_command(
|
||||
OUTPUT bink.h
|
||||
COMMAND ${PROJECT_SOURCE_DIR}/convert_keys_to_cpp.py
|
||||
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
|
||||
DEPENDS bink.h
|
||||
)
|
||||
include(cmake/CPM.cmake)
|
||||
|
||||
# include json runtime library
|
||||
CPMAddPackage(
|
||||
NAME nlohmann_json
|
||||
GITHUB_REPOSITORY nlohmann/json
|
||||
VERSION 3.11.2)
|
||||
|
||||
configure_file(keys.json keys.json COPYONLY)
|
||||
|
||||
set(BUILD_SHARED_LIBS OFF)
|
||||
set(CMAKE_EXE_LINKER_FLAGS "-static")
|
||||
ADD_EXECUTABLE(xpkey main.cpp xp.cpp key.cpp util.cpp cli.cpp bink.h)
|
||||
ADD_EXECUTABLE(xpkey main.cpp xp.cpp key.cpp util.cpp cli.cpp)
|
||||
TARGET_INCLUDE_DIRECTORIES(xpkey PUBLIC crypto)
|
||||
TARGET_LINK_LIBRARIES(xpkey PUBLIC crypto)
|
||||
add_dependencies(xpkey bink.h)
|
||||
TARGET_LINK_LIBRARIES(xpkey PUBLIC crypto nlohmann_json::nlohmann_json)
|
||||
|
||||
ADD_EXECUTABLE(srv2003key server.cpp key.cpp util.cpp cli.cpp bink.h)
|
||||
ADD_EXECUTABLE(srv2003key server.cpp key.cpp util.cpp cli.cpp)
|
||||
TARGET_INCLUDE_DIRECTORIES(srv2003key PUBLIC crypto)
|
||||
TARGET_LINK_LIBRARIES(srv2003key PUBLIC crypto)
|
||||
add_dependencies(srv2003key bink.h)
|
||||
TARGET_LINK_LIBRARIES(srv2003key PUBLIC crypto nlohmann_json::nlohmann_json)
|
||||
Reference in New Issue
Block a user