This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] RISC-V: Add configure support for riscv*-linux*.


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=52a187f8e78eeaefa38bdaff04aae1fd9a69d788

commit 52a187f8e78eeaefa38bdaff04aae1fd9a69d788
Author: Jim Wilson <jimw@sifive.com>
Date:   Thu Aug 9 13:37:45 2018 -0700

    RISC-V: Add configure support for riscv*-linux*.
    
    This adds the target and native configure support, and the NEWS entries for
    the new target and native configurations.
    
    	gdb/
    	* Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
    	(ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
    	* NEWS: Mention new GNU/Linux RISC-V target.
    	* configure.host: Add riscv*-*-linux*.
    	* configure.nat: Add riscv*.
    	* configure.tgt: Add riscv*-*-linux*.

Diff:
---
 gdb/ChangeLog      | 6 ++++++
 gdb/Makefile.in    | 3 +++
 gdb/NEWS           | 8 ++++++++
 gdb/configure.host | 2 ++
 gdb/configure.nat  | 4 ++++
 gdb/configure.tgt  | 6 ++++++
 6 files changed, 29 insertions(+)

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 40210bb..338813a 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,11 @@
 2018-08-09  Jim Wilson  <jimw@sifive.com>
 
+	* Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
+	(ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
+	* NEWS: Mention new GNU/Linux RISC-V target.
+	* configure.host: Add riscv*-*-linux*.
+	* configure.nat: Add riscv*.
+	* configure.tgt: Add riscv*-*-linux*.
 	* riscv-linux-nat.c: New file.
 	* riscv-linux-tdep.c: New file.
 
diff --git a/gdb/Makefile.in b/gdb/Makefile.in
index 59e3dbf..c007fbc 100644
--- a/gdb/Makefile.in
+++ b/gdb/Makefile.in
@@ -753,6 +753,7 @@ ALL_TARGET_OBS = \
 	ppc-sysv-tdep.o \
 	ppc64-tdep.o \
 	ravenscar-thread.o \
+	riscv-linux-tdep.o \
 	riscv-tdep.o \
 	rl78-tdep.o \
 	rs6000-aix-tdep.o \
@@ -2304,6 +2305,8 @@ ALLDEPFILES = \
 	procfs.c \
 	ravenscar-thread.c \
 	remote-sim.c \
+	riscv-linux-nat.c \
+	riscv-linux-tdep.c \
 	riscv-tdep.c \
 	rl78-tdep.c \
 	rs6000-lynx178-tdep.c \
diff --git a/gdb/NEWS b/gdb/NEWS
index 7f94665..f275031 100644
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -41,6 +41,14 @@ thread apply [all | COUNT | -COUNT] [FLAG]... COMMAND
   FLAG arguments allow to control what output to produce and how to handle
   errors raised when applying COMMAND to a thread.
 
+* New native configurations
+
+GNU/Linux/RISC-V		riscv*-*-linux*
+
+* New targets
+
+GNU/Linux/RISC-V		riscv*-*-linux*
+
 *** Changes in GDB 8.2
 
 * The 'set disassembler-options' command now supports specifying options
diff --git a/gdb/configure.host b/gdb/configure.host
index 6bcb8da..23a2f16 100644
--- a/gdb/configure.host
+++ b/gdb/configure.host
@@ -149,6 +149,8 @@ powerpc64*-*-linux*)	gdb_host=ppc64-linux
 			;;
 powerpc*-*-linux*)	gdb_host=linux ;;
 
+riscv*-*-linux*)	gdb_host=linux ;;
+
 s390*-*-linux*)		gdb_host=linux ;;
 
 sh*-*-netbsdelf* | sh*-*-knetbsd*-gnu)
diff --git a/gdb/configure.nat b/gdb/configure.nat
index 7611266..feddeaa 100644
--- a/gdb/configure.nat
+++ b/gdb/configure.nat
@@ -267,6 +267,10 @@ case ${gdb_host} in
 		# Host: PowerPC, running Linux
 		NATDEPFILES="${NATDEPFILES} ppc-linux-nat.o ppc-linux.o"
 		;;
+	    riscv*)
+		# Host: RISC-V, running Linux
+		NATDEPFILES="${NATDEPFILES} riscv-linux-nat.o"
+		;;
 	    s390)
 		# Host: S390, running Linux
 		NATDEPFILES="${NATDEPFILES} s390-linux-nat.o"
diff --git a/gdb/configure.tgt b/gdb/configure.tgt
index f197160..5e3bd5d 100644
--- a/gdb/configure.tgt
+++ b/gdb/configure.tgt
@@ -517,6 +517,12 @@ s390*-*-linux*)
 	build_gdbserver=yes
 	;;
 
+riscv*-*-linux*)
+	# Target: Linux/RISC-V
+	gdb_target_obs="riscv-linux-tdep.o riscv-tdep.o glibc-tdep.o \
+ 			linux-tdep.o solib-svr4.o symfile-mem.o linux-record.o"
+	;;
+
 riscv*-*-*)
 	# Target: RISC-V architecture
 	gdb_target_obs="riscv-tdep.o"


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]