[Build-common-hackers] Bug#494141: Bug#494141: no way to use get-orig-source with cdbs without breaking policy

Noah Slater nslater at bytesexual.org
Thu Aug 7 14:37:54 UTC 2008


On Thu, Aug 07, 2008 at 04:55:27PM +0300, Peter Eisentraut wrote:
> Yeah, you're right.  But I think get-orig-source is kind of obsolete.
> Everyone is using uscan now.

Well, a lot of people use uscan when available but many people also embed uscan
into the get-orig-source target as a matter of policy, the Erlang Packaging team
being the first example of this that springs to mind.

Here is a sample from couchdb, one of the Erlang packages:

  get-orig-source:
          uscan --force-download --repack --rename --destdir .

This may seem a little silly at first, but as soon as you get any level of
complexity involved in packaging the upstream source it suddenly makes a lot of
sense to be following policy and providing a consistent interface for grabbing
the upstream source across a large collection of packages.

I'm thinking specifically of both repackaging to remove components as happens
for a lot of Java packages or other non-free-upstream cases or more commonly
when the upstream source is non uscan-able, such as packages that are built
directly out of a repository or taken from an unversioned URI.

In these cases uscan is not able to fetch the upstream source and the
get-orig-source target is used to provide the same functionality.

Two examples of this from my own packages:

  get-orig-source:
          hg clone -r $(DEB_REPOS_VERSION) $(DEB_ORIG_URI) $(DEB_ORIG_DIRECTORY)
          tar -czf $(DEB_ORIG_FILENAME) $(DEB_ORIG_DIRECTORY) --exclude .hg
          rm -fr $(DEB_ORIG_DIRECTORY)

  - http://svn.debian.org/wsvn/python-apps/packages/phenny/trunk/debian/rules?op=file&rev=0&sc=0

  get-orig-source:
          bzr export -r $(DEB_REPOS_VERSION) $(DEB_ORIG_DIRECTORY) $(DEB_ORIG_URI)
          tar -czf $(DEB_ORIG_FILENAME) $(DEB_ORIG_DIRECTORY)
          rm -fr $(DEB_ORIG_DIRECTORY)

  - http://svn.debian.org/wsvn/python-apps/packages/planet-venus/trunk/debian/rules?op=file&rev=0&sc=0

I guess the upshot is that get-orig-source is still being used in quite a few
packages and is highly useful to a lot of people, certainly not obsolete.

It would be great if this situation was handled gracefully so that I'm not
forced to break policy in order to use CDBS, which totally rocks, by the way. :)

-- 
Noah Slater, http://bytesexual.org/nslater





More information about the Build-common-hackers mailing list