Commit 911cc554 authored by Florian Oetke's avatar Florian Oetke
Browse files

added special case for different SDL-include dir with some find-scripts/distributions

parent 24410563
......@@ -38,6 +38,9 @@ if(MIRRAGE_PREFER_SYSTEM_SDL)
add_library(mirrage::deps::SDL2 ALIAS SDL2::SDL2)
add_library(mirrage::deps::SDL2main ALIAS SDL2::SDL2main)
else()
if(NOT EXISTS ${SDL2_INCLUDE_DIR}/SDL.h)
set(SDL2_INCLUDE_DIR ${SDL2_INCLUDE_DIR}/SDL2)
endif()
add_library(mirrage::deps::SDL2 INTERFACE IMPORTED GLOBAL)
set_property(TARGET mirrage::deps::SDL2 PROPERTY INTERFACE_LINK_LIBRARIES ${SDL2_LIBRARY})
set_property(TARGET mirrage::deps::SDL2 PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${SDL2_INCLUDE_DIR})
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment