The libSDL authors provide an x86_64 DLL and import library on their download page. The .zip (also containing 32-bit versions) can be found at http://www.libsdl.org/release/SDL-devel-1.2.15-VC.zip
I can build x64 executables with Visual Studio 2010 using the .lib and .dll they provide, and they work properly. However doing the same with mingw-w64 creates a non-working executable: it crashes at the first call in the DLL because the address generated at link time doesn't match the address of the function in the DLL.
However, rebuilding libSDL using mingw-64 and using the resulting .lib (still with the .dll provided by the SDL team) results in properly working executables.
I am attaching a tarball with the following elements:
- the upstream SDL.dll
- the upstream SDL.lib
- the SDL.lib I built with mingw-w64
- a tiny C++ program that calls SDL_getenv() then returns immediately
- a Makefile to build the above