public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] sim: cris/frv/iq2000/lm32: merge with common configure script
@ 2021-06-30 18:38 Mike Frysinger
  0 siblings, 0 replies; only message in thread
From: Mike Frysinger @ 2021-06-30 18:38 UTC (permalink / raw)
  To: gdb-patches

Now that the scache logic has been migrated into the common code,
there's nothing specific in these configure scripts, so merge them
into the common one.

The frv unique logic can be moved to a dedicated include and merged
in the common configure since the flag has been scoped to the arch.
---
 sim/Makefile.in         |   24 +-
 sim/configure           |  105 +-
 sim/configure.ac        |    9 +-
 sim/cris/aclocal.m4     |   15 -
 sim/cris/configure      | 2876 --------------------------------------
 sim/cris/configure.ac   |    5 -
 sim/frv/acinclude.m4    |   34 +
 sim/frv/aclocal.m4      |   15 -
 sim/frv/configure       | 2906 ---------------------------------------
 sim/frv/configure.ac    |   23 -
 sim/iq2000/aclocal.m4   |   15 -
 sim/iq2000/configure    | 2876 --------------------------------------
 sim/iq2000/configure.ac |    5 -
 sim/lm32/aclocal.m4     |   15 -
 sim/lm32/configure      | 2876 --------------------------------------
 sim/lm32/configure.ac   |    5 -
 16 files changed, 154 insertions(+), 11650 deletions(-)
 delete mode 100644 sim/cris/aclocal.m4
 delete mode 100755 sim/cris/configure
 delete mode 100644 sim/cris/configure.ac
 create mode 100644 sim/frv/acinclude.m4
 delete mode 100644 sim/frv/aclocal.m4
 delete mode 100755 sim/frv/configure
 delete mode 100644 sim/frv/configure.ac
 delete mode 100644 sim/iq2000/aclocal.m4
 delete mode 100755 sim/iq2000/configure
 delete mode 100644 sim/iq2000/configure.ac
 delete mode 100644 sim/lm32/aclocal.m4
 delete mode 100755 sim/lm32/configure
 delete mode 100644 sim/lm32/configure.ac

diff --git a/sim/configure.ac b/sim/configure.ac
index 7e6d01360b6e..9d0c9f5dd445 100644
--- a/sim/configure.ac
+++ b/sim/configure.ac
@@ -117,13 +117,13 @@ if test "${enable_sim}" != no; then
     SIM_TARGET([bfin-*-*], [bfin])
     SIM_TARGET([bpf-*-*], [bpf], [true])
     SIM_TARGET([cr16*-*-*], [cr16])
-    SIM_TARGET([cris-*-* | crisv32-*-*], [cris], [true])
+    SIM_TARGET([cris-*-* | crisv32-*-*], [cris])
     SIM_TARGET([d10v-*-*], [d10v])
-    SIM_TARGET([frv-*-*], [frv], [true])
+    SIM_TARGET([frv-*-*], [frv])
     SIM_TARGET([ft32-*-*], [ft32])
     SIM_TARGET([h8300*-*-*], [h8300])
-    SIM_TARGET([iq2000-*-*], [iq2000], [true])
-    SIM_TARGET([lm32-*-*], [lm32], [true])
+    SIM_TARGET([iq2000-*-*], [iq2000])
+    SIM_TARGET([lm32-*-*], [lm32])
     SIM_TARGET([m32c-*-*], [m32c])
     SIM_TARGET([m32r-*-*], [m32r], [true])
     SIM_TARGET([m68hc11-*-*|m6811-*-*], [m68hc11])
@@ -175,6 +175,7 @@ AC_SUBST(sim_float)
 AC_SUBST(sim_reserved_bits)
 
 dnl Some arches have unique configure flags.
+m4_include([frv/acinclude.m4])
 m4_include([rx/acinclude.m4])
 
 AC_CONFIG_FILES([arch-subdir.mk Makefile])
