Skip to content

Commit

Permalink
FindSDL2: Also add include directories to fix build on Raspberry systems
Browse files Browse the repository at this point in the history
Discussed in EasyRPG#2719
  • Loading branch information
Ghabry committed Apr 10, 2022
1 parent 01aa217 commit b2c0fea
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion builds/cmake/Modules/FindSDL2.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,10 @@ if(SDL2_FOUND)
# Remove -lSDL2 -lSDL2main from the pkg-config linker line,
# to prevent linking against the system library
list(REMOVE_ITEM SDL2PC_STATIC_LIBRARIES SDL2main SDL2)
set_property(TARGET SDL2::SDL2 APPEND_STRING PROPERTY
set_property(TARGET SDL2::SDL2 APPEND PROPERTY
INTERFACE_LINK_LIBRARIES "${SDL2PC_STATIC_LIBRARIES}")
set_property(TARGET SDL2::SDL2 APPEND PROPERTY
INTERFACE_INCLUDE_DIRECTORIES "${SDL2PC_STATIC_LIBRARY_DIRS}")
endif()
endif()
mark_as_advanced(SDL2_ROOT_DIR)
Expand Down

0 comments on commit b2c0fea

Please sign in to comment.