From 9d9c66adc9dc459cffacc0bd0e2e6f5a97e2bcf4 Mon Sep 17 00:00:00 2001 From: Supakorn 'Jamie' Rassameemasmuang Date: Sun, 31 Dec 2023 14:26:38 -0700 Subject: [PATCH] OPTIONAL: Add Optional backport to build. --- CMakeLists.txt | 1 + backports/optional/CMakeLists.txt | 6 ++++++ cmake-scripts/backport-libs.cmake | 3 +++ 3 files changed, 10 insertions(+) create mode 100644 backports/optional/CMakeLists.txt create mode 100644 cmake-scripts/backport-libs.cmake diff --git a/CMakeLists.txt b/CMakeLists.txt index 91bea2890..2fdf853be 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -20,6 +20,7 @@ endif() build_files_to_src(CORE_BUILD_FILES CORE_SOURCE_FILES) include(cmake-scripts/external-libs.cmake) include(cmake-scripts/thirdparty-impl.cmake) +include(cmake-scripts/backport-libs.cmake) # PRC add_subdirectory(prc/) diff --git a/backports/optional/CMakeLists.txt b/backports/optional/CMakeLists.txt new file mode 100644 index 000000000..bf506918c --- /dev/null +++ b/backports/optional/CMakeLists.txt @@ -0,0 +1,6 @@ +cmake_minimum_required(VERSION 3.26) + +project(OptionalBackport) + +add_library(OptionalBackport INTERFACE) +target_include_directories(OptionalBackport INTERFACE ${CMAKE_CURRENT_LIST_DIR}/include/) \ No newline at end of file diff --git a/cmake-scripts/backport-libs.cmake b/cmake-scripts/backport-libs.cmake new file mode 100644 index 000000000..3aa7391a6 --- /dev/null +++ b/cmake-scripts/backport-libs.cmake @@ -0,0 +1,3 @@ +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/backports/optional) + +list(APPEND ASY_STATIC_LIBARIES OptionalBackport) \ No newline at end of file