[PATCH 2/5] Assume only FLAG_ELF_LIBC6 suport
Alexander Monakov
amonakov@ispras.ru
Thu Dec 7 13:14:53 GMT 2023
On Tue, 2 Aug 2022, Adhemerval Zanella via Libc-alpha wrote:
> From: "Lucas A. M. Magalhaes" <lamm@linux.ibm.com>
>
> The older libc versions are obsolete for over twenty years now.
> This patch removes the special flags for libc5 and libc4 and assumes
> that all libraries cached are libc6 compatible and use FLAG_ELF_LIBC6.
>
> Checked with a build for all affected architectures.
>
> Co-authored-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
> Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
> --- a/elf/readelflib.c
> +++ b/elf/readelflib.c
> @@ -110,16 +108,6 @@ process_elf_file (const char *file_name, const char *lib, int *flag,
> program_interpreter = (char *) (file_contents + segment->p_offset);
> check_ptr (program_interpreter);
>
> - /* Check if this is enough to classify the binary. */
> - for (j = 0; j < sizeof (interpreters) / sizeof (interpreters [0]);
> - ++j)
> - if (strcmp (program_interpreter, interpreters[j].soname) == 0)
> - {
> - *flag = interpreters[j].flag;
> - break;
> - }
> - break;
> -
> case PT_GNU_PROPERTY:
> /* The NT_GNU_PROPERTY_TYPE_0 note must be aligned to 4 bytes
> in 32-bit objects and to 8 bytes in 64-bit objects. Skip
This hunk removes a 'break', resulting in a nonsensical
fall-through from 'case PT_INTERP' to 'case PT_GNU_PROPERTY'.
Alexander
More information about the Libc-alpha
mailing list