libsdl-org / setup-sdl

GitHub action for providing SDL.
The Unlicense
26 stars 3 forks source link

Issue on Windows & MacOS: SDL2 isn't actually installed into anywhere CMake can find it #24

Closed ProjectHSI closed 10 months ago

ProjectHSI commented 10 months ago

Not tied into the Linux error.

The action succeeds and lets the workflow continue, but configuring CMake causes a generic error about CMake not being able to find SDL2Config.cmake.

madebr commented 10 months ago

This action sets SDL2_ROOT environment variables which CMake should pick up.

Does this faq help? https://github.com/libsdl-org/setup-sdl#faq It has a few suggestions for older CMake versions (or scripts that use an older cmake_minimum_required)

When your project uses a custom FindSDL2.cmake, you might have to pass additional CMake arguments.

I test setup-sdl with this repo: https://github.com/madebr/setup-sdl-test (Building SDL satellite libraries is not fully supported yet)

ProjectHSI commented 10 months ago

Hi there; sorry for the late reply. I'm bumping the CMake minimum required version as for some reason default CMake projects in VS 2022 use a min version of 3.8... No idea why.

ProjectHSI commented 10 months ago

That fixed it, thanks.

ProjectHSI commented 10 months ago

(closed as not planned due to it being an issue with my end, not setup-sdl.)