David Howells <dhowe...@redhat.com> wrote:

> Josh Boyer <jwbo...@gmail.com> 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@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Reply via email to