[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: python packaging example with debhelper, dh_pysupport and dh_python2



[Thomas Bechtold, 2011-03-11]
> i tried to understand the correct way to package a python module with
> debhelper, dh_pysupport and dh_python2.

you can use either dh_pysupport or dh_python2, passing --with python2 to
dh sequencer (which you use) will disable (default) dh_pysupport

> I created a python-helloworld example package ( get it from
> https://code.launchpad.net/~toabctl/+junk/python-helloworld ) and want
> to know if i used the correct way to package a simple python module.

please also take a look at py2dsc script (from python-stdeb package)
 
> questions are:
> - are the package dependencies correct or do i need some more substvars?

${python:Depends} is enough

> - what exactly should do dh_python2 and do i need both, dh_pysupport
> _and_ dh_python2? i just found the manpage and [1] as dh_python2
> documentation and don't exactly understand why i need dh_python2.

dh_python2 does the same thing dh_pysupport does, but in a differen't
way, see NOTES in dh_python2 manpage¹

> - How should i install the python module if i don't have a setup.py . i
> use the debian/install file and just copy all files
> to /usr/share/pyshared/helloworld . is this correct?

both helpers will pick these files up, with dh_python2 you can also use
debian/python-helloworld.pyinstall file (I will document it in the
manpage this weekend, for now, see debian-python thread²)

PS please ask on debian-python@l.d.o next time

[¹] http://deb.li/dhp2
[²] http://lists.debian.org/debian-python/2010/11/msg00063.html
-- 
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


Reply to: