diff options
Diffstat (limited to 'sim/bfin')
-rw-r--r-- | sim/bfin/ChangeLog | 6 | ||||
-rw-r--r-- | sim/bfin/Makefile.in | 33 | ||||
-rwxr-xr-x | sim/bfin/configure | 136 | ||||
-rw-r--r-- | sim/bfin/configure.ac | 33 |
4 files changed, 85 insertions, 123 deletions
diff --git a/sim/bfin/ChangeLog b/sim/bfin/ChangeLog index e3e352a..7c34a4f 100644 --- a/sim/bfin/ChangeLog +++ b/sim/bfin/ChangeLog @@ -1,3 +1,9 @@ +2021-06-21 Mike Frysinger <vapier@gentoo.org> + + * Makefile.in (SIM_EXTRA_HW_DEVICES): Define. + * configure.ac (SIM_AC_OPTION_HARDWARE): Delete call. + * configure: Regenerate. + 2021-06-20 Mike Frysinger <vapier@gentoo.org> * configure.ac (SIM_AC_COMMON): Delete. diff --git a/sim/bfin/Makefile.in b/sim/bfin/Makefile.in index e353615..57b9b5e 100644 --- a/sim/bfin/Makefile.in +++ b/sim/bfin/Makefile.in @@ -26,6 +26,39 @@ SIM_OBJS = \ machs.o \ sim-resume.o +SIM_EXTRA_HW_DEVICES = \ + bfin_cec \ + bfin_ctimer \ + bfin_dma \ + bfin_dmac \ + bfin_ebiu_amc \ + bfin_ebiu_ddrc \ + bfin_ebiu_sdc \ + bfin_emac \ + bfin_eppi \ + bfin_evt \ + bfin_gpio \ + bfin_gpio2 \ + bfin_gptimer \ + bfin_jtag \ + bfin_mmu \ + bfin_nfc \ + bfin_otp \ + bfin_pfmon \ + bfin_pint \ + bfin_pll \ + bfin_ppi \ + bfin_rtc \ + bfin_sic \ + bfin_spi \ + bfin_trace \ + bfin_twi \ + bfin_uart \ + bfin_uart2 \ + bfin_wdog \ + bfin_wp \ + eth_phy + SIM_EXTRA_CFLAGS = @SDL_CFLAGS@ SIM_EXTRA_LIBS = @SDL_LIBS@ -lm diff --git a/sim/bfin/configure b/sim/bfin/configure index 0453bae..a8a383a 100755 --- a/sim/bfin/configure +++ b/sim/bfin/configure @@ -589,6 +589,10 @@ sim_scache sim_float sim_bitsize cgen_breaks +sim_hw_sockser +sim_hw_cflags +SIM_ENABLE_HW_FALSE +SIM_ENABLE_HW_TRUE OBJEXT EXEEXT ac_ct_CC @@ -639,9 +643,6 @@ PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL -sim_hw -sim_hw_objs -sim_hw_cflags sim_default_model' ac_subst_files='' ac_user_opts=' @@ -1271,8 +1272,7 @@ Optional Features: --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --enable-sim-default-model=model Specify default model to simulate - --enable-sim-hardware=LIST - Specify the hardware to be included in the build. + --enable-sim-hardware Whether to enable hardware/device simulation Some influential environment variables: PKG_CONFIG path to pkg-config utility @@ -1824,88 +1824,6 @@ fi -hardware="cfi core pal glue \ - bfin_cec \ - bfin_ctimer \ - bfin_dma \ - bfin_dmac \ - bfin_ebiu_amc \ - bfin_ebiu_ddrc \ - bfin_ebiu_sdc \ - bfin_emac \ - bfin_eppi \ - bfin_evt \ - bfin_gpio \ - bfin_gpio2 \ - bfin_gptimer \ - bfin_jtag \ - bfin_mmu \ - bfin_nfc \ - bfin_otp \ - bfin_pfmon \ - bfin_pint \ - bfin_pll \ - bfin_ppi \ - bfin_rtc \ - bfin_sic \ - bfin_spi \ - bfin_trace \ - bfin_twi \ - bfin_uart \ - bfin_uart2 \ - bfin_wdog \ - bfin_wp \ - eth_phy \ -" -sim_hw_cflags="-DWITH_HW=1" -sim_hw="$hardware" -sim_hw_objs="\$(SIM_COMMON_HW_OBJS) `echo $sim_hw | sed -e 's/\([^ ][^ ]*\)/dv-\1.o/g'`" - -# Check whether --enable-sim-hardware was given. -if test "${enable_sim_hardware+set}" = set; then : - enableval=$enable_sim_hardware; -else - enable_sim_hardware="yes" -fi - -case ${enable_sim_hardware} in - yes|no) ;; - ,*) hardware="${hardware} `echo ${enableval} | sed -e 's/,/ /'`";; - *,) hardware="`echo ${enableval} | sed -e 's/,/ /'` ${hardware}";; - *) hardware="`echo ${enableval} | sed -e 's/,/ /'`"'';; -esac - -if test "$enable_sim_hardware" = no; then - sim_hw_objs= - sim_hw_cflags="-DWITH_HW=0" - sim_hw= -else - sim_hw_cflags="-DWITH_HW=1" - # remove duplicates - sim_hw="" - sim_hw_objs="\$(SIM_COMMON_HW_OBJS)" - for i in $hardware ; do - case " $sim_hw " in - *" $i "*) ;; - *) sim_hw="$sim_hw $i" ; sim_hw_objs="$sim_hw_objs dv-$i.o";; - esac - done - # mingw does not support sockser - case ${host} in - *mingw*) ;; - *) # TODO: We don't add dv-sockser to sim_hw as it is not a "real" device - # that you instatiate. Instead, other code will call into it directly. - # At some point, we should convert it over. - sim_hw_objs="$sim_hw_objs dv-sockser.o" - sim_hw_cflags="$sim_hw_cflags -DHAVE_DV_SOCKSER" - ;; - esac - if test x"$silent" != x"yes"; then - echo "Setting hardware to $sim_hw_cflags, $sim_hw, $sim_hw_objs" - fi -fi - - @@ -2960,6 +2878,47 @@ fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sim hardware settings" >&5 +$as_echo_n "checking for sim hardware settings... " >&6; } +# Check whether --enable-sim-hardware was given. +if test "${enable_sim_hardware+set}" = set; then : + enableval=$enable_sim_hardware; +else + enable_sim_hardware="yes" +fi + +sim_hw_sockser= +if test "$enable_sim_hardware" = no; then + sim_hw_cflags="-DWITH_HW=0" +elif test "$enable_sim_hardware" = yes; then + sim_hw_cflags="-DWITH_HW=1" + # mingw does not support sockser + case ${host} in + *mingw*) ;; + *) # TODO: We don't add dv-sockser to sim_hw as it is not a "real" device + # that you instatiate. Instead, other code will call into it directly. + # At some point, we should convert it over. + sim_hw_sockser="dv-sockser.o" + sim_hw_cflags="$sim_hw_cflags -DHAVE_DV_SOCKSER" + ;; + esac +else + as_fn_error $? "unknown argument \"$enable_sim_hardware\"" "$LINENO" 5 +fi +if test "$enable_sim_hardware" = "yes"; then + SIM_ENABLE_HW_TRUE= + SIM_ENABLE_HW_FALSE='#' +else + SIM_ENABLE_HW_TRUE='#' + SIM_ENABLE_HW_FALSE= +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_sim_hardware}" >&5 +$as_echo "${enable_sim_hardware}" >&6; } + + + cgen_breaks="" if grep CGEN_MAINT $srcdir/Makefile.in >/dev/null; then @@ -2983,9 +2942,6 @@ ac_config_commands="$ac_config_commands stamp-h" - - - cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure diff --git a/sim/bfin/configure.ac b/sim/bfin/configure.ac index 4e31c6f..ab3bd5b 100644 --- a/sim/bfin/configure.ac +++ b/sim/bfin/configure.ac @@ -3,39 +3,6 @@ AC_INIT(Makefile.in) AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config]) SIM_AC_OPTION_DEFAULT_MODEL(bf537) -SIM_AC_OPTION_HARDWARE(\ - bfin_cec \ - bfin_ctimer \ - bfin_dma \ - bfin_dmac \ - bfin_ebiu_amc \ - bfin_ebiu_ddrc \ - bfin_ebiu_sdc \ - bfin_emac \ - bfin_eppi \ - bfin_evt \ - bfin_gpio \ - bfin_gpio2 \ - bfin_gptimer \ - bfin_jtag \ - bfin_mmu \ - bfin_nfc \ - bfin_otp \ - bfin_pfmon \ - bfin_pint \ - bfin_pll \ - bfin_ppi \ - bfin_rtc \ - bfin_sic \ - bfin_spi \ - bfin_trace \ - bfin_twi \ - bfin_uart \ - bfin_uart2 \ - bfin_wdog \ - bfin_wp \ - eth_phy \ -) PKG_PROG_PKG_CONFIG PKG_CHECK_MODULES(SDL, sdl, [ |