Skip to content

Commit

Permalink
More idiomatic way of linking OpenGL framework
Browse files Browse the repository at this point in the history
  • Loading branch information
dbeef committed Aug 25, 2024
1 parent 90665cc commit 158e9db
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmake/DependenciesDarwin.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ macro(add_darwin_dependencies)

find_package(SDL2 CONFIG REQUIRED)
find_package(SDL2_mixer REQUIRED)
find_library(OpenGL OpenGL)

add_library(SDL_2_XX INTERFACE)
target_link_libraries(SDL_2_XX INTERFACE
Expand All @@ -17,7 +18,7 @@ macro(add_darwin_dependencies)
)

add_library(Dependencies INTERFACE)
target_link_libraries(Dependencies INTERFACE SDL_2_XX "-framework OpenGL")
target_link_libraries(Dependencies INTERFACE SDL_2_XX ${OpenGL})
target_compile_definitions(Dependencies INTERFACE
SPELUNKY_PSP_PLATFORM_DARWIN
SPELUNKY_PSP_PLATFORM_DESKTOP
Expand Down

0 comments on commit 158e9db

Please sign in to comment.