1
0
Fork 0

Add a test/option to enable unaliged memory access for certain processors

Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@2130
This commit is contained in:
Sjoerd van der Berg 2005-03-24 08:46:38 +00:00
parent 641fe1b465
commit fb4802a0bb

View file

@ -101,16 +101,31 @@ dnl The target cpu checks for dynamic cores
AH_TEMPLATE(C_HOSTCPU,[The type of cpu this host has])
AC_MSG_CHECKING(for target cpu type)
case "$target_cpu" in
i386|i486|i586|i686)
i?86)
AC_DEFINE(C_HOSTCPU,X86)
AC_MSG_RESULT(x86 compatible)
c_hostcpu="x86"
c_unalignedmemory=yes
;;
*)
powerpc*)
AC_DEFINE(C_HOSTCPU,POWERPC)
AC_MSG_RESULT(Power PC)
c_hostcpu="powerpc"
c_unalignedmemory=yes
;;
m68k*)
AC_DEFINE(C_HOSTCPU,M68K)
AC_MSG_RESULT(Motorola 68000)
c_hostcpu="m68k"
c_unalignedmemory=yes
;;
*)
AC_DEFINE(C_HOSTCPU,UNKOWN)
AC_MSG_RESULT(unknown)
c_unalignedmemory=no
;;
esac
AH_TEMPLATE(C_DYNAMIC_X86,[Define to 1 to use x86 dynamic cpu core])
AC_ARG_ENABLE(dynamic-x86,AC_HELP_STRING([--disable-dynamic-x86],[Disable x86 dynamic cpu core]),,enable_dynamic_x86=yes)
AC_MSG_CHECKING(whether x86 dynamic cpu core will be enabled)
@ -125,8 +140,6 @@ else
fi
fi
AH_TEMPLATE(C_FPU,[Define to 1 to enable floating point emulation])
AC_ARG_ENABLE(fpu,AC_HELP_STRING([--disable-fpu],[Disable fpu support]),,enable_fpu=yes)
AC_MSG_CHECKING(whether fpu emulation will be enabled)
@ -155,6 +168,16 @@ else
fi
fi
AH_TEMPLATE(C_UNALIGNED_MEMORY,[Define to 1 to use a unaligned memory access])
AC_ARG_ENABLE(unaligned_memory,AC_HELP_STRING([--disable-unaligned-memory],[Disable unaligned memory access]),,enable_unaligned_memory=yes)
AC_MSG_CHECKING(whether to enable unaligned memory access)
if test x$enable_unaligned_memory = xyes -a x$c_unalignedmemory = xyes; then
AC_DEFINE(C_UNALIGNED_MEMORY,1)
AC_MSG_RESULT(yes)
else
AC_MSG_RESULT(no)
fi
AH_TEMPLATE(C_SSHOT,[Define to 1 to enable screenshots, requires libpng])
AC_CHECK_HEADER(png.h,have_png_h=yes,)
AC_CHECK_LIB(png, png_check_sig, have_png_lib=yes, ,-lz)