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

Re: RFS: python-goopy



On Mon, Aug 22, 2005 at 07:40:35AM +0530, Kumar Appaiah wrote:
> On Sun, Aug 21, 2005 at 08:51:43PM +0200, Christoph Haas wrote:

> > Thomas is right that it's not trivial to create multi-binary packages.
> > I'd upload your package if you just want to do a package for Python 2.3.
> > Perhaps you want to look at another Python package though. I believe
> > that http://packages.qa.debian.org/p/python-mysqldb.html would be a good
> > example. Look at the debian/control file there.
> 
> If there is a right waty of doing it, I must learn it!
> 
> So, I borrowed a few things from python-imaging, and now have a neat
> setup to generate python-goopy, python2.3-goopy and python2.4-goopy
> from a single control file single rules and a single source "tree"
> (directory). It wasn't difficult, though it did take some time.
> 
> In case you still have enthusiasm remaining, the current stuff is at
> http://kumar.travisbsd.org/debpackages and it is more "standards
> adherent", as it used debhelper more wisely.
> 
> Now, I have identified three more things which are to be done:
> 
> 1.docs: Upstream claims that they have docs, but there aren't
>   any. Anyway, the source is well commented. What should I do with the
>   README and PKG-INFO?
Documentation should be in an architecture independent package if it
is of any substatial size.  Include whatever documentation you feel
might be useful for an end user.  It is typical to leave out the "how
to compile" document, since Debian is a "binary distribution".

> 2.There is one file, functional_unittest.py which is executable. Now,
>   its permissions get set to 644 even if I add a
>   -Xfunctional_unittest.py to dh_fixperms.
You can just chmod it (them?) from the fules file to give it whatever
permissions you want.

> 3.functional_unittest.py has #!/usr/bin/env python at the
>   top. Standards demand that it should be #!/usr/bin/python2.x for the
>   appropriate Python version. Is there a standard way to take care of
>   this or do I write some sed substitution do do it?
You can do sed, or you can use a patch.  There are elaborate patch
systems for Debianization, such as dpatch, but it sounds like you
don't need it at all.  Just modify the file, and call "debuild" or
whatever your favorite frontend is; it will regenerate the
diff.gz, which will then include a patch fragment which changes the
first line.

But, if you are making multiple binary packages, for multiple python
versions (As I recall), then sed seems appropriate:

	name='./path/functional_unittest.py';
	sed -i -e '1 s,.*,#!/usr/bin/python2.2,' ./debian/foo-2.2/$name
	sed -i -e '1 s,.*,#!/usr/bin/python2.4,' ./debian/foo-2.4/$name

Clear skies,
Justin



Reply to: