Build sfml-main with position-independent code

This commit is contained in:
Chris Thrasher 2023-02-06 15:21:43 -07:00
parent 8a307df494
commit 04483c58d9

View File

@ -17,6 +17,9 @@ endif()
sfml_add_library(sfml-main STATIC SOURCES ${SRC})
if(SFML_OS_ANDROID)
# ensure that linking into shared libraries doesn't fail
set_target_properties(sfml-main PROPERTIES POSITION_INDEPENDENT_CODE ON)
# glad sources
target_include_directories(sfml-main SYSTEM PRIVATE "${PROJECT_SOURCE_DIR}/extlibs/headers/glad/include")
endif()