Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: use cmake's builtin FindSDL #1027

Draft
wants to merge 1 commit into
base: vanilla
Choose a base branch
from

Conversation

xiaoxiangmoe
Copy link
Contributor

@xiaoxiangmoe xiaoxiangmoe commented Feb 1, 2025

FindSDL2.cmake is added in cmake 3.19.

Current version ./cmake/FindSDL2.cmake has some bug that can't use it in nixos. We should use cmake builtin version FindSDL instead.

@xiaoxiangmoe
Copy link
Contributor Author

@OmniBlade Can you help me to fix this windows ci bug? I don't have windows pc now.

@OmniBlade
Copy link
Contributor

Unfortunately that is only a find module for SDL, not SDL2 which has never had an official find module in CMake. The reason it works on Linux is because SDL2 now ships with appropriate files of its own which on Linux get installed in a standard location CMake knows to look in. This isn't true on Windows hence the failure on the CI there.

The options are either 1. Write/update the find module to better work with Nix or 2. Point CMake to the correct location on a Windows install (and potentially also macOS) to look for the CMake info find_package searches for.

@xiaoxiangmoe xiaoxiangmoe marked this pull request as draft February 2, 2025 03:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants