Wed 21 Oct 2009 09:18:24 PM UTC, comment #1:
Yes, indeed compilation (your log shows it well) is done with DLW6_X86=1 which is bad on a 64-bit platform. I did compile the game on an x86_64 (but it was a GNU/Linux box) and there's no fundamental reason it wouldn't build on Snow Leopard.
Out of curiosity, what is the output of ./configure? It should show, on the very first lines, what is detected as an OS. For instance on Leopard it gives:
----8<------------------------------------------
checking build system type... i386-apple-darwin9.8.0
checking host system type... i386-apple-darwin9.8.0
checking target system type... i386-apple-darwin9.8.0
----8<------------------------------------------
The host system is what is important in our case.
Normally ./configure should detect non-x86 and avoid compiling the assembly file. Here's an excerpt from ./configure.ac in upcoming 0.0.8beta.
----8<------------------------------------------
lw6_x86=no
if test ${host_cpu} = i386 || test ${host_cpu} = i486 || test ${host_cpu} = i586 || test ${host_cpu} = i686 ; then
lw6_x86=yes
fi
AM_CONDITIONAL(LW6_X86, test x${lw6_x86} = xyes)
LW6_X86_CFLAGS=
if test x${lw6_x86} = xyes ; then
LW6_X86_CFLAGS="-DLW6_X86=1"
fi
----8<------------------------------------------
As a side note, 0.0.7beta has a bug, which is that it tests target instead of host for that matter. But I'm not sure this is the very problem.
If you simply want to continue your compilation (and track other problems) you can try to just patch and put instead:
----8<------------------------------------------
AM_CONDITIONAL(LW6_X86, false)
LW6_X86_CFLAGS=
----8<------------------------------------------
You'll then have to run autoconf and ./configure again.
Thanks for your feedback and have a nice day.
ufoot.
PS: LW does run faster on x86_64, it has non-negligeable 64-bit operations so even if it memory footprint is well below 4gigs, you can expect good perfs. The x86 assembly code was here to fill a gap and implement spin locks which are missing on Mac OS X. So it happens on Mac OS X it's really interesting to have it. The long term solution (I self-censor the possibility that Apple backports pthread spin support to their OS) would be to code that for x86_64 too. It's not that hard, this file is very small and non-complicated. But it's obviously not my priority now. If LW6_X86 is undefined, spin locks are not used and a standard mutex lock is used instead. In theory it's less efficient for some tasks. In theory.
|