X-Git-Url: https://git.mxchange.org/?p=quix0rs-apt-p2p.git;a=blobdiff_plain;f=setup.py;h=189af152c34d87574d967ab46fa443afc8536c85;hp=7e75b639fc6b58ccb73d6d412f2555baa568d901;hb=66a54d42206699aeab07c7e5d70609d25651e9eb;hpb=99afa9dfc4dff7b47bccb33d037c7ebf5c2c8b02 diff --git a/setup.py b/setup.py index 7e75b63..189af15 100755 --- a/setup.py +++ b/setup.py @@ -1,57 +1,25 @@ #!/usr/bin/env python -try: - import distutils.core - import distutils.command.build_ext -except ImportError: - raise SystemExit, """\ -You don't have the python development modules installed. +import sys +from distutils.core import setup -If you have Debian you can install it by running - apt-get install python-dev +from debian_bundle import changelog -If you have RedHat and know how to install this from an RPM please -email us so we can put instructions here. -""" +f = open('debian/changelog') +data = f.read() +f.close() +c = changelog.Changelog(file=data, max_blocks=1) +del data -try: - import twisted -except ImportError: - raise SystemExit, """\ -You don't have Twisted installed. +setup( + name = "apt-p2p", + version = c.full_version, + author = "Cameron Dale", + author_email = "", + url = "http://www.camrdale.org/apt-p2p.html", + license = "GPL", -Twisted can be downloaded from - http://twistedmatrix.com/products/download + packages = ["apt_p2p", "apt_p2p_Khashmir"], -Anything later that version 1.0.3 should work -""" - -try: - import pysqlite2 -except ImportError: - raise SystemExit, """\ -You don't have PySQLite installed. - -PySQLite can be downloaded from - http://sourceforge.net/project/showfiles.php?group_id=54058&release_id=139482 -""" - -setup_args = { - 'name': 'khashmir', - 'author': 'Andrew Loewenstern', - 'author_email': 'burris@users.sourceforge.net', - 'licence': 'MIT', - 'package_dir': {'khashmir': '.'}, - 'packages': [ - 'khashmir', - ], -} - -if hasattr(distutils.dist.DistributionMetadata, 'get_keywords'): - setup_args['keywords'] = "internet tcp p2p" - -if hasattr(distutils.dist.DistributionMetadata, 'get_platforms'): - setup_args['platforms'] = "win32 posix" - -if __name__ == '__main__': - apply(distutils.core.setup, (), setup_args) + scripts = ['apt-p2p.py'] + )