FS#57790 - [sdl2] CMake producing "wrong" variable names
Attached to Project:
Arch Linux
Opened by Lucas Mota (lucasm0ta) - Sunday, 11 March 2018, 18:23 GMT
Last edited by Sven-Hendrik Haase (Svenstaro) - Thursday, 22 March 2018, 10:54 GMT
Opened by Lucas Mota (lucasm0ta) - Sunday, 11 March 2018, 18:23 GMT
Last edited by Sven-Hendrik Haase (Svenstaro) - Thursday, 22 March 2018, 10:54 GMT
|
Details
Description:
Hello, Trying to follow some tutorials online I found that most used the CMake variable ${SDL2_INCLUDE_DIR}, when using this package, this variable is always null. Looking more inside usr/lib/cmake/SDL2/sdl2-config.cmake I found that only the ${SDL2_INCLUDE_DIRS} is created (with an S on the end). Not sure why the difference regarding how is handled in other package management systems but following in the CMake doc about how importing SDL (https://cmake.org/cmake/help/v3.0/module/FindSDL.html) fixing this would be nice. |
This task depends upon
Closed by Sven-Hendrik Haase (Svenstaro)
Thursday, 22 March 2018, 10:54 GMT
Reason for closing: Upstream
Thursday, 22 March 2018, 10:54 GMT
Reason for closing: Upstream
Comment by Antonio Rojas (arojas) -
Sunday, 11 March 2018, 23:18 GMT
Comment by
Sven-Hendrik Haase (Svenstaro) -
Wednesday, 21 March 2018, 21:00 GMT
Comment by Antonio Rojas (arojas) -
Wednesday, 21 March 2018, 21:30 GMT
Comment by
Sven-Hendrik Haase (Svenstaro) -
Thursday, 22 March 2018, 10:54 GMT
You're mixing up FindSDL.cmake (provided by cmake) and
sdl2-config.cmake (provided by sdl2). The problem is that the
latter has priority over the former - it should probably be
removed now that cmake ships its own module.
I don't see how our cmake has any stuff specifically for sdl2 and
I don't see a conflict. Can anybody point me at the right place?
Right, the cmake module is for SDL1, my mistake. So I'm not sure
what the issue is here, or whether there is an issue at all.
If anything, this is a bug in the tutorials or sdl2 upstream. The
package doesn't do anything weird CMake-related.