[Distutils] distributing only .pyc with stdeb

Piotr Ozarowski ozarow at gmail.com
Tue Nov 23 15:42:29 CET 2010

[Barry Warsaw, 2010-11-22]
> Not that it can't be done, but you'll probably have to write some custom
> debian/rules file to handle that case.

|#!/usr/bin/make -f
|	dh $@ --with python2
|	dh_python2
|	pycompile debian/python-foo/usr/lib/
|       # if you have different files for python2.X and python2.Y (i.e. pyshared is not used)
|	find debian/python-foo/usr/lib/ -name *.py -delete
|	rm -rf debian/python-foo/usr/share/pyshared/

should do the trick (not tested)
Piotr Ożarowski                         Debian GNU/Linux Developer
www.ozarowski.pl          www.griffith.cc           www.debian.org
GPG Fingerprint: 1D2F A898 58DA AF62 1786 2DF7 AEF6 F1A2 A745 7645

More information about the Distutils-SIG mailing list