feat(solver-bootstrap): step 1 — cmake-project-scaffold

This commit is contained in:
KOKO\Mimi
2026-07-30 00:46:22 +09:00
parent 4157ba2ff7
commit fc5493bd59
9 changed files with 187 additions and 0 deletions
+51
View File
@@ -0,0 +1,51 @@
cmake_minimum_required(VERSION 3.30)
project(FESA VERSION 0.1.0 LANGUAGES CXX)
if(NOT MSVC)
message(FATAL_ERROR "FESA requires the Microsoft Visual C++ compiler (MSVC v145).")
endif()
if(NOT CMAKE_VS_PLATFORM_TOOLSET STREQUAL "v145")
message(
FATAL_ERROR
"FESA requires the v145 platform toolset; configured toolset is "
"'${CMAKE_VS_PLATFORM_TOOLSET}'."
)
endif()
if(NOT CMAKE_GENERATOR_PLATFORM STREQUAL "x64")
message(FATAL_ERROR "FESA requires the x64 generator platform.")
endif()
if(NOT CMAKE_SIZEOF_VOID_P EQUAL 8)
message(FATAL_ERROR "FESA requires a 64-bit target.")
endif()
include(cmake/FesaDependencies.cmake)
add_library(fesa_core STATIC
src/fesa/core/version.cpp
)
target_include_directories(fesa_core
PUBLIC
"${CMAKE_CURRENT_SOURCE_DIR}/include"
)
target_compile_features(fesa_core PUBLIC cxx_std_20)
target_compile_options(fesa_core PRIVATE /W4 /permissive- /EHsc)
add_executable(fesa
src/fesa/cli/main.cpp
)
target_link_libraries(fesa PRIVATE fesa_core)
target_compile_features(fesa PRIVATE cxx_std_20)
target_compile_options(fesa PRIVATE /W4 /permissive- /EHsc)
include(CTest)
if(BUILD_TESTING)
add_subdirectory(tests)
endif()