[Rpm-maint] [PATCH] find-debuginfo.sh: Also pass -g to eu-strip for executables.
mjw at redhat.com
Thu Mar 26 11:23:10 UTC 2015
On Thu, 2015-03-19 at 14:15 +0100, Mark Wielaard wrote:
> The -g flag was only passed to eu-strip for shared libraries.
> Explicitly pass it also for executables. This also makes it more
> consistent since PIE executables were reported by file -bi as
Note that bug also contains a fix for mini symtab support, which doesn't
seem to have been upstreamed, but is a fedora extension. See
> scripts/find-debuginfo.sh | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
> diff --git a/scripts/find-debuginfo.sh b/scripts/find-debuginfo.sh
> index 264fad5..17522e0 100644
> --- a/scripts/find-debuginfo.sh
> +++ b/scripts/find-debuginfo.sh
> @@ -7,7 +7,7 @@
> # [[-l filelist]... [-p 'pattern'] -o debuginfo.list]
> # [builddir]
> -# The -g flag says to use strip -g instead of full strip on DSOs.
> +# The -g flag says to use strip -g instead of full strip on DSOs or EXEs.
> # The --strict-build-id flag says to exit with failure status if
> # any ELF binary processed fails to contain a build-id note.
> # The -r flag says to use eu-strip --reloc-debug-sections.
> @@ -23,7 +23,7 @@
> # All file names in switches are relative to builddir (. if not given).
> -# With -g arg, pass it to strip on libraries.
> +# With -g arg, pass it to strip on libraries or executables.
> # with -r arg, pass --reloc-debug-sections to eu-strip.
> @@ -100,6 +100,7 @@ strip_to_debug()
> $strip_r && r=--reloc-debug-sections
> $strip_g && case "$(file -bi "$2")" in
> application/x-sharedlib*) g=-g ;;
> + application/x-executable*) g=-g ;;
> eu-strip --remove-comment $r $g -f "$1" "$2" || exit
> chmod 444 "$1" || exit
More information about the Rpm-maint