added my Recipes
This commit is contained in:
@@ -0,0 +1,99 @@
|
||||
From afae74e88e7cef05a22d5c50b662172d201b7b48 Mon Sep 17 00:00:00 2001
|
||||
From: Richard Purdie <richard.purdie@linuxfoundation.org>
|
||||
Date: Wed, 19 Feb 2020 09:51:16 -0800
|
||||
Subject: [PATCH] binutils-nativesdk: Search for alternative ld.so.conf in SDK
|
||||
installation
|
||||
|
||||
We need binutils to look at our ld.so.conf file within the SDK to ensure
|
||||
we search the SDK's libdirs as well as those from the host system.
|
||||
|
||||
We therefore pass in the directory to the code using a define, then add
|
||||
it to a section we relocate in a similar way to the way we relocate the
|
||||
gcc internal paths. This ensures that ld works correctly in our buildtools
|
||||
tarball.
|
||||
|
||||
Standard sysroot relocation doesn't work since we're not in a sysroot,
|
||||
we want to use both the host system and SDK libs.
|
||||
|
||||
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
||||
2020/1/17
|
||||
Upstream-Status: Inappropriate [OE specific tweak]
|
||||
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
|
||||
---
|
||||
ld/Makefile.am | 3 ++-
|
||||
ld/Makefile.in | 3 ++-
|
||||
ld/ldelf.c | 2 +-
|
||||
ld/ldmain.c | 1 +
|
||||
ld/ldmain.h | 1 +
|
||||
5 files changed, 7 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/ld/Makefile.am b/ld/Makefile.am
|
||||
index 4df3f718f80..1b875904b8d 100644
|
||||
--- a/ld/Makefile.am
|
||||
+++ b/ld/Makefile.am
|
||||
@@ -42,7 +42,8 @@ ZLIBINC = @zlibinc@
|
||||
|
||||
ELF_CLFAGS=-DELF_LIST_OPTIONS=@elf_list_options@ \
|
||||
-DELF_SHLIB_LIST_OPTIONS=@elf_shlib_list_options@ \
|
||||
- -DELF_PLT_UNWIND_LIST_OPTIONS=@elf_plt_unwind_list_options@
|
||||
+ -DELF_PLT_UNWIND_LIST_OPTIONS=@elf_plt_unwind_list_options@ \
|
||||
+ -DSYSCONFDIR="\"$(sysconfdir)\""
|
||||
WARN_CFLAGS = @WARN_CFLAGS@
|
||||
NO_WERROR = @NO_WERROR@
|
||||
AM_CFLAGS = $(WARN_CFLAGS) $(ELF_CLFAGS) $(JANSSON_CFLAGS) $(ZSTD_CFLAGS)
|
||||
diff --git a/ld/Makefile.in b/ld/Makefile.in
|
||||
index 13997650f58..17c58dd2fd0 100644
|
||||
--- a/ld/Makefile.in
|
||||
+++ b/ld/Makefile.in
|
||||
@@ -569,7 +569,8 @@ ZLIB = @zlibdir@ -lz
|
||||
ZLIBINC = @zlibinc@
|
||||
ELF_CLFAGS = -DELF_LIST_OPTIONS=@elf_list_options@ \
|
||||
-DELF_SHLIB_LIST_OPTIONS=@elf_shlib_list_options@ \
|
||||
- -DELF_PLT_UNWIND_LIST_OPTIONS=@elf_plt_unwind_list_options@
|
||||
+ -DELF_PLT_UNWIND_LIST_OPTIONS=@elf_plt_unwind_list_options@ \
|
||||
+ -DSYSCONFDIR="\"$(sysconfdir)\""
|
||||
|
||||
AM_CFLAGS = $(WARN_CFLAGS) $(ELF_CLFAGS) $(JANSSON_CFLAGS) $(ZSTD_CFLAGS)
|
||||
|
||||
diff --git a/ld/ldelf.c b/ld/ldelf.c
|
||||
index 747b47123c2..925da4cff34 100644
|
||||
--- a/ld/ldelf.c
|
||||
+++ b/ld/ldelf.c
|
||||
@@ -936,7 +936,7 @@ ldelf_check_ld_so_conf (const struct bfd_link_needed_list *l, int force,
|
||||
|
||||
info.path = NULL;
|
||||
info.len = info.alloc = 0;
|
||||
- tmppath = concat (ld_sysroot, prefix, "/etc/ld.so.conf",
|
||||
+ tmppath = concat (ld_sysconfdir, "/ld.so.conf",
|
||||
(const char *) NULL);
|
||||
if (!ldelf_parse_ld_so_conf (&info, tmppath))
|
||||
{
|
||||
diff --git a/ld/ldmain.c b/ld/ldmain.c
|
||||
index ca1b1a8f0fb..62e7b4e5341 100644
|
||||
--- a/ld/ldmain.c
|
||||
+++ b/ld/ldmain.c
|
||||
@@ -70,6 +70,7 @@ char *program_name;
|
||||
|
||||
/* The prefix for system library directories. */
|
||||
const char *ld_sysroot;
|
||||
+char ld_sysconfdir[4096] __attribute__ ((section (".gccrelocprefix"))) = SYSCONFDIR;
|
||||
|
||||
/* The canonical representation of ld_sysroot. */
|
||||
char *ld_canon_sysroot;
|
||||
diff --git a/ld/ldmain.h b/ld/ldmain.h
|
||||
index dda124b96e8..ba06a7d7be2 100644
|
||||
--- a/ld/ldmain.h
|
||||
+++ b/ld/ldmain.h
|
||||
@@ -23,6 +23,7 @@
|
||||
|
||||
extern char *program_name;
|
||||
extern const char *ld_sysroot;
|
||||
+extern char ld_sysconfdir[4096];
|
||||
extern char *ld_canon_sysroot;
|
||||
extern int ld_canon_sysroot_len;
|
||||
extern FILE *saved_script_handle;
|
||||
--
|
||||
2.25.1
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
# look for files in the layer first
|
||||
FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
FILESEXTRAPATHS:prepend := "${THISDIR}:"
|
||||
|
||||
SRC_URI:append = "file://gdb/0010-fix-gdb-cross-arm-compilation-with-YOCTO-build-syste.patch"
|
||||
@@ -0,0 +1,38 @@
|
||||
From 02370e466c7cda9347c9a6d65a160fdd41e91cbe Mon Sep 17 00:00:00 2001
|
||||
From: Vincent ABRIOU <vincent.abriou@st.com>
|
||||
Date: Thu, 13 Apr 2023 18:28:55 +0200
|
||||
Subject: [PATCH 10/10] fix gdb-cross-arm compilation with YOCTO build system
|
||||
|
||||
Issue meet while compiling:
|
||||
linux-tdep.c:(.text+0x13ac): undefined reference to
|
||||
`gcore_elf_build_thread_register_notes(gdbarch*, thread_info*, gdb_signal,
|
||||
bfd*, std::unique_ptr<char, gdb::xfree_deleter<char> >*, int*)'
|
||||
linux-tdep.c:(.text+0x49d7): undefined reference to
|
||||
`gcore_elf_make_tdesc_note(bfd*, std::unique_ptr<char,
|
||||
gdb::xfree_deleter<char> >*, int*)'
|
||||
|
||||
|
||||
Patch inspired fro this discussion.
|
||||
https://lists.openembedded.org/g/openembedded-core/message/177970
|
||||
|
||||
Signed-off-by: Vincent ABRIOU <vincent.abriou@st.com>
|
||||
---
|
||||
gdb/configure | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/gdb/configure b/gdb/configure
|
||||
index bdc84be9c01..2179743d3ab 100755
|
||||
--- a/gdb/configure
|
||||
+++ b/gdb/configure
|
||||
@@ -28561,7 +28561,7 @@ WIN32LIBS="$WIN32LIBS $WIN32APILIBS"
|
||||
# points somewhere with bfd, with -I/foo/lib and -L/foo/lib. We
|
||||
# always want our bfd.
|
||||
CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
|
||||
- LDFLAGS="-L../bfd -L../libiberty"
|
||||
+ LDFLAGS="-L../bfd -L../libiberty $LDFLAGS"
|
||||
intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
|
||||
LIBS="-lbfd -liberty $intl $LIBS"
|
||||
CC="./libtool --quiet --mode=link $CC"
|
||||
--
|
||||
2.25.1
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
From 31c4a53fb0f7538850e0814bdecfc927a36433d4 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?C=C3=A9dric=20VINCENT?= <cedric.vincent@st.com>
|
||||
Date: Wed, 20 Nov 2019 16:33:28 +0100
|
||||
Subject: [PATCH] Add support for ARM Thumb branches with instruction-set
|
||||
exchange.
|
||||
|
||||
This is issue has been detected on OpenSTLinux 2019-10-09, where
|
||||
ltrace failed to single-step on a "bx lr" instruction when tracing
|
||||
weston-simple-egl.
|
||||
---
|
||||
sysdeps/linux-gnu/arm/trace.c | 8 ++++++++
|
||||
1 file changed, 8 insertions(+)
|
||||
|
||||
diff --git a/sysdeps/linux-gnu/arm/trace.c b/sysdeps/linux-gnu/arm/trace.c
|
||||
index 54632f3..7475f81 100644
|
||||
--- a/sysdeps/linux-gnu/arm/trace.c
|
||||
+++ b/sysdeps/linux-gnu/arm/trace.c
|
||||
@@ -430,6 +430,14 @@ thumb_get_next_pcs(struct process *proc,
|
||||
}
|
||||
} else if ((inst1 & 0xf800) == 0xe000) { /* unconditional branch */
|
||||
next_pcs[nr++] = pc + (SBITS(inst1, 0, 10) << 1);
|
||||
+ } else if ((inst1 & 0xff07) == 0x4700) { /* branch with exchange */
|
||||
+ const enum arm_register reg = BITS(inst1, 3, 6);
|
||||
+ uint32_t next;
|
||||
+
|
||||
+ if (arm_get_register(proc, reg, &next) < 0)
|
||||
+ return -1;
|
||||
+
|
||||
+ next_pcs[nr++] = (arch_addr_t) (next & 0xfffffffe);
|
||||
} else if (thumb_insn_size(inst1) == 4) { /* 32-bit instruction */
|
||||
unsigned short inst2;
|
||||
if (proc_read_16(proc, pc + 2, &inst2) < 0)
|
||||
--
|
||||
2.20.1
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
|
||||
|
||||
SRC_URI:append = " file://0001-Add-support-for-ARM-Thumb-branches-with-instruction-.patch "
|
||||
Reference in New Issue
Block a user