We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 4817 - Static Library with CMake Broken
Summary: Static Library with CMake Broken
Status: ASSIGNED
Alias: None
Product: SDL
Classification: Unclassified
Component: *don't know* (show other bugs)
Version: 2.0.10
Hardware: x86_64 Windows 10
: P2 major
Assignee: Ryan C. Gordon
QA Contact: Sam Lantinga
URL:
Keywords: target-2.0.16
Depends on:
Blocks:
 
Reported: 2019-10-07 06:30 UTC by Ryan Edward
Modified: 2020-07-16 18:29 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ryan Edward 2019-10-07 06:30:21 UTC
Hi there,
I’m on windows 10, using clang + mingw.
I recently attempted to update to sdl2.0.10. I invoke the following command:

cmake.exe -DCMAKE_BUILD_TYPE=Debug -G "MinGW Makefiles"^
        -DCMAKE_C_FLAGS="-target x86_64-windows-gnu"^
        -DCMAKE_C_COMPILER_ID="Clang" -DCMAKE_C_COMPILER="clang.exe"^
        -DCMAKE_CXX_FLAGS="-target x86_64-windows-gnu"^
        -DCMAKE_CXX_COMPILER_ID="Clang++" -DCMAKE_CXX_COMPILER="clang++.exe"^
        -DDIRECTX=OFF -DSDL_TEST=OFF -DSDL_SHARED=OFF -DSDL_STATIC=ON ..

cmake.exe --build . -- -j %NUMBER_OF_PROCESSORS%

This produces un-usable ‘.lib’ files, specifically SDL2maind.lib and SDL2d.lib. Performing the same invocation on sdl2.0.9 gives usable ‘.a’ files, specifically libSDL2maind.a and libSDL2d.a. If this is a problem, could someone give me a link to an archived sdl2.0.9 source?

Thanks.