This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
trivial fix to sim/common/aclocal.m4 SIM_AC_OPTION_SCACHE
- To: gdb-patches at sourceware dot cygnus dot com
- Subject: trivial fix to sim/common/aclocal.m4 SIM_AC_OPTION_SCACHE
- From: cgd at sibyte dot com (Chris G. Demetriou)
- Date: 02 Dec 2000 15:43:01 -0800
While looking through and cleaning our diffs to the sim bits, I
noticed a bug in SIM_AC_OPTION_SCACHE, a patch for which is below.
The existing code is obviously broken and the new code correct. (as
it turns out, because of complementary errors in the old code, the
effect would simply be that WITH_SCACHE wouldn't be defined at all,
rather than a bogus value showing up in the compile flags... but a
bug's a bug. 8-)
I tested it in the stock sim sources by configuring an fr30-elf
simulator with "--enable-sim-cache=3" and looking at the resulting
fr30 Makefile.
(apply in sim/common)
2000-12-02 Chris Demetriou <cgd@sibyte.com>
* aclocal.m4 (SIM_AC_OPTION_SCACHE): Properly
handle the case where a numeric value is supplied.
(all of the configure files need to be updated, too.)
chris
===================================================================
Index: common/aclocal.m4
===================================================================
RCS file: /cvs/src/src/sim/common/aclocal.m4,v
retrieving revision 1.3
diff -c -r1.3 aclocal.m4
*** aclocal.m4 2000/05/24 04:39:47 1.3
--- aclocal.m4 2000/12/02 23:28:35
***************
*** 529,535 ****
[case "${enableval}" in
yes) sim_scache="-DWITH_SCACHE=${default_sim_scache}";;
no) sim_scache="-DWITH_SCACHE=0" ;;
! [[0-9]]*) sim_cache=${enableval};;
*) AC_MSG_ERROR("Bad value $enableval passed to --enable-sim-scache");
sim_scache="";;
esac
--- 529,535 ----
[case "${enableval}" in
yes) sim_scache="-DWITH_SCACHE=${default_sim_scache}";;
no) sim_scache="-DWITH_SCACHE=0" ;;
! [[0-9]]*) sim_scache="-DWITH_SCACHE=${enableval}";;
*) AC_MSG_ERROR("Bad value $enableval passed to --enable-sim-scache");
sim_scache="";;
esac