mirror of https://github.com/WerWolv/ImHex.git
36 lines
1.0 KiB
CMake
36 lines
1.0 KiB
CMake
cmake_minimum_required(VERSION 3.16)
|
|
project(libimhex)
|
|
|
|
set(CMAKE_CXX_STANDARD 20)
|
|
|
|
add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../../external/ImGui ${CMAKE_CURRENT_BINARY_DIR}/external/ImGui)
|
|
add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../../external/nlohmann_json ${CMAKE_CURRENT_BINARY_DIR}/external/nlohmann_json)
|
|
|
|
|
|
if (WIN32)
|
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -static-libstdc++ -static-libgcc")
|
|
endif()
|
|
|
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC")
|
|
|
|
add_library(libimhex SHARED
|
|
source/helpers/event.cpp
|
|
source/helpers/utils.cpp
|
|
source/helpers/content_registry.cpp
|
|
source/helpers/shared_data.cpp
|
|
|
|
source/lang/preprocessor.cpp
|
|
source/lang/lexer.cpp
|
|
source/lang/parser.cpp
|
|
source/lang/validator.cpp
|
|
source/lang/evaluator.cpp
|
|
source/lang/builtin_functions.cpp
|
|
|
|
source/providers/provider.cpp
|
|
|
|
source/views/view.cpp
|
|
)
|
|
|
|
target_include_directories(libimhex PUBLIC include)
|
|
target_link_libraries(libimhex PUBLIC imgui nlohmann_json)
|