Re: How to prevent a binary from being stripped by rpmbuild?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



David Howells <dhowells@xxxxxxxxxx> wrote:

> Josh Boyer <jwboyer@xxxxxxxxx> wrote:
> 
> > You might also want to redefine %{__strip} to the appropriate
> > cross-strip utility, or /bin/true.  Something like:
> > 
> > %define debug_package %{nil}
> > %define __strip /bin/true
> 
> Ah, so I can make a shell script to apply the appropriate strip binary...

Like so:

	%define __ar_no_strip $RPM_BUILD_DIR/%{srcdir}/ar-no-strip
	cat >%{__ar_no_strip} <<EOF
	#!/bin/bash
	f=\$2
	if [ \${f##*/} = libgcc.a -o \${f##*/} = libgcov.a ]
	then
		:
	else
		%{__strip} \$*
	fi
	EOF
	chmod +x %{__ar_no_strip}
	%undefine __strip
	%define __strip %{__ar-no-strip}

Interestingly, it only seems to be used for static libraries.

David
-- 
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/devel



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux