Some Python Packaging Questions

Jeff Pitman symbiont at berlios.de
Tue Aug 24 09:10:58 UTC 2004


On Tuesday 24 August 2004 15:36, Michael Schwendt wrote:
> That doesn't include directories (IIRC) and would need extra effort
> when you want to %ghost *.pyo files.

That is the suck!  Thanks for pointing that out.  That would cause all 
sorts of littering.  Maybe we should push a patch to upstream distutils 
that includes directories or a more well-rounded approach that includes 
file options.  --rpm-record or something would be a neat option to 
setup.py.

I was going to recommend this one liner:

sed 's/\(.*\.pyo\)/%ghost \1/' < INSTALLED_FILES > 
INSTALLED_FILES.ghostbusted

%files -f INSTALLED_FILES.ghostbusted
%doc README INSTALL LICENSE
%dir %{_libdir}/python?.?/site-packages/blah
%dir %{_libdir}/python?.?/site-packages/blah/subblah

But, the '%files -f' directive doesn't process %ghost as of RPM 4.3.1.  
Oh well, it's just more disk space anyway... still not convinced we 
absolutely need to ghost pyo files.

thanks,
-- 
-jeff





More information about the fedora-devel-list mailing list