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 2141

Summary: testfilesystem fails to link on Mac
Product: SDL Reporter: Joseph Carter <tjcarter>
Component: fileAssignee: Sam Lantinga <slouken>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2    
Version: HG 2.1   
Hardware: x86_64   
OS: Mac OS X 10.8   

Description Joseph Carter 2013-10-08 21:15:44 UTC
I just ran make in my tests dir and got:

$ make
gcc -o testfilesystem testfilesystem.c -g -O2 -D_THREAD_SAFE -I/opt/local/include/SDL2  -I -DHAVE_OPENGL -DHAVE_SDL_TTF -L/opt/local/lib -lSDL2  -lSDL2_test
Undefined symbols for architecture x86_64:
  "_SDL_GetBasePath", referenced from:
      _main in ccfXfB0A.o
  "_SDL_GetPrefPath", referenced from:
      _main in ccfXfB0A.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make: *** [testfilesystem] Error 1

I see that these functions are defined in src/filesystem/cocoa/SDL_sysfilesystem.m and I can see that the objects compiled therefrom do contain the strings.

Calling convention issue maybe?
Comment 1 Joseph Carter 2013-10-09 18:17:31 UTC
MacPorts was overriding my locally installed SDL and apparently the ABI has changed a bit in hg tip…