Dawn/lib/CMakeLists.txt
2024-09-25 15:01:26 -04:00

37 lines
1000 B
CMake

# Copyright (c) 2021 Dominic Msters
#
# This software is released under the MIT License.
# https://opensource.org/licenses/MIT
include(FetchContent)
# add_subdirectory(glm)
FetchContent_Declare(
glm
GIT_REPOSITORY https://github.com/g-truc/glm.git
GIT_TAG bf71a834948186f4097caa076cd2663c69a10e1e
)
FetchContent_MakeAvailable(glm)
if(DAWN_TARGET STREQUAL "linux-x64-glfw")
add_subdirectory(glad)
add_subdirectory(glfw)
add_subdirectory(libarchive)
add_subdirectory(freetype)
else()
message(FATAL_ERROR "Unknown target: ${DAWN_TARGET}")
endif()
# JSON
FetchContent_Declare(json URL https://github.com/nlohmann/json/releases/download/v3.11.3/json.tar.xz)
FetchContent_MakeAvailable(json)
# if(DAWN_TARGET_OPENAL)
# set(LIBTYPE "STATIC")
# add_subdirectory(openal-soft)
# set(BUILD_TESTS OFF CACHE BOOL "Build tests" FORCE)
# set(BUILD_EXAMPLES OFF CACHE BOOL "Build examples" FORCE)
# add_subdirectory(AudioFile)
# endif()