mirror of
https://github.com/devkitPro/buildscripts.git
synced 2026-08-21 09:54:03 -05:00
Compare commits
7 Commits
devkitPPC_
...
v20181215
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8421d92bcb | ||
|
|
20dc1324d4 | ||
|
|
118896fb1a | ||
|
|
ab95988007 | ||
|
|
596d710c3b | ||
|
|
f0463ecba1 | ||
|
|
0bbc2be394 |
@@ -1,6 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
#---------------------------------------------------------------------------------
|
#---------------------------------------------------------------------------------
|
||||||
# devkitARM release 49
|
# devkitARM release 50
|
||||||
# devkitPPC release 33
|
# devkitPPC release 33
|
||||||
# devkitA64 release 12
|
# devkitA64 release 12
|
||||||
#---------------------------------------------------------------------------------
|
#---------------------------------------------------------------------------------
|
||||||
@@ -154,11 +154,13 @@ export MAKE
|
|||||||
TOOLPATH=$(echo $INSTALLDIR | sed -e 's/^\([a-zA-Z]\):/\/\1/')
|
TOOLPATH=$(echo $INSTALLDIR | sed -e 's/^\([a-zA-Z]\):/\/\1/')
|
||||||
export PATH=$PATH:$TOOLPATH/$package/bin
|
export PATH=$PATH:$TOOLPATH/$package/bin
|
||||||
|
|
||||||
|
CROSS_PARAMS="--build=`./config.guess`"
|
||||||
|
|
||||||
if [ ! -z $CROSSBUILD ]; then
|
if [ ! -z $CROSSBUILD ]; then
|
||||||
toolsprefix=$INSTALLDIR/$CROSSBUILD/tools
|
toolsprefix=$INSTALLDIR/$CROSSBUILD/tools
|
||||||
prefix=$INSTALLDIR/$CROSSBUILD/$package
|
prefix=$INSTALLDIR/$CROSSBUILD/$package
|
||||||
toolsprefix=$INSTALLDIR/$CROSSBUILD/tools
|
toolsprefix=$INSTALLDIR/$CROSSBUILD/tools
|
||||||
CROSS_PARAMS="--build=`./config.guess` --host=$CROSSBUILD"
|
CROSS_PARAMS="$CROSS_PARAMS --host=$CROSSBUILD"
|
||||||
CROSS_GCC_PARAMS="--with-gmp=$CROSSPATH --with-mpfr=$CROSSPATH --with-mpc=$CROSSPATH"
|
CROSS_GCC_PARAMS="--with-gmp=$CROSSPATH --with-mpfr=$CROSSPATH --with-mpc=$CROSSPATH"
|
||||||
else
|
else
|
||||||
toolsprefix=$INSTALLDIR/tools
|
toolsprefix=$INSTALLDIR/tools
|
||||||
|
|||||||
@@ -1,7 +1,8 @@
|
|||||||
diff -NBaur gcc-8.1.0/gcc/config/arm/arm-cpus.in gcc-8.1.0-arm/gcc/config/arm/arm-cpus.in
|
diff --git a/gcc/config/arm/arm-cpus.in b/gcc/config/arm/arm-cpus.in
|
||||||
--- gcc-8.1.0/gcc/config/arm/arm-cpus.in 2018-01-11 15:21:26.000000000 +0000
|
index 545321b0bbe..63ed77af8fd 100644
|
||||||
+++ gcc-8.1.0-arm/gcc/config/arm/arm-cpus.in 2018-05-11 01:05:33.648236777 +0000
|
--- a/gcc/config/arm/arm-cpus.in
|
||||||
@@ -393,7 +393,7 @@
|
+++ b/gcc/config/arm/arm-cpus.in
|
||||||
|
@@ -395,7 +395,7 @@ begin arch armv6k
|
||||||
tune for mpcore
|
tune for mpcore
|
||||||
tune flags CO_PROC
|
tune flags CO_PROC
|
||||||
base 6K
|
base 6K
|
||||||
@@ -10,9 +11,10 @@ diff -NBaur gcc-8.1.0/gcc/config/arm/arm-cpus.in gcc-8.1.0-arm/gcc/config/arm/ar
|
|||||||
option fp add VFPv2 FP_DBL
|
option fp add VFPv2 FP_DBL
|
||||||
optalias vfpv2 fp
|
optalias vfpv2 fp
|
||||||
option nofp remove ALL_FP
|
option nofp remove ALL_FP
|
||||||
diff -NBaur gcc-8.1.0/gcc/config/arm/t-arm-elf gcc-8.1.0-arm/gcc/config/arm/t-arm-elf
|
diff --git a/gcc/config/arm/t-arm-elf b/gcc/config/arm/t-arm-elf
|
||||||
--- gcc-8.1.0/gcc/config/arm/t-arm-elf 2018-01-11 15:21:26.000000000 +0000
|
index 9ec5bf065ac..9ab3ffb109d 100644
|
||||||
+++ gcc-8.1.0-arm/gcc/config/arm/t-arm-elf 2018-05-10 23:15:13.124566279 +0000
|
--- a/gcc/config/arm/t-arm-elf
|
||||||
|
+++ b/gcc/config/arm/t-arm-elf
|
||||||
@@ -1,4 +1,4 @@
|
@@ -1,4 +1,4 @@
|
||||||
-# Copyright (C) 1998-2018 Free Software Foundation, Inc.
|
-# Copyright (C) 1998-2018 Free Software Foundation, Inc.
|
||||||
+# Copyright (C) 1998-2017 Free Software Foundation, Inc.
|
+# Copyright (C) 1998-2017 Free Software Foundation, Inc.
|
||||||
@@ -105,25 +107,22 @@ diff -NBaur gcc-8.1.0/gcc/config/arm/t-arm-elf gcc-8.1.0-arm/gcc/config/arm/t-ar
|
|||||||
-
|
-
|
||||||
-MULTILIB_MATCHES += $(foreach FPARCH, $(v7a_fps), \
|
-MULTILIB_MATCHES += $(foreach FPARCH, $(v7a_fps), \
|
||||||
- march?armv7+fp=march?armv7-a+$(FPARCH))
|
- march?armv7+fp=march?armv7-a+$(FPARCH))
|
||||||
|
-
|
||||||
-MULTILIB_MATCHES += $(foreach FPARCH, $(v7ve_fps), \
|
-MULTILIB_MATCHES += $(foreach FPARCH, $(v7ve_fps), \
|
||||||
- march?armv7+fp=march?armv7ve+$(FPARCH))
|
- march?armv7+fp=march?armv7ve+$(FPARCH))
|
||||||
+MULTILIB_REQUIRED = mthumb mbig-endian mthumb/mbig-endian march=armv6k/mfloat-abi=hard
|
-
|
||||||
|
|
||||||
-MULTILIB_MATCHES += $(foreach ARCH, $(all_v7_a_r), \
|
-MULTILIB_MATCHES += $(foreach ARCH, $(all_v7_a_r), \
|
||||||
- march?armv7+fp=march?$(ARCH) \
|
- march?armv7+fp=march?$(ARCH) \
|
||||||
- march?armv7+fp=march?$(ARCH)+fp)
|
- march?armv7+fp=march?$(ARCH)+fp)
|
||||||
|
-
|
||||||
-MULTILIB_MATCHES += $(foreach ARCH, $(all_v8_archs), \
|
-MULTILIB_MATCHES += $(foreach ARCH, $(all_v8_archs), \
|
||||||
- march?armv7+fp=march?$(ARCH) \
|
- march?armv7+fp=march?$(ARCH) \
|
||||||
- $(foreach FPARCH, $(v8_fps), \
|
- $(foreach FPARCH, $(v8_fps), \
|
||||||
- march?armv7+fp=march?$(ARCH)+$(FPARCH)))
|
- march?armv7+fp=march?$(ARCH)+$(FPARCH)))
|
||||||
+MULTILIB_MATCHES += march?armv6k=mtune?mpcore
|
-
|
||||||
+MULTILIB_MATCHES += march?armv6k=mcpu?mpcore
|
|
||||||
|
|
||||||
-MULTILIB_MATCHES += $(foreach ARCH, armv7e-m armv8-m.mainline, \
|
-MULTILIB_MATCHES += $(foreach ARCH, armv7e-m armv8-m.mainline, \
|
||||||
- march?armv7+fp=march?$(ARCH)+fp.dp)
|
- march?armv7+fp=march?$(ARCH)+fp.dp)
|
||||||
|
-
|
||||||
-# PART 4 - Reuse rules
|
-# PART 4 - Reuse rules
|
||||||
|
|
||||||
-MULTILIB_REUSE += mthumb=mthumb/mfpu.auto
|
-MULTILIB_REUSE += mthumb=mthumb/mfpu.auto
|
||||||
@@ -135,6 +134,14 @@ diff -NBaur gcc-8.1.0/gcc/config/arm/t-arm-elf gcc-8.1.0-arm/gcc/config/arm/t-ar
|
|||||||
-MULTILIB_REUSE += mthumb/mfpu.auto/march.armv7+fp/mfloat-abi.hard=mthumb/march.armv7+fp/mfloat-abi.hard
|
-MULTILIB_REUSE += mthumb/mfpu.auto/march.armv7+fp/mfloat-abi.hard=mthumb/march.armv7+fp/mfloat-abi.hard
|
||||||
-MULTILIB_REUSE += mthumb/mfpu.auto/march.armv7+fp/mfloat-abi.hard=mfpu.auto/march.armv7+fp/mfloat-abi.hard
|
-MULTILIB_REUSE += mthumb/mfpu.auto/march.armv7+fp/mfloat-abi.hard=mfpu.auto/march.armv7+fp/mfloat-abi.hard
|
||||||
-MULTILIB_REUSE += mthumb/mfpu.auto/march.armv7+fp/mfloat-abi.hard=march.armv7+fp/mfloat-abi.hard
|
-MULTILIB_REUSE += mthumb/mfpu.auto/march.armv7+fp/mfloat-abi.hard=march.armv7+fp/mfloat-abi.hard
|
||||||
|
+MULTILIB_REQUIRED = mthumb mbig-endian mthumb/mbig-endian march=armv6k/mfloat-abi=hard
|
||||||
|
+
|
||||||
|
+
|
||||||
|
+MULTILIB_MATCHES += march?armv6k=mtune?mpcore
|
||||||
|
+MULTILIB_MATCHES += march?armv6k=mcpu?mpcore
|
||||||
|
+
|
||||||
|
+
|
||||||
|
+
|
||||||
+#MULTILIB_OPTIONS += mcpu=fa526/mcpu=fa626/mcpu=fa606te/mcpu=fa626te/mcpu=fmp626/mcpu=fa726te
|
+#MULTILIB_OPTIONS += mcpu=fa526/mcpu=fa626/mcpu=fa606te/mcpu=fa626te/mcpu=fmp626/mcpu=fa726te
|
||||||
+#MULTILIB_DIRNAMES += fa526 fa626 fa606te fa626te fmp626 fa726te
|
+#MULTILIB_DIRNAMES += fa526 fa626 fa606te fa626te fmp626 fa726te
|
||||||
+#MULTILIB_EXCEPTIONS += *mthumb*/*mcpu=fa526 *mthumb*/*mcpu=fa626
|
+#MULTILIB_EXCEPTIONS += *mthumb*/*mcpu=fa526 *mthumb*/*mcpu=fa626
|
||||||
@@ -202,9 +209,10 @@ diff -NBaur gcc-8.1.0/gcc/config/arm/t-arm-elf gcc-8.1.0-arm/gcc/config/arm/t-ar
|
|||||||
+# MULTILIB_MATCHES += mcpu?arm7=mcpu?arm600
|
+# MULTILIB_MATCHES += mcpu?arm7=mcpu?arm600
|
||||||
+# MULTILIB_MATCHES += mcpu?arm7=mcpu?arm610
|
+# MULTILIB_MATCHES += mcpu?arm7=mcpu?arm610
|
||||||
+# MULTILIB_MATCHES += mcpu?arm7=mcpu?arm620
|
+# MULTILIB_MATCHES += mcpu?arm7=mcpu?arm620
|
||||||
diff -NBaur gcc-8.1.0/gcc/config/arm/unknown-elf.h gcc-8.1.0-arm/gcc/config/arm/unknown-elf.h
|
diff --git a/gcc/config/arm/unknown-elf.h b/gcc/config/arm/unknown-elf.h
|
||||||
--- gcc-8.1.0/gcc/config/arm/unknown-elf.h 2018-01-03 10:03:58.000000000 +0000
|
index 12dd0931b08..59584fe64bc 100644
|
||||||
+++ gcc-8.1.0-arm/gcc/config/arm/unknown-elf.h 2018-05-10 23:01:02.432676190 +0000
|
--- a/gcc/config/arm/unknown-elf.h
|
||||||
|
+++ b/gcc/config/arm/unknown-elf.h
|
||||||
@@ -29,7 +29,7 @@
|
@@ -29,7 +29,7 @@
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -225,10 +233,11 @@ diff -NBaur gcc-8.1.0/gcc/config/arm/unknown-elf.h gcc-8.1.0-arm/gcc/config/arm/
|
|||||||
+#undef NO_IMPLICIT_EXTERN_C
|
+#undef NO_IMPLICIT_EXTERN_C
|
||||||
+#define NO_IMPLICIT_EXTERN_C
|
+#define NO_IMPLICIT_EXTERN_C
|
||||||
+
|
+
|
||||||
diff -NBaur gcc-8.1.0/gcc/gcc.c gcc-8.1.0-arm/gcc/gcc.c
|
diff --git a/gcc/gcc.c b/gcc/gcc.c
|
||||||
--- gcc-8.1.0/gcc/gcc.c 2018-02-09 06:44:06.000000000 +0000
|
index a716f708259..6a11011dba7 100644
|
||||||
+++ gcc-8.1.0-arm/gcc/gcc.c 2018-05-10 23:01:02.440676328 +0000
|
--- a/gcc/gcc.c
|
||||||
@@ -786,6 +786,11 @@
|
+++ b/gcc/gcc.c
|
||||||
|
@@ -786,6 +786,11 @@ proper position among the other output files. */
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -240,7 +249,7 @@ diff -NBaur gcc-8.1.0/gcc/gcc.c gcc-8.1.0-arm/gcc/gcc.c
|
|||||||
/* config.h can define STARTFILE_SPEC to override the default crt0 files. */
|
/* config.h can define STARTFILE_SPEC to override the default crt0 files. */
|
||||||
#ifndef STARTFILE_SPEC
|
#ifndef STARTFILE_SPEC
|
||||||
#define STARTFILE_SPEC \
|
#define STARTFILE_SPEC \
|
||||||
@@ -1081,6 +1086,7 @@
|
@@ -1081,6 +1086,7 @@ static const char *link_spec = LINK_SPEC;
|
||||||
static const char *lib_spec = LIB_SPEC;
|
static const char *lib_spec = LIB_SPEC;
|
||||||
static const char *link_gomp_spec = "";
|
static const char *link_gomp_spec = "";
|
||||||
static const char *libgcc_spec = LIBGCC_SPEC;
|
static const char *libgcc_spec = LIBGCC_SPEC;
|
||||||
@@ -248,7 +257,7 @@ diff -NBaur gcc-8.1.0/gcc/gcc.c gcc-8.1.0-arm/gcc/gcc.c
|
|||||||
static const char *endfile_spec = ENDFILE_SPEC;
|
static const char *endfile_spec = ENDFILE_SPEC;
|
||||||
static const char *startfile_spec = STARTFILE_SPEC;
|
static const char *startfile_spec = STARTFILE_SPEC;
|
||||||
static const char *linker_name_spec = LINKER_NAME;
|
static const char *linker_name_spec = LINKER_NAME;
|
||||||
@@ -1577,6 +1583,7 @@
|
@@ -1577,6 +1583,7 @@ static struct spec_list static_specs[] =
|
||||||
INIT_STATIC_SPEC ("lib", &lib_spec),
|
INIT_STATIC_SPEC ("lib", &lib_spec),
|
||||||
INIT_STATIC_SPEC ("link_gomp", &link_gomp_spec),
|
INIT_STATIC_SPEC ("link_gomp", &link_gomp_spec),
|
||||||
INIT_STATIC_SPEC ("libgcc", &libgcc_spec),
|
INIT_STATIC_SPEC ("libgcc", &libgcc_spec),
|
||||||
@@ -256,19 +265,21 @@ diff -NBaur gcc-8.1.0/gcc/gcc.c gcc-8.1.0-arm/gcc/gcc.c
|
|||||||
INIT_STATIC_SPEC ("startfile", &startfile_spec),
|
INIT_STATIC_SPEC ("startfile", &startfile_spec),
|
||||||
INIT_STATIC_SPEC ("cross_compile", &cross_compile),
|
INIT_STATIC_SPEC ("cross_compile", &cross_compile),
|
||||||
INIT_STATIC_SPEC ("version", &compiler_version),
|
INIT_STATIC_SPEC ("version", &compiler_version),
|
||||||
diff -NBaur gcc-8.1.0/libgcc/config/arm/t-bpabi gcc-8.1.0-arm/libgcc/config/arm/t-bpabi
|
diff --git a/libgcc/config/arm/t-bpabi b/libgcc/config/arm/t-bpabi
|
||||||
--- gcc-8.1.0/libgcc/config/arm/t-bpabi 2012-08-17 15:06:06.000000000 +0000
|
index dddddc7c444..c2502597953 100644
|
||||||
+++ gcc-8.1.0-arm/libgcc/config/arm/t-bpabi 2018-05-10 23:01:02.440676328 +0000
|
--- a/libgcc/config/arm/t-bpabi
|
||||||
@@ -17,4 +17,4 @@
|
+++ b/libgcc/config/arm/t-bpabi
|
||||||
|
@@ -17,4 +17,4 @@ SHLIB_MAPFILES += $(srcdir)/config/arm/libgcc-bpabi.ver
|
||||||
# On ARM, specifying -fnon-call-exceptions will needlessly pull in
|
# On ARM, specifying -fnon-call-exceptions will needlessly pull in
|
||||||
# the unwinder in simple programs which use 64-bit division. Omitting
|
# the unwinder in simple programs which use 64-bit division. Omitting
|
||||||
# the option is safe.
|
# the option is safe.
|
||||||
-LIB2_DIVMOD_EXCEPTION_FLAGS := -fexceptions
|
-LIB2_DIVMOD_EXCEPTION_FLAGS := -fexceptions
|
||||||
+LIB2_DIVMOD_EXCEPTION_FLAGS := -fno-exceptions
|
+LIB2_DIVMOD_EXCEPTION_FLAGS := -fno-exceptions
|
||||||
diff -NBaur gcc-8.1.0/libgcc/crtstuff.c gcc-8.1.0-arm/libgcc/crtstuff.c
|
diff --git a/libgcc/crtstuff.c b/libgcc/crtstuff.c
|
||||||
--- gcc-8.1.0/libgcc/crtstuff.c 2018-01-03 10:03:58.000000000 +0000
|
index 5e894455e16..f81c9c6a64c 100644
|
||||||
+++ gcc-8.1.0-arm/libgcc/crtstuff.c 2018-05-10 23:01:02.440676328 +0000
|
--- a/libgcc/crtstuff.c
|
||||||
@@ -47,7 +47,7 @@
|
+++ b/libgcc/crtstuff.c
|
||||||
|
@@ -47,7 +47,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
|
||||||
|
|
||||||
/* Target machine header files require this define. */
|
/* Target machine header files require this define. */
|
||||||
#define IN_LIBGCC2
|
#define IN_LIBGCC2
|
||||||
@@ -277,15 +288,3 @@ diff -NBaur gcc-8.1.0/libgcc/crtstuff.c gcc-8.1.0-arm/libgcc/crtstuff.c
|
|||||||
/* FIXME: Including auto-host is incorrect, but until we have
|
/* FIXME: Including auto-host is incorrect, but until we have
|
||||||
identified the set of defines that need to go into auto-target.h,
|
identified the set of defines that need to go into auto-target.h,
|
||||||
this will have to do. */
|
this will have to do. */
|
||||||
diff -NBaur gcc-8.1.0/libgcc/Makefile.in gcc-8.1.0-arm/libgcc/Makefile.in
|
|
||||||
--- gcc-8.1.0/libgcc/Makefile.in 2018-01-03 10:03:58.000000000 +0000
|
|
||||||
+++ gcc-8.1.0-arm/libgcc/Makefile.in 2018-05-10 23:01:02.440676328 +0000
|
|
||||||
@@ -847,7 +847,7 @@
|
|
||||||
# libgcc_eh.a, only LIB2ADDEH matters. If we do, only LIB2ADDEHSTATIC and
|
|
||||||
# LIB2ADDEHSHARED matter. (Usually all three are identical.)
|
|
||||||
|
|
||||||
-c_flags := -fexceptions
|
|
||||||
+c_flags := -fno-exceptions
|
|
||||||
|
|
||||||
ifeq ($(enable_shared),yes)
|
|
||||||
|
|
||||||
@@ -1,29 +1,7 @@
|
|||||||
diff --git a/gdb/Makefile.in b/gdb/Makefile.in
|
diff -NBaur gdb-8.2/gdb/arm-3ds-tdep.c gdb-8.2-3ds/gdb/arm-3ds-tdep.c
|
||||||
index 1d2dbaf3f7..2d24f09c1b 100644
|
--- gdb-8.2/gdb/arm-3ds-tdep.c 1970-01-01 01:00:00.000000000 +0100
|
||||||
--- a/gdb/Makefile.in
|
+++ gdb-8.2-3ds/gdb/arm-3ds-tdep.c 2018-11-15 22:55:21.916968907 +0000
|
||||||
+++ b/gdb/Makefile.in
|
@@ -0,0 +1,157 @@
|
||||||
@@ -779,6 +779,7 @@ ALL_64_TARGET_OBS = \
|
|
||||||
ALL_TARGET_OBS = \
|
|
||||||
arc-tdep.o \
|
|
||||||
arm.o \
|
|
||||||
+ arm-3ds-tdep.o \
|
|
||||||
arm-bsd-tdep.o \
|
|
||||||
arm-get-next-pcs.o \
|
|
||||||
arm-linux.o \
|
|
||||||
@@ -2487,6 +2488,7 @@ ALLDEPFILES = \
|
|
||||||
amd64-tdep.c \
|
|
||||||
arc-tdep.c \
|
|
||||||
arm.c \
|
|
||||||
+ arm-3ds-tdep.c \
|
|
||||||
arm-bsd-tdep.c \
|
|
||||||
arm-get-next-pcs.c \
|
|
||||||
arm-linux.c \
|
|
||||||
diff --git a/gdb/arm-3ds-tdep.c b/gdb/arm-3ds-tdep.c
|
|
||||||
new file mode 100644
|
|
||||||
index 0000000000..ad014e28db
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/gdb/arm-3ds-tdep.c
|
|
||||||
@@ -0,0 +1,197 @@
|
|
||||||
+/* Target-dependent code for 3DS. */
|
+/* Target-dependent code for 3DS. */
|
||||||
+
|
+
|
||||||
+/* This uses code from GDB, which license is: */
|
+/* This uses code from GDB, which license is: */
|
||||||
@@ -95,48 +73,11 @@ index 0000000000..ad014e28db
|
|||||||
+ return next_pc;
|
+ return next_pc;
|
||||||
+}
|
+}
|
||||||
+
|
+
|
||||||
+static VEC (CORE_ADDR) *
|
|
||||||
+arm_3ds_software_single_step (struct regcache *regcache)
|
|
||||||
+{
|
|
||||||
+ struct gdbarch *gdbarch = get_regcache_arch (regcache);
|
|
||||||
+ struct arm_get_next_pcs next_pcs_ctx;
|
|
||||||
+ CORE_ADDR pc;
|
|
||||||
+ int i;
|
|
||||||
+ VEC (CORE_ADDR) *next_pcs = NULL;
|
|
||||||
+ struct cleanup *old_chain;
|
|
||||||
+
|
|
||||||
+ /* If the target does have hardware single step, GDB doesn't have
|
|
||||||
+ to bother software single step. */
|
|
||||||
+ if (target_can_do_single_step () == 1)
|
|
||||||
+ return NULL;
|
|
||||||
+
|
|
||||||
+ old_chain = make_cleanup (VEC_cleanup (CORE_ADDR), &next_pcs);
|
|
||||||
+
|
|
||||||
+ arm_get_next_pcs_ctor (&next_pcs_ctx,
|
|
||||||
+ &arm_3ds_get_next_pcs_ops,
|
|
||||||
+ gdbarch_byte_order (gdbarch),
|
|
||||||
+ gdbarch_byte_order_for_code (gdbarch),
|
|
||||||
+ 1,
|
|
||||||
+ regcache);
|
|
||||||
+
|
|
||||||
+ next_pcs = arm_get_next_pcs (&next_pcs_ctx);
|
|
||||||
+
|
|
||||||
+ for (i = 0; VEC_iterate (CORE_ADDR, next_pcs, i, pc); i++)
|
|
||||||
+ {
|
|
||||||
+ pc = gdbarch_addr_bits_remove (gdbarch, pc);
|
|
||||||
+ VEC_replace (CORE_ADDR, next_pcs, i, pc);
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
+ discard_cleanups (old_chain);
|
|
||||||
+
|
|
||||||
+ return next_pcs;
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+static LONGEST
|
+static LONGEST
|
||||||
+arm_3ds_get_syscall_number (struct gdbarch *gdbarch,
|
+arm_3ds_get_syscall_number (struct gdbarch *gdbarch,
|
||||||
+ ptid_t ptid)
|
+ thread_info *thread)
|
||||||
+{
|
+{
|
||||||
+ struct regcache *regs = get_thread_regcache (ptid);
|
+ struct regcache *regs = get_thread_regcache (thread);
|
||||||
+
|
+
|
||||||
+ ULONGEST pc;
|
+ ULONGEST pc;
|
||||||
+ ULONGEST cpsr;
|
+ ULONGEST cpsr;
|
||||||
@@ -205,42 +146,35 @@ index 0000000000..ad014e28db
|
|||||||
+ tdep->fp_model = ARM_FLOAT_VFP;
|
+ tdep->fp_model = ARM_FLOAT_VFP;
|
||||||
+
|
+
|
||||||
+ /* Single stepping. */
|
+ /* Single stepping. */
|
||||||
+ set_gdbarch_software_single_step (gdbarch, arm_3ds_software_single_step);
|
+ set_gdbarch_software_single_step (gdbarch, arm_software_single_step);
|
||||||
+
|
+
|
||||||
+ /* `catch syscall' */
|
+ /* `catch syscall' */
|
||||||
+ set_xml_syscall_file_name (gdbarch, "syscalls/arm-3ds.xml");
|
+ set_xml_syscall_file_name (gdbarch, "syscalls/arm-3ds.xml");
|
||||||
+ set_gdbarch_get_syscall_number (gdbarch, arm_3ds_get_syscall_number);
|
+ set_gdbarch_get_syscall_number (gdbarch, arm_3ds_get_syscall_number);
|
||||||
+}
|
+}
|
||||||
+
|
+
|
||||||
+/* Provide a prototype to silence -Wmissing-prototypes. */
|
|
||||||
+extern initialize_file_ftype _initialize_arm_3ds_tdep;
|
|
||||||
+
|
|
||||||
+void
|
+void
|
||||||
+_initialize_arm_3ds_tdep (void)
|
+_initialize_arm_3ds_tdep (void)
|
||||||
+{
|
+{
|
||||||
+ gdbarch_register_osabi (bfd_arch_arm, 0, GDB_OSABI_3DS,
|
+ gdbarch_register_osabi (bfd_arch_arm, 0, GDB_OSABI_3DS,
|
||||||
+ arm_3ds_init_abi);
|
+ arm_3ds_init_abi);
|
||||||
+}
|
+}
|
||||||
diff --git a/gdb/configure.tgt b/gdb/configure.tgt
|
diff -NBaur gdb-8.2/gdb/configure.tgt gdb-8.2-3ds/gdb/configure.tgt
|
||||||
index fdcb7b1d69..d8fd1622b8 100644
|
--- gdb-8.2/gdb/configure.tgt 2018-09-05 08:44:28.000000000 +0100
|
||||||
--- a/gdb/configure.tgt
|
+++ gdb-8.2-3ds/gdb/configure.tgt 2018-11-15 22:47:17.337689978 +0000
|
||||||
+++ b/gdb/configure.tgt
|
@@ -61,7 +61,7 @@
|
||||||
@@ -119,8 +119,8 @@ arm*-*-symbianelf*)
|
|
||||||
gdb_target_obs="arm.o arm-get-next-pcs.o arm-tdep.o arm-symbian-tdep.o"
|
|
||||||
;;
|
|
||||||
arm*-*-*)
|
|
||||||
- # Target: ARM embedded system
|
|
||||||
- gdb_target_obs="arm.o arm-get-next-pcs.o arm-tdep.o"
|
|
||||||
+ # Target: ARM embedded system (+ 3DS)
|
|
||||||
+ gdb_target_obs="arm.o arm-get-next-pcs.o arm-tdep.o arm-3ds-tdep.o"
|
|
||||||
gdb_sim=../sim/arm/libsim.a
|
|
||||||
;;
|
;;
|
||||||
|
|
||||||
diff --git a/gdb/data-directory/Makefile.in b/gdb/data-directory/Makefile.in
|
arm*-*-*)
|
||||||
index 304d4b05c0..2cf8986d3a 100644
|
- cpu_obs="arch/arm.o arch/arm-get-next-pcs.o arm-tdep.o";;
|
||||||
--- a/gdb/data-directory/Makefile.in
|
+ cpu_obs="arch/arm.o arch/arm-get-next-pcs.o arm-tdep.o arm-3ds-tdep.o";;
|
||||||
+++ b/gdb/data-directory/Makefile.in
|
|
||||||
@@ -63,7 +63,7 @@ GEN_SYSCALLS_FILES = \
|
hppa*-*-*)
|
||||||
|
# Target: HP PA-RISC
|
||||||
|
diff -NBaur gdb-8.2/gdb/data-directory/Makefile.in gdb-8.2-3ds/gdb/data-directory/Makefile.in
|
||||||
|
--- gdb-8.2/gdb/data-directory/Makefile.in 2018-01-05 04:07:23.000000000 +0000
|
||||||
|
+++ gdb-8.2-3ds/gdb/data-directory/Makefile.in 2018-11-15 22:42:36.840956065 +0000
|
||||||
|
@@ -63,7 +63,7 @@
|
||||||
sparc-linux.xml \
|
sparc-linux.xml \
|
||||||
sparc64-linux.xml
|
sparc64-linux.xml
|
||||||
|
|
||||||
@@ -249,11 +183,10 @@ index 304d4b05c0..2cf8986d3a 100644
|
|||||||
|
|
||||||
PYTHON_DIR = python
|
PYTHON_DIR = python
|
||||||
PYTHON_INSTALL_DIR = $(DESTDIR)$(GDB_DATADIR)/$(PYTHON_DIR)
|
PYTHON_INSTALL_DIR = $(DESTDIR)$(GDB_DATADIR)/$(PYTHON_DIR)
|
||||||
diff --git a/gdb/defs.h b/gdb/defs.h
|
diff -NBaur gdb-8.2/gdb/defs.h gdb-8.2-3ds/gdb/defs.h
|
||||||
index a0b586f401..a1508fd5b3 100644
|
--- gdb-8.2/gdb/defs.h 2018-09-05 08:27:32.000000000 +0100
|
||||||
--- a/gdb/defs.h
|
+++ gdb-8.2-3ds/gdb/defs.h 2018-11-15 22:42:36.840956065 +0000
|
||||||
+++ b/gdb/defs.h
|
@@ -495,6 +495,7 @@
|
||||||
@@ -604,6 +604,7 @@ enum gdb_osabi
|
|
||||||
GDB_OSABI_LYNXOS178,
|
GDB_OSABI_LYNXOS178,
|
||||||
GDB_OSABI_NEWLIB,
|
GDB_OSABI_NEWLIB,
|
||||||
GDB_OSABI_SDE,
|
GDB_OSABI_SDE,
|
||||||
@@ -261,11 +194,29 @@ index a0b586f401..a1508fd5b3 100644
|
|||||||
|
|
||||||
GDB_OSABI_INVALID /* keep this last */
|
GDB_OSABI_INVALID /* keep this last */
|
||||||
};
|
};
|
||||||
diff --git a/gdb/osabi.c b/gdb/osabi.c
|
diff -NBaur gdb-8.2/gdb/Makefile.in gdb-8.2-3ds/gdb/Makefile.in
|
||||||
index 84fa9c0273..c1c4bb1672 100644
|
--- gdb-8.2/gdb/Makefile.in 2018-09-05 08:44:28.000000000 +0100
|
||||||
--- a/gdb/osabi.c
|
+++ gdb-8.2-3ds/gdb/Makefile.in 2018-11-15 22:45:01.628931262 +0000
|
||||||
+++ b/gdb/osabi.c
|
@@ -684,6 +684,7 @@
|
||||||
@@ -79,6 +79,7 @@ static const struct osabi_names gdb_osabi_names[] =
|
arch/arm-linux.o \
|
||||||
|
arch/i386.o \
|
||||||
|
arch/ppc-linux-common.o \
|
||||||
|
+ arm-3ds-tdep.o \
|
||||||
|
arm-bsd-tdep.o \
|
||||||
|
arm-fbsd-tdep.o \
|
||||||
|
arm-linux-tdep.o \
|
||||||
|
@@ -2213,6 +2214,7 @@
|
||||||
|
amd64-tdep.c \
|
||||||
|
arc-tdep.c \
|
||||||
|
arm.c \
|
||||||
|
+ arm-3ds-tdep.c \
|
||||||
|
arm-bsd-tdep.c \
|
||||||
|
arm-fbsd-nat.c \
|
||||||
|
arm-fbsd-tdep.c \
|
||||||
|
diff -NBaur gdb-8.2/gdb/osabi.c gdb-8.2-3ds/gdb/osabi.c
|
||||||
|
--- gdb-8.2/gdb/osabi.c 2018-09-05 08:27:13.000000000 +0100
|
||||||
|
+++ gdb-8.2-3ds/gdb/osabi.c 2018-11-15 22:42:36.840956065 +0000
|
||||||
|
@@ -80,6 +80,7 @@
|
||||||
{ "LynxOS178", NULL },
|
{ "LynxOS178", NULL },
|
||||||
{ "Newlib", NULL },
|
{ "Newlib", NULL },
|
||||||
{ "SDE", NULL },
|
{ "SDE", NULL },
|
||||||
@@ -273,11 +224,9 @@ index 84fa9c0273..c1c4bb1672 100644
|
|||||||
|
|
||||||
{ "<invalid>", NULL }
|
{ "<invalid>", NULL }
|
||||||
};
|
};
|
||||||
diff --git a/gdb/syscalls/arm-3ds.xml b/gdb/syscalls/arm-3ds.xml
|
diff -NBaur gdb-8.2/gdb/syscalls/arm-3ds.xml gdb-8.2-3ds/gdb/syscalls/arm-3ds.xml
|
||||||
new file mode 100644
|
--- gdb-8.2/gdb/syscalls/arm-3ds.xml 1970-01-01 01:00:00.000000000 +0100
|
||||||
index 0000000000..48780b7bd5
|
+++ gdb-8.2-3ds/gdb/syscalls/arm-3ds.xml 2018-11-15 22:42:36.840956065 +0000
|
||||||
--- /dev/null
|
|
||||||
+++ b/gdb/syscalls/arm-3ds.xml
|
|
||||||
@@ -0,0 +1,159 @@
|
@@ -0,0 +1,159 @@
|
||||||
+<?xml version="1.0"?>
|
+<?xml version="1.0"?>
|
||||||
+<!DOCTYPE syscalls_info SYSTEM "gdb-syscalls.dtd">
|
+<!DOCTYPE syscalls_info SYSTEM "gdb-syscalls.dtd">
|
||||||
@@ -438,4 +387,3 @@ index 0000000000..48780b7bd5
|
|||||||
+ <syscall name="TranslateHandle" number="178" groups="custom,synchronization,ipc,thread,process,debug"/>
|
+ <syscall name="TranslateHandle" number="178" groups="custom,synchronization,ipc,thread,process,debug"/>
|
||||||
+
|
+
|
||||||
+</syscalls_info>
|
+</syscalls_info>
|
||||||
|
|
||||||
@@ -7531,7 +7531,7 @@ index 2900b332f..6efb54eb3 100644
|
|||||||
#ifdef __rtems__
|
#ifdef __rtems__
|
||||||
diff --git a/newlib/libc/include/sys/iosupport.h b/newlib/libc/include/sys/iosupport.h
|
diff --git a/newlib/libc/include/sys/iosupport.h b/newlib/libc/include/sys/iosupport.h
|
||||||
new file mode 100644
|
new file mode 100644
|
||||||
index 000000000..ee14d2610
|
index 000000000..dfed4107e
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/newlib/libc/include/sys/iosupport.h
|
+++ b/newlib/libc/include/sys/iosupport.h
|
||||||
@@ -0,0 +1,112 @@
|
@@ -0,0 +1,112 @@
|
||||||
@@ -7553,7 +7553,7 @@ index 000000000..ee14d2610
|
|||||||
+ STD_IN,
|
+ STD_IN,
|
||||||
+ STD_OUT,
|
+ STD_OUT,
|
||||||
+ STD_ERR,
|
+ STD_ERR,
|
||||||
+ STD_MAX = 16
|
+ STD_MAX = 35
|
||||||
+};
|
+};
|
||||||
+
|
+
|
||||||
+
|
+
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ if [ ! -f configured-binutils ]
|
|||||||
then
|
then
|
||||||
CPPFLAGS="$cppflags $CPPFLAGS" LDFLAGS=$ldflags ../../binutils-$BINUTILS_VER/configure \
|
CPPFLAGS="$cppflags $CPPFLAGS" LDFLAGS=$ldflags ../../binutils-$BINUTILS_VER/configure \
|
||||||
--prefix=$prefix --target=$target --disable-nls --disable-werror \
|
--prefix=$prefix --target=$target --disable-nls --disable-werror \
|
||||||
--enable-lto --enable-plugins --enable-gold \
|
--enable-lto --enable-plugins \
|
||||||
--enable-poison-system-directories \
|
--enable-poison-system-directories \
|
||||||
$CROSS_PARAMS \
|
$CROSS_PARAMS \
|
||||||
|| { echo "Error configuring binutils"; exit 1; }
|
|| { echo "Error configuring binutils"; exit 1; }
|
||||||
@@ -64,7 +64,7 @@ then
|
|||||||
--prefix=$prefix \
|
--prefix=$prefix \
|
||||||
--enable-lto\
|
--enable-lto\
|
||||||
--with-system-zlib \
|
--with-system-zlib \
|
||||||
--with-bugurl="http://wiki.devkitpro.org/index.php/Bug_Reports" --with-pkgversion="devkitARM release 49" \
|
--with-bugurl="http://wiki.devkitpro.org/index.php/Bug_Reports" --with-pkgversion="devkitARM release 50" \
|
||||||
$CROSS_PARAMS \
|
$CROSS_PARAMS \
|
||||||
$CROSS_GCC_PARAMS \
|
$CROSS_GCC_PARAMS \
|
||||||
|| { echo "Error configuring gcc"; exit 1; }
|
|| { echo "Error configuring gcc"; exit 1; }
|
||||||
|
|||||||
@@ -30,10 +30,10 @@ done
|
|||||||
|
|
||||||
case "$VERSION" in
|
case "$VERSION" in
|
||||||
"1" )
|
"1" )
|
||||||
GCC_VER=8.1.0
|
GCC_VER=8.2.0
|
||||||
BINUTILS_VER=2.30
|
BINUTILS_VER=2.31.1
|
||||||
NEWLIB_VER=3.0.0
|
NEWLIB_VER=3.0.0
|
||||||
GDB_VER=8.0
|
GDB_VER=8.2
|
||||||
basedir='dkarm-eabi'
|
basedir='dkarm-eabi'
|
||||||
package=devkitARM
|
package=devkitARM
|
||||||
target=arm-none-eabi
|
target=arm-none-eabi
|
||||||
|
|||||||
Reference in New Issue
Block a user