mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-23 22:37:55 +02:00
initial iOS support to fix building
tested with Xcode and Unix Makefiles
This commit is contained in:
@@ -273,7 +273,7 @@ if(SDL2_LIBRARY)
|
||||
# I think it has something to do with the CACHE STRING.
|
||||
# So I use a temporary variable until the end so I can set the
|
||||
# "real" variable in one-shot.
|
||||
if(APPLE)
|
||||
if(APPLE_MACOS)
|
||||
set(SDL2_LIBRARIES ${SDL2_LIBRARIES} -framework Cocoa)
|
||||
endif()
|
||||
|
||||
@@ -342,8 +342,10 @@ if(SDL2_FOUND)
|
||||
if(APPLE)
|
||||
# For OS X, SDL2 uses Cocoa as a backend so it must link to Cocoa.
|
||||
# For more details, please see above.
|
||||
set_property(TARGET SDL2::SDL2 APPEND PROPERTY
|
||||
INTERFACE_LINK_OPTIONS -framework Cocoa)
|
||||
if (APPLE_MACOS)
|
||||
set_property(TARGET SDL2::SDL2 APPEND PROPERTY
|
||||
INTERFACE_LINK_OPTIONS -framework Cocoa)
|
||||
endif()
|
||||
else()
|
||||
# For threads, as mentioned Apple doesn't need this.
|
||||
# For more details, please see above.
|
||||
|
||||
Reference in New Issue
Block a user