Debian – Creating deb and rpm from the same source

debianfedorapackagingpython

Is there a standard for source packages to be able to build rpms, debs (and perhaps others) without too much customization?

I'm talking mostly about Python, PyQt programs.

Best Answer

FPM can build debs/rpms from python packages on PyPI or from a local setup.py file. You can build a deb with

fpm -s python -t deb $package-name-on-pypi

or

fpm -s python -t deb setup.py

Building packages in other formats only requires you to change the -t (target type) parameter.

To produce debs I can also recommend python-stdeb.

Related Question