diff options
| author | Michael Forney <mforney@mforney.org> | 2020-08-13 01:32:28 -0700 |
|---|---|---|
| committer | Michael Forney <mforney@mforney.org> | 2020-08-13 01:32:28 -0700 |
| commit | 04f09bac7b28e001356019296ec83d318332f7e8 (patch) | |
| tree | 4df4f7a18e8625c5add70ea70aa906c8358f3cb4 /pkg | |
| parent | 18dcc504b518cfaeb9031a0acbd03655d9df2924 (diff) | |
elftoolchain: Add patch to fix build of Linux 5.8
Diffstat (limited to 'pkg')
| -rw-r--r-- | pkg/elftoolchain/patch/0005-gelf_symshndx-allow-xndxdata-parameter-to-be-NULL.patch | 38 | ||||
| -rw-r--r-- | pkg/elftoolchain/ver | 2 |
2 files changed, 39 insertions, 1 deletions
diff --git a/pkg/elftoolchain/patch/0005-gelf_symshndx-allow-xndxdata-parameter-to-be-NULL.patch b/pkg/elftoolchain/patch/0005-gelf_symshndx-allow-xndxdata-parameter-to-be-NULL.patch new file mode 100644 index 00000000..72f7b1a4 --- /dev/null +++ b/pkg/elftoolchain/patch/0005-gelf_symshndx-allow-xndxdata-parameter-to-be-NULL.patch @@ -0,0 +1,38 @@ +From c7e6c81df0d0c04b6ff585b95cbade36a7bfbe47 Mon Sep 17 00:00:00 2001 +From: Ethan Sommer <e5ten.arch@gmail.com> +Date: Mon, 3 Aug 2020 12:47:08 -0400 +Subject: [PATCH] gelf_symshndx: allow xndxdata parameter to be NULL + +Only retrieve extended section index for the symbol if xndxdata is +non-NULL + +Signed-off-by: Ethan Sommer <e5ten.arch@gmail.com> +--- + libelf/gelf_symshndx.c | 11 ++++++++--- + 1 file changed, 8 insertions(+), 3 deletions(-) + +diff --git a/libelf/gelf_symshndx.c b/libelf/gelf_symshndx.c +index 93ce2dba..601fb95e 100644 +--- a/libelf/gelf_symshndx.c ++++ b/libelf/gelf_symshndx.c +@@ -48,9 +48,14 @@ gelf_getsymshndx(Elf_Data *d, Elf_Data *id, int ndx, GElf_Sym *dst, + if (gelf_getsym(d, ndx, dst) == 0) + return (NULL); + +- if (lid == NULL || (scn = lid->d_scn) == NULL || +- (e = scn->s_elf) == NULL || (e != ld->d_scn->s_elf) || +- shindex == NULL) { ++ if (lid == NULL) { ++ if (shindex) ++ *shindex = 0; ++ return (dst); ++ } ++ ++ if ((scn = lid->d_scn) == NULL || (e = scn->s_elf) == NULL || ++ (e != ld->d_scn->s_elf) || shindex == NULL) { + LIBELF_SET_ERROR(ARGUMENT, 0); + return (NULL); + } +-- +2.28.0 + diff --git a/pkg/elftoolchain/ver b/pkg/elftoolchain/ver index b4aba240..18a845a2 100644 --- a/pkg/elftoolchain/ver +++ b/pkg/elftoolchain/ver @@ -1 +1 @@ -0.7.1 r1 +0.7.1 r2 |
