more build fixes for python bindings and 64bit cpus

This commit is contained in:
Jaromil
2008-12-01 13:25:56 +01:00
parent ff4ce2f0f5
commit 28cd83de7c
3 changed files with 28 additions and 9 deletions
-1
View File
@@ -30,7 +30,6 @@ Makefile
TAGS
ylwrap
py-compile
py/freej.pth
py/freej.py
py/freej.pyc
py/freej_py.cpp
+27 -8
View File
@@ -33,12 +33,18 @@ dnl AM_CONDITIONAL(ARCH_PPC, test x$hostcpu = xpowerpc)
have_ppc=yes
;;
i*86*|x86_64*|ia64*)
x86_64*|ia64*)
AC_DEFINE(ARCH_X86,1,[define if compiling for Linux/x86])
AC_DEFINE(HAVE_64BIT,1,[define if host has 64 bit])
;;
i*86*)
AC_DEFINE(ARCH_X86,1,[define if compiling for Linux/x86])
AC_DEFINE(PA_LITTLE_ENDIAN,1,[define little endian arch for portaudio])
# AC_DEFINE(SDL_BYTEORDER,SDL_LIL_ENDIAN,[define little endian arch for SDL])
;;
*)
;;
esac
@@ -56,6 +62,11 @@ dnl AM_CONDITIONAL(ARCH_PPC, test x$hostcpu = xpowerpc)
have_sse=yes
AC_DEFINE(HAVE_SSE2,1,[define if enabling SSE2 acceleration])
fi
if grep "^flags.* ssse3" /proc/cpuinfo > /dev/null; then
have_ssse3=yes
AC_DEFINE(HAVE_SSSE3,1,[define if enabling SSSE3 acceleration])
fi
;;
Darwin)
@@ -391,9 +402,9 @@ if test x$have_lubrifications = xyes; then
if test x$have_ppc = xyes; then
# use optimization flags for darwin
CFLAGS="$CFLAGS -O2 -fomit-frame-pointer -ffast-math -mabi=altivec -maltivec -mpowerpc-gfxopt"
CFLAGS="$CFLAGS -O2 -mabi=altivec -maltivec -mpowerpc-gfxopt"
else
CFLAGS="$CFLAGS -O2 -fexpensive-optimizations -msse -fomit-frame-pointer -ffast-math"
CFLAGS="$CFLAGS -O2 -mfpmath=sse -mtune=pentium4"
fi
# adding these provoke 'illegal instruction' errors in some
@@ -401,16 +412,24 @@ if test x$have_lubrifications = xyes; then
elif test x$have_ppc = xyes; then
CFLAGS="$CFLAGS -O2 -fomit-frame-pointer -ffast-math -mabi=altivec -maltivec -mpowerpc-gfxopt"
elif test x$host_cpu = xx86_64; then
CFLAGS="$CFLAGS -O2 -fomit-frame-pointer -ffast-math"
AC_DEFINE(HAVE_64BIT,1,[define if host has 64 bit])
else # any other platform optimizations
CFLAGS="$CFLAGS -O2 -ffast-math"
# should complete this with all 64bit CPUs (AMD too)
if test x$have_ssse3 = xyes; then
# multiple core cpu
CFLAGS="$CFLAGS -O2 -mfpmath=sse -mtune=core2"
else
# single core 64bit cpu
CFLAGS="$CFLAGS -O2 -mfpmath=sse -mtune=nocona"
fi
fi
# any other platform optimizations
echo "no special optimisation flags found for your cpu"
echo "please suggest some on our mailinglist if you know better!"
CFLAGS="$CFLAGS -O2"
fi
else
if test x$have_profiling = xno -a x$debug = xfalse; then
echo "enabling generic compiler optimizations"
CFLAGS="$CFLAGS -O2 -fomit-frame-pointer -ffast-math -mmmx"
CFLAGS="$CFLAGS -O2"
fi
fi
AC_SUBST(CFLAGS)
+1
View File
@@ -0,0 +1 @@
freej