SDL2 Patch: Pthread naming disable configure option

For review: Bug # 1629 ( http://bugzilla.libsdl.org/show_bug.cgi?id=1629 )

This simple patch adds a --enable-pthread-naming option (default on)
which allows disabling of the use of pthread_setname_np when compiling
against glibc 2.12 or newer on linux, thus allowing the SDL 2 library to
NOT require 2.12 as a minimum glibc requirement.–
Edward Rudd
OutOfOrder.cc
Skype: outoforder_cc
317-674-3296

This simple patch adds a --enable-pthread-naming option

How about we check for the function at runtime instead?

–ryan.

That’s a great idea! :)On Sat, Nov 3, 2012 at 8:07 AM, Ryan C. Gordon wrote:

This simple patch adds a --enable-pthread-naming option

How about we check for the function at runtime instead?

–ryan.


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

That’s a great idea! :slight_smile:

Done: http://hg.libsdl.org/SDL/rev/44a2e00e7c66

Edward, does this cover your concerns? I’ll close the bug if we’re good
here.

–ryan.

Looks great, thanks Ryan! :)On Sat, Nov 3, 2012 at 9:08 AM, Ryan C. Gordon wrote:

That’s a great idea! :slight_smile:

Done: http://hg.libsdl.org/SDL/rev/**44a2e00e7c66http://hg.libsdl.org/SDL/rev/44a2e00e7c66

Edward, does this cover your concerns? I’ll close the bug if we’re good
here.

–ryan.

_____________**
SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/**listinfo.cgi/sdl-libsdl.orghttp://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Question: Does Apple allow the use of dlsym on the App Store, i.e.
have apps been approved? (I don’t know the answer and I honestly want
to know.)

I know dlsym is not dlopen, but this being Apple and their irrational
review process (anybody remember the no-underscores rejection for the
embedded SDL.framework CFBundleIdentifier in the Mac App Store review
process?), I have been wondering if this gets caught in their net or
not. (I really want to use dlsym for LuaCocoa on iOS.)

Thanks,
EricOn 11/3/12, Ryan C. Gordon wrote:

That’s a great idea! :slight_smile:

Done: http://hg.libsdl.org/SDL/rev/44a2e00e7c66

Edward, does this cover your concerns? I’ll close the bug if we’re good
here.

–ryan.


Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/

Question: Does Apple allow the use of dlsym on the App Store, i.e.
have apps been approved? (I don’t know the answer and I honestly want
to know.)

That’s a good question, I don’t know. For SDL’s use, we can probably use
a weak reference on Mac/iOS instead of dlsym.

–ryan.

Apple’s main restriction is against calling un-documented APIs… and pthread_set_name_np isn’t an undocumented API, just one only available in newer OSes. (np == non-portable). So, IMHO, and from my understandings of Apple’s restrictions it should be ok.On Nov 3, 2012, at 15:50 , Eric Wing wrote:

On 11/3/12, Ryan C. Gordon wrote:

That’s a great idea! :slight_smile:

Done: http://hg.libsdl.org/SDL/rev/44a2e00e7c66

Edward, does this cover your concerns? I’ll close the bug if we’re good
here.

–ryan.

Question: Does Apple allow the use of dlsym on the App Store, i.e.
have apps been approved? (I don’t know the answer and I honestly want
to know.)

I know dlsym is not dlopen, but this being Apple and their irrational
review process (anybody remember the no-underscores rejection for the
embedded SDL.framework CFBundleIdentifier in the Mac App Store review
process?), I have been wondering if this gets caught in their net or
not. (I really want to use dlsym for LuaCocoa on iOS.)

Thanks,
Eric

Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Edward Rudd
OutOfOrder.cc
Skype: outoforder_cc
317-674-3296

Yes this should cover the concerns… And actually Sam and I had bounced back and forth on the bug itself to do this exact thing, you just got to it before me.

I shall test this on my linux boxen here to ensure it works as expected and resolve the bug if it works.On Nov 3, 2012, at 12:08 , Ryan C. Gordon wrote:

That’s a great idea! :slight_smile:

Done: http://hg.libsdl.org/SDL/rev/44a2e00e7c66

Edward, does this cover your concerns? I’ll close the bug if we’re good here.

–ryan.


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Edward Rudd
OutOfOrder.cc
Skype: outoforder_cc
317-674-3296

That’s a great idea! :slight_smile:

Done: http://hg.libsdl.org/SDL/rev/44a2e00e7c66

Edward, does this cover your concerns? I’ll close the bug if we’re good here.

Sweet, Ryan… that did the trick.

Edward Rudd
OutOfOrder.cc
Skype: outoforder_cc
317-674-3296On Nov 3, 2012, at 12:08 , Ryan C. Gordon wrote: