aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.in6
-rwxr-xr-xconfigure20
-rw-r--r--configure.ac11
3 files changed, 35 insertions, 2 deletions
diff --git a/Makefile.in b/Makefile.in
index 184ba5a..145ad88 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -110,7 +110,8 @@ stamps/build-binutils-linux: $(srcdir)/riscv-binutils-gdb
$(MULTILIB_FLAGS) \
@with_guile@ \
--disable-werror \
- --disable-nls
+ --disable-nls \
+ @enable_gdb@
$(MAKE) -C $(notdir $@)
$(MAKE) -C $(notdir $@) install
mkdir -p $(dir $@) && touch $@
@@ -234,7 +235,8 @@ stamps/build-binutils-newlib: $(srcdir)/riscv-binutils-gdb
$(CONFIGURE_HOST) \
--prefix=$(INSTALL_DIR) \
@with_guile@ \
- --disable-werror
+ --disable-werror \
+ @enable_gdb@
$(MAKE) -C $(notdir $@)
$(MAKE) -C $(notdir $@) install
mkdir -p $(dir $@) && touch $@
diff --git a/configure b/configure
index cb56bae..ab8d525 100755
--- a/configure
+++ b/configure
@@ -584,6 +584,7 @@ PACKAGE_URL=''
ac_subst_vars='LTLIBOBJS
LIBOBJS
+enable_gdb
with_guile
with_system_zlib
configure_host
@@ -663,6 +664,7 @@ with_cmodel
with_host
with_system_zlib
with_guile
+enable_gdb
'
ac_precious_vars='build_alias
host_alias
@@ -1301,6 +1303,7 @@ Optional Features:
--enable-gcc-checking Enable gcc internal checking, it will make gcc very
slow, only enable it when developing gcc
[--disable-gcc-checking]
+ --disable-gdb Don't build GDB, as it's not upstream
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
@@ -3400,6 +3403,23 @@ else
fi
+# Check whether --enable-gdb was given.
+if test "${enable_gdb+set}" = set; then :
+ enableval=$enable_gdb;
+else
+ enable_gdb=yes
+
+fi
+
+
+if test "x$enable_gdb" != xno; then :
+ enable_gdb=--enable-gdb
+
+else
+ enable_gdb=--disable-gdb
+
+fi
+
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/configure.ac b/configure.ac
index 949c73d..af31113 100644
--- a/configure.ac
+++ b/configure.ac
@@ -157,4 +157,15 @@ AS_IF([test "x$with_guile" != xdefault],
[AC_SUBST(with_guile,--with-guile=$with_guile)],
[AC_SUBST(with_guile,"")])
+AC_ARG_ENABLE(gdb,
+ [AS_HELP_STRING([--disable-gdb],
+ [Don't build GDB, as it's not upstream])],
+ [],
+ [enable_gdb=yes]
+ )
+
+AS_IF([test "x$enable_gdb" != xno],
+ [AC_SUBST(enable_gdb, --enable-gdb)],
+ [AC_SUBST(enable_gdb, --disable-gdb)])
+
AC_OUTPUT