Skip to content

Commit

Permalink
cmake: For SDL, disable rlgl_standalone
Browse files Browse the repository at this point in the history
  • Loading branch information
RobLoach committed Mar 7, 2024
1 parent 3060408 commit b9ba864
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions examples/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ elseif ("${PLATFORM}" STREQUAL "DRM")
list(REMOVE_ITEM example_sources ${CMAKE_CURRENT_SOURCE_DIR}/others/rlgl_standalone.c)
list(REMOVE_ITEM example_sources ${CMAKE_CURRENT_SOURCE_DIR}/others/raylib_opengl_interop.c)

elseif ("${PLATFORM}" STREQUAL "SDL")
list(REMOVE_ITEM example_sources ${CMAKE_CURRENT_SOURCE_DIR}/others/rlgl_standalone.c)

endif ()

include_directories(BEFORE SYSTEM others/external/include)
Expand Down Expand Up @@ -145,11 +148,5 @@ foreach (example_source ${example_sources})
endif ()
endforeach ()

# For SDL, have rlgl_standalone link the glfw dependency.
if ("${PLATFORM}" STREQUAL "SDL")
find_package(glfw3 3.3 REQUIRED)
target_link_libraries(rlgl_standalone glfw)
endif()

# Copy all of the resource files to the destination
file(COPY ${example_resources} DESTINATION "resources/")

0 comments on commit b9ba864

Please sign in to comment.