source: python/setup.py @ 164980f

feature/autosinkfeature/cnnfeature/cnn_orgfeature/constantqfeature/crepefeature/crepe_orgfeature/pitchshiftfeature/pydocstringsfeature/timestretchfix/ffmpeg5pitchshiftsamplertimestretchyinfft+
Last change on this file since 164980f was 164980f, checked in by Paul Brossier <piem@piem.org>, 11 years ago

python/: move source files to ext/

  • Property mode set to 100755
File size: 2.4 KB
Line 
1#! /usr/bin/python
2
3from distutils.core import setup, Extension
4from generator import generate_object_files
5import sys
6import os.path
7import numpy
8
9# read from VERSION
10for l in open(os.path.join('..','VERSION')).readlines(): exec (l.strip())
11__version__ = '.'.join \
12        ([str(x) for x in [AUBIO_MAJOR_VERSION, AUBIO_MINOR_VERSION, AUBIO_PATCH_VERSION]]) \
13        + AUBIO_VERSION_STATUS
14
15library_dirs = ['../build/src', '../src/.libs']
16include_dirs = ['../build/src', '../src', '.' ]
17library_dirs = filter (lambda x: os.path.isdir(x), library_dirs)
18include_dirs = filter (lambda x: os.path.isdir(x), include_dirs)
19
20aubio_extension = Extension("aubio._aubio", [
21            "ext/aubiomodule.c",
22            "ext/aubioproxy.c",
23            "ext/ufuncs.c",
24            "ext/py-cvec.c",
25            # example without macro
26            "ext/py-filter.c",
27            # macroised
28            "ext/py-filterbank.c",
29            "ext/py-fft.c",
30            "ext/py-phasevoc.c",
31            # generated files
32            ] + generate_object_files(),
33        include_dirs = include_dirs + [ numpy.get_include() ],
34        library_dirs = library_dirs,
35        libraries=['aubio'])
36
37if sys.platform.startswith('darwin'):
38        aubio_extension.extra_link_args = ['-framework','CoreFoundation', '-framework','AudioToolbox']
39
40classifiers = [
41        'Development Status :: 4 - Beta',
42        'Environment :: Console',
43        'Intended Audience :: Science/Research',
44        'Topic :: Software Development :: Libraries',
45        'Topic :: Multimedia :: Sound/Audio :: Analysis',
46        'Topic :: Multimedia :: Sound/Audio :: Sound Synthesis',
47        'Operating System :: POSIX',
48        'Operating System :: MacOS :: MacOS X',
49        'Operating System :: Microsoft :: Windows',
50        'Programming Language :: C',
51        'Programming Language :: Python',
52        'License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)',
53        ]
54
55distrib = setup(name='aubio',
56        version = __version__,
57        packages = ['aubio'],
58        ext_modules = [aubio_extension],
59        description = 'interface to the aubio library',
60        long_description = 'interface to the aubio library',
61        license = 'GNU/GPL version 3',
62        author = 'Paul Brossier',
63        author_email = 'piem@aubio.org',
64        maintainer = 'Paul Brossier',
65        maintainer_email = 'piem@aubio.org',
66        url = 'http://aubio.org/',
67        platforms = 'any',
68        classifiers = classifiers,
69        )
70
Note: See TracBrowser for help on using the repository browser.