]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - sim/configure.ac
sim: unify -Werror build settings
[thirdparty/binutils-gdb.git] / sim / configure.ac
index 35101a0d6729e755d90546034fd519aa01d590ab..8e9190040d4c058c05fd8abcdea768e555225408 100644 (file)
@@ -5,10 +5,21 @@ AC_INIT([sim], [0],
   [https://sourceware.org/bugzilla/enter_bug.cgi?product=gdb&component=sim],
   [], [https://sourceware.org/gdb/wiki/Sim/])
 
+dnl Probably should unify PKGVERSION with PACKAGE_* settings from AC_INIT.
+ACX_PKGVERSION([SIM])
+AC_DEFINE_UNQUOTED([PKGVERSION], ["$PKGVERSION"], [Additional package description])
+dnl PACKAGE_BUGREPORT is provided by AC_INIT.
+ACX_BUGURL([$PACKAGE_BUGREPORT])
+AC_DEFINE_UNQUOTED([REPORT_BUGS_TO], ["$REPORT_BUGS_TO"], [Bug reporting address])
+
+AC_CONFIG_HEADERS([config.h])
+
 SIM_AC_TOOLCHAIN
+SIM_AC_PLATFORM
 
 AM_MAINTAINER_MODE
 AM_INIT_AUTOMAKE
+AM_SILENT_RULES([yes])
 
 # If a cpu ever has more than one simulator to choose from, use
 # --enable-sim=... to choose.
@@ -19,6 +30,10 @@ yes | no) ;;
 *)     AC_MSG_ERROR(bad value ${enableval} given for --enable-sim option) ;;
 esac])
 
+AC_ARG_ENABLE([example-sims],
+             [AC_HELP_STRING([--enable-example-sims],
+                             [enable example GNU simulators])])
+
 AC_ARG_ENABLE(targets,
 [  --enable-targets        alternative target configurations],
 [case "${enableval}" in
@@ -85,8 +100,24 @@ if test "${enable_sim}" != no; then
     SIM_TARGET([ft32-*-*], [ft32])
     SIM_TARGET([v850*-*-*], [v850], [sim_igen=yes])
   done
+
+  if test "x${enable_example_sims}" = xyes; then
+    AC_CONFIG_SUBDIRS(example-synacor)
+  fi
 fi
 AM_CONDITIONAL([SIM_ENABLE_IGEN], [test "$sim_igen" = "yes"])
 
-AC_CONFIG_FILES([Makefile])
+dnl Standard (and optional) simulator options.
+dnl Eventually all simulators will support these.
+SIM_AC_OPTION_ALIGNMENT
+SIM_AC_OPTION_ASSERT
+SIM_AC_OPTION_DEBUG
+SIM_AC_OPTION_ENDIAN
+SIM_AC_OPTION_ENVIRONMENT
+SIM_AC_OPTION_PROFILE
+SIM_AC_OPTION_STDIO
+SIM_AC_OPTION_TRACE
+SIM_AC_OPTION_WARNINGS
+
+AC_CONFIG_FILES([arch-subdir.mk Makefile])
 AC_OUTPUT