feat: better cmake support (#21)
* feat: CMakeSettings.json * chore: remove visual studio stuff chore: move .clang-format to main directory * feat: new file structure, easier to implement as a submodule within existing projects * chore: we actually include some code now... * chore: remove prebuilt libraries (oops) * feat: new shader building script using cmake * chore: add debug postfix specifier * fix: forgot that windows builds use 4J_Render_PC for the render library * fix: didn't add the output directory (where shaders are saved to) to the include directories of 4J_Render
This commit is contained in:
+18
-2
@@ -2,5 +2,21 @@ cmake_minimum_required(VERSION 3.25 FATAL_ERROR)
|
||||
|
||||
project(4JLibs LANGUAGES CXX)
|
||||
|
||||
# TODO: target selection?
|
||||
add_subdirectory(Windows_Libs/Dev)
|
||||
add_library(4JLibs.Globals INTERFACE)
|
||||
|
||||
target_include_directories(4JLibs.Globals INTERFACE
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/inc
|
||||
)
|
||||
|
||||
set(CMAKE_DEBUG_POSTFIX "_d")
|
||||
|
||||
# msvc specific flags
|
||||
if(MSVC)
|
||||
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>")
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
add_subdirectory(impls/Windows_Libs)
|
||||
else()
|
||||
message(FATAL_ERROR "Unsupported platform.")
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user