[Fedora-packaging] remove source files

Tom Lane tgl at redhat.com
Thu Feb 11 00:35:39 UTC 2010


Ville =?iso-8859-1?q?Skytt=E4?= <ville.skytta at iki.fi> writes:
> On Thursday 11 February 2010, Scott Frankel wrote:
>> I'm using a simple spec file to package a python-based application for
>> distribution.  When passed to rpmbuild, it creates an rpm with both
>> source (.py) and bytecode compiled (.pyc) files.  I'd like to remove
>> the source files from the rpm.

> Try this in %files:
> %exclude /path/to/stuff/*.py

Even easier: after running "make install" in the specfile script, just
"rm" the files you don't want from the install tree.

As noted, this particular case doesn't seem to be a good idea, but when
you do want to exclude files it's certainly easy enough.

			regards, tom lane


More information about the packaging mailing list