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 2812

Summary: [patch] Make libSDL2main.a usable on Android via a dummy symbol
Product: SDL Reporter: Jonas Kulla <ancurio_bugzilla>
Component: mainAssignee: Gabriel Jacobo <gabomdq>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: enhancement    
Priority: P2 CC: icculus
Version: HG 2.1   
Hardware: All   
OS: Android (All)   
Attachments: patch
patch

Description Jonas Kulla 2014-12-10 10:54:12 UTC
Created attachment 1963 [details]
patch

This eliminates the need to manually compile in SDL_main_android.c.
Instead, add "-lSDL2main -Wl,-u,SDL_main_dummy" when linking.

I don't know how the nkd-build process works, but unless it was
for some reason linking libSDL2main.a it should be unaffected.
Comment 1 Jonas Kulla 2014-12-10 12:07:44 UTC
Created attachment 1964 [details]
patch

Remove superfluous initialization.
Comment 2 Ryan C. Gordon 2015-02-19 04:21:53 UTC
Tossing this bug to Gabriel for review.

--ryan.
Comment 3 Ryan C. Gordon 2015-02-19 05:22:18 UTC
Marking a large number of bugs with the "triage-2.0.4" keyword at once. Sorry if you got a lot of email from this. This is to help me sort through some bugs in regards to a 2.0.4 release. We may or may not fix this bug for 2.0.4, though!
Comment 4 Sam Lantinga 2017-08-14 01:12:22 UTC
Patch added, thanks!
https://hg.libsdl.org/SDL/rev/f85618f8ba81