Errors when compiling x64 of SDL 1.3

Hello

I’ve used 1.2 in the past and had no problems compiling it to x64 with VS.

Doing the exact same with 1.3 doesnt seem to work good though.

Here’s the logfile.
http://walen.se/temp/BuildLog.htm

Any ideas?

I’m going to have a guess that you may need to re-enable HAVE_LIBC in the
SDL_config_win32.h file. Win64 does not support any of the code in the
SDL_stdlib.c file so I can only suspect it was not included in the past for
Win64 compilation. I’m affraid I don’t have win64 on this laptop to give it
a shot.

Good luck.

walfridson wrote:>

Hello

I’ve used 1.2 in the past and had no problems compiling it to x64 with VS.

Doing the exact same with 1.3 doesnt seem to work good though.

Here’s the logfile.
http://walen.se/temp/BuildLog.htm

Any ideas?


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


View this message in context: http://www.nabble.com/Errors-when-compiling-x64-of-SDL-1.3-tp24979108p24984270.html
Sent from the SDL mailing list archive at Nabble.com.

Correct, there are a couple steps that need to be taken revolving around
HAVE_LIBC

First, duplicate the x86 configuration to x64,
In project properties, under C/C++ -> Preprocessor, you must remove
"MMX;3dNOW;SSE;SSE2" and add "_WIN64;HAVE_LIBC"
Under Linker -> Input you must set “Ignore All Default Libraries” to "No"
and under Linker -> Command Line, you must remove “/MACHINE:I386” from
Additional Options.

That should make everything compile in VS2008 with the DXSDK installed.

–William

GMScribe wrote:> I’m going to have a guess that you may need to re-enable HAVE_LIBC in the

SDL_config_win32.h file. Win64 does not support any of the code in the
SDL_stdlib.c file so I can only suspect it was not included in the past for
Win64 compilation. I’m affraid I don’t have win64 on this laptop to give it
a shot.

Good luck.

walfridson wrote:

Hello

I’ve used 1.2 in the past and had no problems compiling it to x64 with VS.

Doing the exact same with 1.3 doesnt seem to work good though.

Here’s the logfile.
http://walen.se/temp/BuildLog.htm

Any ideas?


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

Hi,

Try turning off the assembly (optimization for specific CPU).

Regards,
Alex PopovOn Sat, Aug 15, 2009 at 12:39 AM, walfridson wrote:

Hello

I’ve used 1.2 in the past and had no problems compiling it to x64 with VS.

Doing the exact same with 1.3 doesnt seem to work good though.

Here’s the logfile.
http://walen.se/temp/BuildLog.htm

Any ideas?


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

Here’s the logfile.
http://walen.se/temp/BuildLog.htm

Any ideas?

Inline assembly isn’t supported in the Win64 compiler. We need to #ifdef
that.

–ryan.

Thanks guys
You ideas made it work 100%

FYI, only the MMX and 3DNOW assembly needs to be disabled, and you don’t
need to turn on LIBC.

I created a new Visual Studio 2008 solution with a 64-bit target that works
just fine with the latest code in subversion. :slight_smile:

See ya!On Sat, Aug 15, 2009 at 4:49 AM, Alexander Popov wrote:

Hi,

Try turning off the assembly (optimization for specific CPU).

Regards,
Alex Popov

On Sat, Aug 15, 2009 at 12:39 AM, walfridson wrote:

Hello

I’ve used 1.2 in the past and had no problems compiling it to x64 with VS.

Doing the exact same with 1.3 doesnt seem to work good though.

Here’s the logfile.
http://walen.se/temp/BuildLog.htm

Any ideas?


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


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


-Sam Lantinga, Founder and President, Galaxy Gameworks LLC