SDL2's symbols get re-rexported by application binary?

I built static libraries of SDL2 version 2.0.10 on Windows 64 with VisualStudio 2019.

I link my game against it, by adding linker inputs: SDL2.lib and SDLMain.lib

This works just fine; SDL2 works as expected.

But there is this weird unexpected thing that popped up: My binary ends up with an export-table and exports all the SDL2 symbols.

Normally, I would not expect a .exe file to export symbols.
Also, I link against other static libraries, and only the SDL2 library’s symbols leak into the .exe binary’s symbol table.

Am I doing something wrong? Or does SDL2 do something special to have the exports transfer into the binary exports?

Lastly, I would like to note that this export-table has a very suspect timestamp, from the year 2106.

Do other people see exported SDL2 symbols in the application binary?

See the comments at the top of src/dynapi/SDL_dynapi.h. You can turn it off, but you have to edit that file and recompile the libraries.

1 Like