From 5e4b10cf1ec7b499718dd826c230e4fbc6b27fe6 Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Wed, 18 Jul 2012 06:50:50 -0700 Subject: Don't use pbr for pbr. It turns out, that when you setup_requires pbr from another package, it gets installed via easy_install instead of via pip. easy_install, craptastic pile of vomit and excrement that it is, can't manage to process the entry points in the package it's installing while installing it, so you always wind up with pbr version=="". Sigh. Change-Id: Ib2b8e77662286fd4f86e9ccc55680cccc8ce349b --- setup.py | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/setup.py b/setup.py index bbf64a1..9519ff7 100644 --- a/setup.py +++ b/setup.py @@ -16,6 +16,10 @@ import pkg_resources import setuptools +import pbr +from pbr import cmdclass +from pbr import requires + def _fake_require(*args, **kwargs): """We need to block this from recursing - we're instaling an @@ -26,16 +30,22 @@ pkg_resources.EntryPoint.require = _fake_require setuptools.setup( name="pbr", - version="#:", + version=pbr.version_info.canonical_version_string(always=True), author='Hewlett-Packard Development Company, L.P.', author_email='openstack@lists.launchpad.net', description="Python Build Reasonableness", license="Apache License, Version 2.0", url="https://github.com/openstack-dev/pbr", - install_requires=['#:tools/pip-requires'], - tests_require=['#:tools/test-requires'], - dependency_links=['#:tools/pip-requires', '#:tools/test-requires'], + install_requires=requires.parse_requirements('tools/pip-requires'), + tests_require=requires.parse_requirements('tools/test-requires'), + dependency_links=requires.parse_dependency_links('tools/pip-requires', + 'tools/test-requires'), setup_requires=['setuptools-git>0.4'], + cmdclass=cmdclass.get_cmdclass('pbr/versioninfo'), + long_description=open('README.rst').read(), + include_package_data=True, + test_suite='nose.collector', + packages=setuptools.find_packages(exclude=['tests', 'tests.*']), classifiers=[ "Environment :: Console", "Intended Audience :: Developers", -- cgit v1.2.1