📄 configure.in
字号:
dnl Process this file with autoconf to produce a configure script.sinclude(../common/aclocal.m4)AC_PREREQ(2.5)dnlAC_INIT(Makefile.in)AC_PROG_INSTALLAC_PROG_CC# Put a plausible default for CC_FOR_BUILD in Makefile.if test "x$cross_compiling" = "xno"; then CC_FOR_BUILD='$(CC)'else CC_FOR_BUILD=gccfidnl We don't use gettext, but bfd does. So we do the appropriate checksdnl to see if there are intl libraries we should link against.ALL_LINGUAS=CY_GNU_GETTEXTAC_ARG_ENABLE(sim-alignment,[ --enable-sim-alignment=align Specify strict or nonstrict alignment.],[case "${enableval}" in yes | strict | STRICT) sim_alignment="-DWITH_ALIGNMENT=STRICT_ALIGNMENT";; no | nonstrict | NONSTRICT) sim_alignment="-DWITH_ALIGNMENT=NONSTRICT_ALIGNMENT";; 0 | default | DEFAULT) sim_alignment="-DWITH_ALIGNMENT=0";; *) AC_MSG_ERROR("Unknown value $enableval passed to --enable-sim-alignment"); sim_alignment="";;esacif test x"$silent" != x"yes" && test x"$sim_alignment" != x""; then echo "Setting alignment flags = $sim_alignment" 6>&1fi],[sim_alignment=""])dnlAC_ARG_ENABLE(sim-assert,[ --enable-sim-assert Specify whether to perform random assertions.],[case "${enableval}" in yes) sim_assert="-DWITH_ASSERT=1";; no) sim_assert="-DWITH_ASSERT=0";; *) AC_MSG_ERROR("--enable-sim-assert does not take a value"); sim_assert="";;esacif test x"$silent" != x"yes" && test x"$sim_assert" != x""; then echo "Setting assert flags = $sim_assert" 6>&1fi],[sim_assert=""])dnlAC_ARG_ENABLE(sim-bitsize,[ --enable-sim-bitsize=n Specify target bitsize (32 or 64).],[case "${enableval}" in 32|64) sim_bitsize="-DWITH_TARGET_WORD_BITSIZE=$enableval";; *) AC_MSG_ERROR("--enable-sim-bitsize was given $enableval. Expected 32 or 64"); sim_bitsize="";;esacif test x"$silent" != x"yes" && test x"$sim_bitsize" != x""; then echo "Setting bitsize flags = $sim_bitsize" 6>&1fi],[sim_bitsize=""])dnlAC_ARG_ENABLE(sim-bswap,[ --enable-sim-bswap Use the BSWAP instruction on Intel 486s and Pentiums.],[case "${enableval}" in yes) sim_bswap="-DWITH_BSWAP=1";; no) sim_bswap="-DWITH_BSWAP=0";; *) AC_MSG_ERROR("--enable-sim-bswap does not take a value"); sim_bswap="";;esacif test x"$silent" != x"yes" && test x"$sim_bswap" != x""; then echo "Setting bswap flags = $sim_bswap" 6>&1fi],[sim_bswap=""])dnlAC_ARG_ENABLE(sim-cflags,[ --enable-sim-cflags=opts Extra CFLAGS for use in building simulator],[case "${enableval}" in yes) sim_cflags="-O2 -fomit-frame-pointer";; no) sim_cflags="";; *) sim_cflags=`echo "${enableval}" | sed -e "s/,/ /g"`;;esacif test x"$silent" != x"yes" && test x"$sim_cflags" != x""; then echo "Setting sim cflags = $sim_cflags" 6>&1fi],[sim_cflags=""])dnlAC_ARG_ENABLE(sim-config,[ --enable-sim-config=file Override default config file],[case "${enableval}" in yes|no) AC_MSG_ERROR("No value supplied for --enable-sim-config=file");; *) if test -f "${srcdir}/${enableval}"; then sim_config="${enableval}"; elif test -f "${srcdir}/${enableval}-config.h"; then sim_config="${enableval}-config.h" else AC_MSG_ERROR("Config file $enableval was not found"); sim_config=std-config.h fi;;esacif test x"$silent" != x"yes" && test x"$sim_config" != x""; then echo "Setting config flags = $sim_config" 6>&1fi],[sim_config="std-config.h"if test x"$silent" != x"yes"; then echo "Setting config flags = $sim_config" 6>&1fi])dnlAC_ARG_ENABLE(sim-decode-mechanism,[ --enable-sim-decode-mechanism=which Specify the instruction decode mechanism.],[case "${enableval}" in yes|no) AC_MSG_ERROR("No value supplied for --enable-sim-decode-mechanism=file");; array|switch|padded-switch|goto-switch) sim_decode_mechanism="-T ${enableval}";; *) AC_MSG_ERROR("File $enableval is not an opcode rules file"); sim_decode_mechanism="switch";;esacif test x"$silent" != x"yes" && test x"$sim_decode_mechanism" != x""; then echo "Setting decode mechanism flags = $sim_decode_mechanism" 6>&1fi],[sim_decode_mechanism=""if test x"$silent" != x"yes"; then echo "Setting decode mechanism flags = $sim_decode_mechanism"fi])dnlAC_ARG_ENABLE(sim-default-model,[ --enable-sim-default-model=which Specify default PowerPC to model.],[case "${enableval}" in yes|no) AC_MSG_ERROR("No value supplied for --enable-sim-default-model=model");; *) sim_default_model="-DWITH_DEFAULT_MODEL=${enableval}";;esacif test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then echo "Setting default-model flags = $sim_default_model" 6>&1fi],[sim_default_model=""])dnlAC_ARG_ENABLE(sim-duplicate,[ --enable-sim-duplicate Expand (duplicate) semantic functions.],[case "${enableval}" in yes) sim_dup="-E";; no) sim_dup="";; *) AC_MSG_ERROR("--enable-sim-duplicate does not take a value"); sim_dup="";;esacif test x"$silent" != x"yes" && test x"$sim_dup" != x""; then echo "Setting duplicate flags = $sim_dup" 6>&1fi],[sim_dup="-E"if test x"$silent" != x"yes"; then echo "Setting duplicate flags = $sim_dup" 6>&1fi])dnlAC_ARG_ENABLE(sim-endian,[ --enable-sim-endian=endian Specify target byte endian orientation.],[case "${enableval}" in yes) case "$target" in *powerpc-*) sim_endian="-DWITH_TARGET_BYTE_ORDER=BIG_ENDIAN";; *powerpcle-*) sim_endian="-DWITH_TARGET_BYTE_ORDER=LITTLE_ENDIAN";; *) echo "Unknown target $target" 1>&6; sim_endian="-DWITH_TARGET_BYTE_ORDER=0";; esac;; no) sim_endian="-DWITH_TARGET_BYTE_ORDER=0";; b*|B*) sim_endian="-DWITH_TARGET_BYTE_ORDER=BIG_ENDIAN";; l*|L*) sim_endian="-DWITH_TARGET_BYTE_ORDER=LITTLE_ENDIAN";; *) AC_MSG_ERROR("Unknown value $enableval for --enable-sim-endian"); sim_endian="";;esacif test x"$silent" != x"yes" && test x"$sim_endian" != x""; then echo "Setting endian flags = $sim_endian" 6>&1fi],[sim_endian=""])dnlAC_ARG_ENABLE(sim-env,[ --enable-sim-env=env Specify target environment (operating, virtual, user).],[case "${enableval}" in operating | os | oea) sim_env="-DWITH_ENVIRONMENT=OPERATING_ENVIRONMENT";; virtual | vea) sim_env="-DWITH_ENVIRONMENT=VIRTUAL_ENVIRONMENT";; user | uea) sim_env="-DWITH_ENVIRONMENT=USER_ENVIRONMENT";; no) sim_env="-DWITH_ENVIRONMENT=0";; *) AC_MSG_ERROR("Unknown value $enableval passed to --enable-sim-env"); sim_env="";;esacif test x"$silent" != x"yes" && test x"$sim_env" != x""; then echo "Setting env flags = $sim_env" 6>&1fi],[sim_env=""])dnlAC_ARG_ENABLE(sim-filter,[ --enable-sim-filter=rule Specify filter rules.],[case "${enableval}" in yes) AC_MSG_ERROR("--enable-sim-filter must be specified with a rule to filter or no"); sim_filter="";; no) sim_filter="";; *) sim_filter="-F $enableval";;esacif test x"$silent" != x"yes" && test x"$sim_filter" != x""; then echo "Setting filter flags = $sim_filter" 6>&1fi],[sim_filter="-F 32,f,o"if test x"$silent" != x"yes"; then echo "Setting filter flags = $sim_filter" 6>&1fi])dnlAC_ARG_ENABLE(sim-float,[ --enable-sim-float Specify whether the target has hard, soft, altivec or e500 floating point.],[case "${enableval}" in yes | hard) sim_float="-DWITH_FLOATING_POINT=HARD_FLOATING_POINT";; no | soft) sim_float="-DWITH_FLOATING_POINT=SOFT_FLOATING_POINT";; altivec) sim_float="-DWITH_ALTIVEC" ; sim_filter="${sim_filter},av" ;; *spe*|*simd*) sim_float="-DWITH_E500" ; sim_filter="${sim_filter},e500" ;; *) AC_MSG_ERROR("Unknown value $enableval passed to --enable-sim-float"); sim_float="";;esacif test x"$silent" != x"yes" && test x"$sim_float" != x""; then echo "Setting float flags = $sim_float" 6>&1fi],[case "${target}" in *altivec*) sim_float="-DWITH_ALTIVEC" ; sim_filter="${sim_filter},av" ;; *spe*|*simd*) sim_float="-DWITH_E500" ; sim_filter="${sim_filter},e500" ;; *) sim_float=""esac])dnlAC_ARG_ENABLE(sim-hardware,[ --enable-sim-hardware=list Specify the hardware to be included in the build.],[hardware="cpu,memory,nvram,iobus,htab,disk,trace,register,vm,init,core,pal,com,eeprom,opic,glue,phb,ide"case "${enableval}" in yes) ;; no) AC_MSG_ERROR("List of hardware must be specified for --enable-sim-hardware"); hardware="";; ,*) hardware="${hardware}${enableval}";; *,) hardware="${enableval}${hardware}";; *) hardware="${enableval}"'';;esacsim_hw_src=`echo $hardware | sed -e 's/,/.c hw_/g' -e 's/^/hw_/' -e s'/$/.c/'`sim_hw_obj=`echo $sim_hw_src | sed -e 's/\.c/.o/g'`if test x"$silent" != x"yes" && test x"$hardware" != x""; then echo "Setting hardware to $sim_hw_src, $sim_hw_obj"fi],[hardware="cpu,memory,nvram,iobus,htab,disk,trace,register,vm,init,core,pal,com,eeprom,opic,glue,phb,ide"sim_hw_src=`echo $hardware | sed -e 's/,/.c hw_/g' -e 's/^/hw_/' -e s'/$/.c/'`sim_hw_obj=`echo $sim_hw_src | sed -e 's/\.c/.o/g'`if test x"$silent" != x"yes"; then echo "Setting hardware to $sim_hw_src, $sim_hw_obj"fi])dnlAC_ARG_ENABLE(sim-hostbitsize,[ --enable-sim-hostbitsize=32|64 Specify host bitsize (32 or 64).],[case "${enableval}" in 32|64) sim_hostbitsize="-DWITH_HOST_WORD_BITSIZE=$enableval";; *) AC_MSG_ERROR("--enable-sim-hostbitsize was given $enableval. Expected 32 or 64"); sim_hostbitsize="";;esacif test x"$silent" != x"yes" && test x"$sim_hostbitsize" != x""; then echo "Setting hostbitsize flags = $sim_hostbitsize" 6>&1fi],[sim_hostbitsize=""])dnlAC_ARG_ENABLE(sim-hostendian,[ --enable-sim-hostendian=end Specify host byte endian orientation.],[case "${enableval}" in no) sim_hostendian="-DWITH_HOST_BYTE_ORDER=0";; b*|B*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN";; l*|L*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN";; *) AC_MSG_ERROR("Unknown value $enableval for --enable-sim-hostendian"); sim_hostendian="";;esacif test x"$silent" != x"yes" && test x"$sim_hostendian" != x""; then echo "Setting hostendian flags = $sim_hostendian" 6>&1fi],[if test "x$cross_compiling" = "xno"; then AC_C_BIGENDIAN if test $ac_cv_c_bigendian = yes; then sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN" else sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN" fielse sim_hostendian="-DWITH_HOST_BYTE_ORDER=0"fi])dnlAC_ARG_ENABLE(sim-icache,[ --enable-sim-icache=size Specify instruction-decode cache size and type.],[icache="-R" case "${enableval}" in yes) icache="1024"; sim_icache="-I $icache";; no) sim_icache="-R";; *) icache=1024 sim_icache="-" for x in `echo "${enableval}" | sed -e "s/,/ /g"`; do case "$x" in define) sim_icache="${sim_icache}R";; semantic) sim_icache="${sim_icache}C";; insn) sim_icache="${sim_icache}S";; 0*|1*|2*|3*|4*|5*|6*|7*|8*|9*) icache=$x;; *) AC_MSG_ERROR("Unknown value $x for --enable-sim-icache"); sim_icache="";; esac done sim_icache="${sim_icache}I $icache";;esacif test x"$silent" != x"yes" && test x"$icache" != x""; then echo "Setting instruction cache size to $icache ($sim_icache)"fi],[sim_icache="-CSRI 1024"if test x"$silent" != x"yes"; then echo "Setting instruction cache size to 1024 ($sim_icache)"fi])dnlAC_ARG_ENABLE(sim-inline,[ --enable-sim-inline=inlines Specify which functions should be inlined.],[sim_inline=""case "$enableval" in no) sim_inline="-DDEFAULT_INLINE=0";; 0) sim_inline="-DDEFAULT_INLINE=0";; yes | 2) sim_inline="-DDEFAULT_INLINE=ALL_INLINE";; 1) sim_inline="-DDEFAULT_INLINE=PSIM_INLINE_LOCALS";; *) for x in `echo "$enableval" | sed -e "s/,/ /g"`; do new_flag="" case "$x" in *_INLINE=*) new_flag="-D$x";; *=*) new_flag=`echo "$x" | sed -e "s/=/_INLINE=/" -e "s/^/-D/"`;; *_INLINE) new_flag="-D$x=ALL_INLINE";; *) new_flag="-D$x""_INLINE=ALL_INLINE";; esac if test x"$sim_inline" = x""; then sim_inline="$new_flag" else sim_inline="$sim_inline $new_flag" fi done;;esacif test x"$silent" != x"yes" && test x"$sim_inline" != x""; then echo "Setting inline flags = $sim_inline" 6>&1fi],[if test x"$GCC" != ""; then sim_inline="-DDEFAULT_INLINE=PSIM_INLINE_LOCALS" if test x"$silent" != x"yes"; then echo "Setting inline flags = $sim_inline" 6>&1 fielse sim_inline=""fi])dnlAC_ARG_ENABLE(sim-jump,[ --enable-sim-jump Jump between semantic code (instead of call/return).],[case "${enableval}" in yes) sim_jump="-J";; no) sim_jump="";; *) AC_MSG_ERROR("--enable-sim-jump does not take a value"); sim_jump="";;esacif test x"$silent" != x"yes" && test x"$sim_jump" != x""; then echo "Setting jump flag = $sim_jump" 6>&1fi],[sim_jump=""if test x"$silent" != x"yes"; then echo "Setting jump flag = $sim_jump" 6>&1fi])dnlAC_ARG_ENABLE(sim-line-nr,[ --enable-sim-line-nr=opts Generate extra CPP code that references source rather than generated code],[case "${enableval}" in yes) sim_line_nr="";; no) sim_line_nr="-L";; *) AC_MSG_ERROR("--enable-sim-line-nr does not take a value"); sim_line_nr="";;esacif test x"$silent" != x"yes" && test x"$sim_line_nr" != x""; then echo "Setting warning flags = $sim_line_nr" 6>&1fi],[sim_line_nr=""])dnlAC_ARG_ENABLE(sim-model,[ --enable-sim-model=which Specify PowerPC to model.],[case "${enableval}" in yes|no) AC_MSG_ERROR("No value supplied for --enable-sim-model=model");; *) sim_model="-DWITH_MODEL=${enableval}";;esacif test x"$silent" != x"yes" && test x"$sim_model" != x""; then echo "Setting model flags = $sim_model" 6>&1fi],[sim_model=""])dnlAC_ARG_ENABLE(sim-model-issue,[ --enable-sim-model-issue Specify whether to simulate model specific actions],[case "${enableval}" in yes) sim_model_issue="-DWITH_MODEL_ISSUE=MODEL_ISSUE_PROCESS";; no) sim_model_issue="-DWITH_MODEL_ISSUE=MODEL_ISSUE_IGNORE";; *) AC_MSG_ERROR("--enable-sim-model-issue does not take a value"); sim_model_issue="";;esacif test x"$silent" != x"yes"; then echo "Setting model-issue flags = $sim_model_issue" 6>&1fi],[sim_model_issue=""])dnlAC_ARG_ENABLE(sim-monitor,[ --enable-sim-monitor=mon Specify whether to enable monitoring events.],[case "${enableval}" in yes) sim_monitor="-DWITH_MON='MONITOR_INSTRUCTION_ISSUE | MONITOR_LOAD_STORE_UNIT'";; no) sim_monitor="-DWITH_MON=0";; instruction) sim_monitor="-DWITH_MON=MONITOR_INSTRUCTION_ISSUE";; memory) sim_monitor="-DWITH_MON=MONITOR_LOAD_STORE_UNIT";; *) AC_MSG_ERROR("Unknown value $enableval passed to --enable-sim-mon"); sim_env="";;esacif test x"$silent" != x"yes" && test x"$sim_monitor" != x""; then echo "Setting monitor flags = $sim_monitor" 6>&1fi],[sim_monitor=""])dnlAC_ARG_ENABLE(sim-opcode,[ --enable-sim-opcode=which Override default opcode lookup.],[case "${enableval}" in
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -