You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Reported in version: HG 2.0 Reported for operating system, platform: Linux, x86_64
Comments on the original bug report:
On 2018-04-08 10:10:53 +0000, wrote:
Created attachment 3216
Test program
When building SDL2 using the CMake build system, the generated SDL2Targets.cmake file sets the include path to ${_IMPORT_PREFIX}/include instead of ${_IMPORT_PREFIX}/include/SDL2.
This causes applications using the following in their CMakeLists.txt to detect and include SDL2 to fail building:
Also applications have been doing #include "SDL.h" for years, it seems a bit harsh breaking their build when distributions decide to switch SDL2 from autotools to CMake (which is what happened with ArchLinux recently, and the reason I am opening this bug).
On 2018-04-10 21:52:39 +0000, Sam Lantinga wrote:
Whoops, you're right, my mistake.
On 2018-04-10 21:54:50 +0000, Sam Lantinga wrote:
I don't use CMake myself, and I don't see where this is configured in the SDL source files. Can you attach a patch you've tested there?
Created attachment 4218
Allow both types of #include
It would be useful to be able to do either #include "SDL2/SDL.h" or #include "SDL.h". This patch allows that and adds compatibility with other build systems. It also allows differentiating between SDL1 and SDL2.
This bug report was migrated from our old Bugzilla tracker.
These attachments are available in the static archive:
Reported in version: HG 2.0
Reported for operating system, platform: Linux, x86_64
Comments on the original bug report:
On 2018-04-08 10:10:53 +0000, wrote:
On 2018-04-10 15:05:44 +0000, Sam Lantinga wrote:
On 2018-04-10 16:37:31 +0000, wrote:
On 2018-04-10 21:52:39 +0000, Sam Lantinga wrote:
On 2018-04-10 21:54:50 +0000, Sam Lantinga wrote:
On 2018-04-11 04:22:24 +0000, wrote:
On 2018-04-12 00:18:58 +0000, Sam Lantinga wrote:
On 2020-02-16 02:57:14 +0000, Mohamed wrote:
On 2020-02-16 08:08:54 +0000, Sam Lantinga wrote:
The text was updated successfully, but these errors were encountered: