| Summary: | sdl2-config.cmake uses incorrect shared library suffix on macOS | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Joshua Root <josh+sdl> |
| Component: | build | Assignee: | alexander.grund |
| Status: | RESOLVED FIXED | QA Contact: | Sam Lantinga <slouken> |
| Severity: | major | ||
| Priority: | P2 | CC: | alexander.grund, spydog |
| Version: | HG 2.0 | ||
| Hardware: | x86 | ||
| OS: | Mac OS X (All) | ||
| Attachments: | Proposed patch | ||
|
Description
Joshua Root
2020-03-17 02:22:56 UTC
Will add a patch soon. Testing ATM Created attachment 4263 [details]
Proposed patch
This should fix the issue. I verified it doesn't break on Linux using the shared and static targets SDL2::SDL2 and SDL2::SDL2-static
(Very) basic example CML:
cmake_minimum_required(VERSION 3.1)
project(main)
add_executable(${PROJECT_NAME} main.cpp)
find_package(SDL2 2.0.12 REQUIRED)
target_link_libraries(${PROJECT_NAME} SDL2::SDL2)
Ran into this bug earlier today when building FAudio. Just wanted to additionally confirm that this patch solves the issue. Thanks for writing this fix, alexander.grund! Patch added, thanks! https://hg.libsdl.org/SDL/rev/60f1e9fb5957 |