aboutsummaryrefslogtreecommitdiff
path: root/sim/common
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2015-03-23 22:19:41 -0400
committerMike Frysinger <vapier@gentoo.org>2015-03-24 00:13:57 -0400
commit30452bbe7e68581cdb0cd5004e6c4d4d5c9536e8 (patch)
treea52d39c1a9b5466475a60418a6ca495a74307cf2 /sim/common
parent64dd13dfc267b1d13f42519f220e89a4386591fd (diff)
downloadgdb-30452bbe7e68581cdb0cd5004e6c4d4d5c9536e8.zip
gdb-30452bbe7e68581cdb0cd5004e6c4d4d5c9536e8.tar.gz
gdb-30452bbe7e68581cdb0cd5004e6c4d4d5c9536e8.tar.bz2
sim: fix sim-hardware configure option
The current default handling for the --enable-sim-hardware option ends up forcing the value to whatever is set as the first argument when calling the macro (by virtue of how autoconf works). Relocate the setup code to the 4th parameter of the AC_ARG_ENABLE macro to fix it. This was caused by the simplification work in 1517bd274290e06af498ef7e49. Reported-by: Hans-Peter Nilsson <hans-peter.nilsson@axis.com>
Diffstat (limited to 'sim/common')
-rw-r--r--sim/common/ChangeLog5
-rw-r--r--sim/common/acinclude.m49
2 files changed, 7 insertions, 7 deletions
diff --git a/sim/common/ChangeLog b/sim/common/ChangeLog
index 1cfb4d3..655d98a 100644
--- a/sim/common/ChangeLog
+++ b/sim/common/ChangeLog
@@ -1,3 +1,8 @@
+2015-03-24 Mike Frysinger <vapier@gentoo.org>
+
+ * acinclude.m4 (SIM_AC_OPTION_HARDWARE): Move default option setting
+ of enable_sim_hardware to AC_ARG_ENABLE.
+
2015-03-23 Mike Frysinger <vapier@gentoo.org>
* acinclude.m4 (SIM_AC_OPTION_HARDWARE): Delete SIM_DV_SOCKSER_O.
diff --git a/sim/common/acinclude.m4 b/sim/common/acinclude.m4
index 3e9fb2f..6522fea 100644
--- a/sim/common/acinclude.m4
+++ b/sim/common/acinclude.m4
@@ -590,12 +590,6 @@ dnl arg[2] is a space separated list of devices that override the defaults
dnl arg[3] is a space separated list of extra target specific devices.
AC_DEFUN([SIM_AC_OPTION_HARDWARE],
[
-if test x"[$1]" != x"no"; then
- enable_sim_hardware=yes
-else
- enable_sim_hardware=no
-fi
-
if test "[$2]"; then
hardware="[$2]"
else
@@ -609,7 +603,8 @@ sim_hw_objs="\$(SIM_COMMON_HW_OBJS) `echo $sim_hw | sed -e 's/\([[^ ]][[^ ]]*\)/
AC_ARG_ENABLE(sim-hardware,
[AS_HELP_STRING([--enable-sim-hardware=LIST],
- [Specify the hardware to be included in the build.])])
+ [Specify the hardware to be included in the build.])],
+ ,[enable_sim_hardware="[$1]"])
case ${enable_sim_hardware} in
yes|no) ;;
,*) hardware="${hardware} `echo ${enableval} | sed -e 's/,/ /'`";;