diff --git a/sim/cris/configure.ac b/sim/cris/configure.ac
deleted file mode 100644
index 99370b3a5770..000000000000
--- a/sim/cris/configure.ac
+++ /dev/null
@@ -1,5 +0,0 @@
-dnl Process this file with autoconf to produce a configure script.
-AC_INIT(Makefile.in)
-AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
-
-SIM_AC_OUTPUT
diff --git a/sim/frv/acinclude.m4 b/sim/frv/acinclude.m4
new file mode 100644
index 000000000000..797bcd6c60f7
--- /dev/null
+++ b/sim/frv/acinclude.m4
@@ -0,0 +1,34 @@
+dnl   Copyright (C) 1997-2021 Free Software Foundation, Inc.
+dnl
+dnl This program is free software; you can redistribute it and/or modify
+dnl it under the terms of the GNU General Public License as published by
+dnl the Free Software Foundation; either version 3 of the License, or
+dnl (at your option) any later version.
+dnl
+dnl This program is distributed in the hope that it will be useful,
+dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
+dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+dnl GNU General Public License for more details.
+dnl
+dnl You should have received a copy of the GNU General Public License
+dnl along with this program.  If not, see <http://www.gnu.org/licenses/>.
+dnl
+dnl NB: This file is included in sim/configure, so keep settings namespaced.
+dnl
+dnl Enable making unknown traps dump out registers
+AC_MSG_CHECKING([whether sim frv should dump cpu state on unknown traps])
+AC_ARG_ENABLE(sim-frv-trapdump,
+[AS_HELP_STRING([--enable-sim-frv-trapdump],
+		[Make unknown traps dump the registers])],
+[case "${enableval}" in
+yes|no) ;;
+*) AC_MSG_ERROR("Unknown value $enableval passed to --enable-sim-trapdump");;
+esac])
+if test "x${enable_sim_frv_trapdump}" != xno; then
+  SIM_FRV_TRAPDUMP_FLAGS="-DTRAPDUMP=1"
+  AC_MSG_RESULT([yes])
+else
+  SIM_FRV_TRAPDUMP_FLAGS="-DTRAPDUMP=0"
+  AC_MSG_RESULT([no])
+fi
+AC_SUBST(SIM_FRV_TRAPDUMP_FLAGS)
diff --git a/sim/frv/configure.ac b/sim/frv/configure.ac
deleted file mode 100644
index 7e237151f347..000000000000
--- a/sim/frv/configure.ac
+++ /dev/null
@@ -1,23 +0,0 @@
-dnl Process this file with autoconf to produce a configure script.
-AC_INIT(Makefile.in)
-AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
-
-dnl Enable making unknown traps dump out registers
-AC_MSG_CHECKING([whether sim frv should dump cpu state on unknown traps])
-AC_ARG_ENABLE(sim-frv-trapdump,
-[AS_HELP_STRING([--enable-sim-frv-trapdump],
-		[Make unknown traps dump the registers])],
-[case "${enableval}" in
-yes|no) ;;
-*) AC_MSG_ERROR("Unknown value $enableval passed to --enable-sim-trapdump");;
-esac])
-if test "x${enable_sim_frv_trapdump}" != xno; then
-  SIM_FRV_TRAPDUMP_FLAGS="-DTRAPDUMP=1"
-  AC_MSG_RESULT([yes])
-else
-  SIM_FRV_TRAPDUMP_FLAGS="-DTRAPDUMP=0"
-  AC_MSG_RESULT([no])
-fi
-AC_SUBST(SIM_FRV_TRAPDUMP_FLAGS)
-
-SIM_AC_OUTPUT
diff --git a/sim/iq2000/configure.ac b/sim/iq2000/configure.ac
deleted file mode 100644
index 99370b3a5770..000000000000
--- a/sim/iq2000/configure.ac
+++ /dev/null
@@ -1,5 +0,0 @@
-dnl Process this file with autoconf to produce a configure script.
-AC_INIT(Makefile.in)
-AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
-
-SIM_AC_OUTPUT
diff --git a/sim/lm32/configure.ac b/sim/lm32/configure.ac
deleted file mode 100644
index 99370b3a5770..000000000000
--- a/sim/lm32/configure.ac
+++ /dev/null
@@ -1,5 +0,0 @@
-dnl Process this file with autoconf to produce a configure script.
-AC_INIT(Makefile.in)
-AC_CONFIG_MACRO_DIRS([../m4 ../.. ../../config])
-
-SIM_AC_OUTPUT
-- 
2.31.1


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-06-30 18:38 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-30 18:38 [PATCH] sim: cris/frv/iq2000/lm32: merge with common configure script Mike Frysinger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).