[PATCH 1/2] elfclassify: Add --any-ar-member option to classify archive member
Mark Wielaard
mark@klomp.org
Sat Aug 30 12:37:58 GMT 2025
Hi Aaron,
On Thu, Aug 28, 2025 at 08:25:52PM -0400, Aaron Merey wrote:
> On Thu, Aug 28, 2025 at 12:44 PM Mark Wielaard <mark@klomp.org> wrote:
> >
> > To determine whether an ELF archive contains a member of a particular
> > type add a new input option to eu-elfclassify --any-ar-member.
> > eu-elfclassify will match if a given file is an ELF archive and the
> > classification options apply to at least one of the members.
> >
> > This can be used for example to check whether an ELF archive file
> > contains ELF members that can be stripped by using:
> >
> > eu-elfclassify --ar-member --unstripped <ar-file>
> >
> > * src/elfclassify.c (current_path): Drop const.
> > (flag_ar_member): New static bool.
> > (classify_flag_ar_member): new enum member.
> > (parse_opt): Handle classify_flag_ar_member.
> > (check_checks): New function taken from...
> > (process_current_path): ...here.
> > (check_ar_members): New function.
> > (main): Add ar-member to options. Update argp.doc.
> > * tests/run-elfclassify.sh: Add various --any-ar-member tests.
> >
> > Signed-off-by: Mark Wielaard <mark@klomp.org>
>
> This series LGTM. This version builds properly and avoids the
> -Werror=restrict false positive we saw with the RFC.
Thanks. I pused both commits to main.
Cheers,
Mark
More information about the Elfutils-devel
mailing list