add a lib for rendering text in sdl2 and rules to make in makefile

This commit is contained in:
2026-01-21 14:45:11 -06:00
parent f3c0aafe2f
commit e7d9c013f4
1754 changed files with 850297 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
# FIXME: this should be provided by SDL2
include(FindPackageHandleStandardArgs)
include("${CMAKE_CURRENT_LIST_DIR}/CommonFindSDL2.cmake")
find_library(SDL2_MAIN_LIBRARY
NAMES SDL2main
HINTS ${SDL2_DIR} ENV SDL2_DIR
PATH_SUFFIXES ${_lib_suffixes}
)
find_package_handle_standard_args(SDL2main
REQUIRED_VARS SDL2_MAIN_LIBRARY
)
if(SDL2main_FOUND)
if(NOT TARGET SDL2::SDL2main)
add_library(SDL2::SDL2main UNKNOWN IMPORTED)
set_target_properties(SDL2::SDL2main PROPERTIES
IMPORTED_LINK_INTERFACE_LANGUAGES "C"
IMPORTED_LOCATION "${SDL2_MAIN_LIBRARY}"
)
endif()
endif()