aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPalmer Dabbelt <palmer@dabbelt.com>2017-09-05 18:46:07 -0700
committerPalmer Dabbelt <palmer@dabbelt.com>2017-09-06 11:34:44 -0700
commit9d284915bffe270d21b33e813e06c09a9283f2f2 (patch)
tree1895eec681bc8bf885f1ec60f17a1944f91fb9a2
parent06b1ebbe4b397fc1b1b3fc27f1cb996404a8fa49 (diff)
downloadriscv-gnu-toolchain-9d284915bffe270d21b33e813e06c09a9283f2f2.zip
riscv-gnu-toolchain-9d284915bffe270d21b33e813e06c09a9283f2f2.tar.gz
riscv-gnu-toolchain-9d284915bffe270d21b33e813e06c09a9283f2f2.tar.bz2
Add a "--disable-gdb" argument
-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