Add _clear_class and _backed_subclasses to PackageConfig.
[pypiezo.git] / setup.py
1 # Copyright (C) 2009-2011 W. Trevor King <wking@drexel.edu>
2 #
3 # This file is part of pypiezo.
4 #
5 # pypiezo is free software; you can redistribute it and/or modify it
6 # under the terms of the GNU General Public License as published by the
7 # Free Software Foundation, either version 3 of the License, or (at your
8 # option) any later version.
9 #
10 # pypiezo is distributed in the hope that it will be useful, but
11 # WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13 # General Public License for more details.
14 #
15 # You should have received a copy of the GNU General Public License
16 # along with pypiezo.  If not, see <http://www.gnu.org/licenses/>.
17
18 "Tools for controlling piezoelectric actuators."
19
20 from distutils.core import setup
21 from os import walk
22 import os.path
23
24 from pypiezo import __version__
25
26
27 package_name = 'pypiezo'
28 classifiers = """\
29 Development Status :: 2 - Pre-Alpha
30 Intended Audience :: Developers
31 Intended Audience :: Science/Research
32 Operating System :: POSIX
33 Operating System :: Unix
34 License :: OSI Approved :: GNU General Public License (GPL)
35 Programming Language :: Python
36 Topic :: Scientific/Engineering
37 Topic :: Software Development :: Libraries :: Python Modules
38 """
39
40 def find_packages(root='pypiezo'):
41     packages = []
42     prefix = '.'+os.path.sep
43     for dirpath,dirnames,filenames in walk(root):
44         if '__init__.py' in filenames:
45             if dirpath.startswith(prefix):
46                 dirpath = dirpath[len(prefix):]
47             packages.append(dirpath.replace(os.path.sep, '.'))
48     return packages
49
50 _this_dir = os.path.dirname(__file__)
51 packages = find_packages()
52
53 setup(name=package_name,
54       version=__version__,
55       maintainer='W. Trevor King',
56       maintainer_email='wking@drexel.edu',
57       url='http://www.physics.drexel.edu/~wking/unfolding-disasters/posts/%s/' % package_name,
58       download_url='http://www.physics.drexel.edu/~wking/code/python/%s-%s.tar.gz' % (package_name, __version__),
59       license='GNU General Public License (GPL)',
60       platforms=['all'],
61       description=__doc__,
62       long_description=open(os.path.join(_this_dir, 'README'), 'r').read(),
63       classifiers=filter(None, classifiers.split('\n')),
64       packages=packages,
65       provides=['pypiezo (%s)' % __version__],
66       requires=['pycomedi (>= 0.3)'],
67       )