cliechti | 8864126 | 2002-07-29 02:09:04 +0000 | [diff] [blame] | 1 | #!/usr/bin/env python |
cliechti | 8e778b1 | 2008-06-20 23:11:57 +0000 | [diff] [blame] | 2 | # setup.py |
| 3 | try: |
| 4 | from setuptools import setup |
| 5 | except ImportError: |
| 6 | print "standart distutils" |
| 7 | from distutils.core import setup |
| 8 | else: |
| 9 | print "setuptools" |
| 10 | import sys |
| 11 | |
| 12 | #windows installer: |
| 13 | # python setup.py bdist_wininst |
| 14 | |
| 15 | # patch distutils if it can't cope with the "classifiers" or |
| 16 | # "download_url" keywords |
| 17 | if sys.version < '2.2.3': |
| 18 | from distutils.dist import DistributionMetadata |
| 19 | DistributionMetadata.classifiers = None |
| 20 | DistributionMetadata.download_url = None |
cliechti | 8864126 | 2002-07-29 02:09:04 +0000 | [diff] [blame] | 21 | |
cliechti | 49a8ecf | 2003-03-19 02:33:54 +0000 | [diff] [blame] | 22 | import os |
| 23 | if os.name == 'nt': |
cliechti | 8e778b1 | 2008-06-20 23:11:57 +0000 | [diff] [blame] | 24 | print "# set dependedcies for windows version" |
cliechti | a7bafcb | 2005-01-27 00:47:15 +0000 | [diff] [blame] | 25 | data_files = {'parallel': ['simpleio.dll']} |
cliechti | 49a8ecf | 2003-03-19 02:33:54 +0000 | [diff] [blame] | 26 | else: |
cliechti | 8e778b1 | 2008-06-20 23:11:57 +0000 | [diff] [blame] | 27 | print "# no dependedcies" |
cliechti | 85ca4ee | 2005-11-02 18:54:21 +0000 | [diff] [blame] | 28 | data_files = {} |
cliechti | 49a8ecf | 2003-03-19 02:33:54 +0000 | [diff] [blame] | 29 | |
cliechti | 8e778b1 | 2008-06-20 23:11:57 +0000 | [diff] [blame] | 30 | setup( |
| 31 | name = "pyparallel", |
cliechti | 8864126 | 2002-07-29 02:09:04 +0000 | [diff] [blame] | 32 | description="Python Parallel Port Extension", |
cliechti | a7bafcb | 2005-01-27 00:47:15 +0000 | [diff] [blame] | 33 | version="0.2", |
cliechti | 8864126 | 2002-07-29 02:09:04 +0000 | [diff] [blame] | 34 | author="Chris Liechti", |
| 35 | author_email="cliechti@gmx.net", |
| 36 | url="http://pyserial.sourceforge.net/", |
| 37 | packages=['parallel'], |
| 38 | license="Python", |
| 39 | long_description="Python Parallel Port Extension for Win32, Linux, BSD", |
cliechti | 8e778b1 | 2008-06-20 23:11:57 +0000 | [diff] [blame] | 40 | classifiers = [ |
| 41 | 'Development Status :: 4 - Beta', |
| 42 | 'Intended Audience :: Developers', |
| 43 | 'License :: OSI Approved :: Python Software Foundation License', |
| 44 | 'Natural Language :: English', |
| 45 | 'Operating System :: POSIX', |
| 46 | 'Operating System :: Microsoft :: Windows', |
| 47 | 'Programming Language :: Python', |
| 48 | 'Topic :: Communications', |
| 49 | 'Topic :: Software Development :: Libraries', |
| 50 | ], |
| 51 | package_data = data_files |
cliechti | 8864126 | 2002-07-29 02:09:04 +0000 | [diff] [blame] | 52 | ) |