optionally use freetype and plutosvg for color fonts

This commit is contained in:
Green Sky
2025-03-15 00:27:59 +01:00
parent 74f2de81e8
commit 7ef29c9f04
7 changed files with 96 additions and 1 deletions

16
external/plutosvg/CMakeLists.txt vendored Normal file
View File

@ -0,0 +1,16 @@
cmake_minimum_required(VERSION 3.24 FATAL_ERROR)
include(FetchContent)
#makes no sense without freetype
if (NOT TARGET plutosvg::plutosvg AND TARGET Freetype::Freetype)
set(PLUTOSVG_ENABLE_FREETYPE ON CACHE INTERNAL "")
set(PLUTOSVG_BUILD_EXAMPLES OFF CACHE INTERNAL "")
FetchContent_Declare(plutosvg
GIT_REPOSITORY https://github.com/sammycage/plutosvg.git
GIT_TAG v0.0.6
FIND_PACKAGE_ARGS # for the future
)
FetchContent_MakeAvailable(plutosvg)
endif()