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 4160

Summary: SDL_image does not compile as a static library on macOS (easy fix included)
Product: SDL_image Reporter: Pauli Jokela <pauli.jokela>
Component: miscAssignee: Sam Lantinga <slouken>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: blocker    
Priority: P2    
Version: unspecified   
Hardware: x86_64   
OS: Mac OS X (All)   
Attachments: Screenshot of IMG_svg.c not being included with the Static Library target.

Description Pauli Jokela 2018-05-08 12:51:55 UTC
Created attachment 3242 [details]
Screenshot of IMG_svg.c not being included with the Static Library target.

The Xcode project for SDL_image does NOT include IMG_svg.c with static library builds, but DOES include every other file. This is very likely done by accident, and nobody’s noticed it, until now.

The fix is to simply toggle the IMG_svg.c file to be a part of the Static Library target, otherwise it's simply not included with the binary, resulting in compilation errors when including/calling the library from another project.

Attached is a screenshot of the issue (box not ticked).

More information is also available here: https://discourse.libsdl.org/t/cant-build-sdl-image-after-svg-support-was-added/24377
Comment 1 Sam Lantinga 2018-05-09 03:45:24 UTC
Fixed, thanks!
https://hg.libsdl.org/SDL_image/rev/887b1e03cad1