[openstack-dev] Packaging pain tales

Mark McLoughlin markmc at redhat.com
Wed Jan 23 21:46:02 UTC 2013

On Wed, 2013-01-23 at 17:28 +0100, Ionuț Arțăriși wrote:
> On 01/23/2013 05:07 PM, Mark McLoughlin wrote:
> > On Wed, 2013-01-23 at 16:22 +0100, Sascha Peilicke wrote:
> >> A while ago, we were even able
> >> to use daily git checkouts for package building but for reasons
> >> described in [1][2], we had to move away from git checkouts.
> > Can you look at this again and describe why you can't go back to using
> > git checkouts?
> >
> >
> We've discussed that before in the mailing list thread that Sascha 
> mentioned in his email. We can't use git checkouts because it would mean 
> distributing the whole .git repository in our srpms in order to run the 
> python setup.py sdist command with setuptools_git.

There are basically two options now if you want to build  package from a
given git commit and include information about the commit in the package

  - build a tarball using 'python setup.py sdist' and build your RPM 
    using that - the commit id is included in the tarball name, 
    toplevel directory name and PKG-INFO file

  - if you take a git checkout and remove it's .git dir, you need to 
    record the git commit id, construct a version number with it and 
    pass it via the OSLO_PACKAGE_VERSION env variable


More information about the OpenStack-dev mailing list