PDA

View Full Version : RPMBUILD perl packaging problem


aks
13th August 2010, 10:55 AM
I'm trying to package python-zope-html. Since it requires a lot of non-standard perl dependencies which rpmbuild generates, I used the external method of using filter-provides and filter-requires file. I used the guide at http://fedoraproject.org/wiki/Packaging:Perl In my spec file, the changes go like this:

Source98: filter-provides.sh
Source99: filter-requires.sh
%global __perl_provides %{SOURCE98}
%global __perl_requires %{SOURCE99}

as suggested by this guide and the contents of the filter-provides file is:

#!/bin/sh
/usr/lib/rpm/perl.prov $* | sed -e '/perl(CGI)/d'
/usr/lib/rpm/perl.prov $* | sed -e '/perl(File::Temp)/d'
/usr/lib/rpm/perl.prov $* | sed -e '/perl(basexml.pl)/d'
/usr/lib/rpm/perl.prov $* | sed -e '/perl(commands.pl)/d'
/usr/lib/rpm/perl.prov $* | sed -e '/perl(config.pl)/d'
/usr/lib/rpm/perl.prov $* | sed -e '/perl(io.pl)/d'
/usr/lib/rpm/perl.prov $* | sed -e '/perl(upload_fck.pl)/d'
/usr/lib/rpm/perl.prov $* | sed -e '/perl(util.pl)/d'

and that for filter-requires file:

#!/bin/sh
/usr/lib/rpm/perl.req $* | sed -e '/perl(CGI)/d'
/usr/lib/rpm/perl.req $* | sed -e '/perl(File::Temp)/d'
/usr/lib/rpm/perl.req $* | sed -e '/perl(basexml.pl)/d'
/usr/lib/rpm/perl.req $* | sed -e '/perl(commands.pl)/d'
/usr/lib/rpm/perl.req $* | sed -e '/perl(config.pl)/d'
/usr/lib/rpm/perl.req $* | sed -e '/perl(io.pl)/d'
/usr/lib/rpm/perl.req $* | sed -e '/perl(upload_fck.pl)/d'
/usr/lib/rpm/perl.req $* | sed -e '/perl(util.pl)/d'

But when I build the spec file (rpmbuild -ba python-zope-html.spec), I get following error:

error: Couldn't exec /home/aks/rpmbuild/SOURCES/filter-requires.sh: Permission denied
getOutputFrom(): Broken pipe

After I do chmod +x ~/rpmbuild/SOURCES/filter-*.sh, rpmbuild succeeds but unable to remove those perl dependencies. The difference between building the same spec file in F13 and F9 is that on F13, though creating a warning, it builds the package and removes those dependencies, but on F9 it just throws an error and quits. Any Solution for this?