Showing the changes to python/setup.py (1 of 2 files). Show all
Unified · Split
| @@ -1,6 +1,7 @@ | |||
| 1 | #! /usr/bin/python | 1 | #! /usr/bin/python |
| 2 | 2 | ||
| 3 | from distutils.core import setup, Extension | 3 | from distutils.core import setup, Extension |
| 4 | |||
| 4 | import sys | 5 | import sys |
| 5 | import os.path | 6 | import os.path |
| 6 | import numpy | 7 | import numpy |
| @@ -11,13 +12,18 @@ __version__ = '.'.join \ · 4 unmodified lines | |||
| 11 | ([str(x) for x in [AUBIO_MAJOR_VERSION, AUBIO_MINOR_VERSION, AUBIO_PATCH_VERSION]]) \ | 12 | ([str(x) for x in [AUBIO_MAJOR_VERSION, AUBIO_MINOR_VERSION, AUBIO_PATCH_VERSION]]) \ |
| 12 | + AUBIO_VERSION_STATUS | 13 | + AUBIO_VERSION_STATUS |
| 13 | 14 | ||
| 15 | |||
| 14 | include_dirs = [] | 16 | include_dirs = [] |
| 15 | library_dirs = [] | 17 | library_dirs = [] |
| 16 | define_macros = [] | 18 | define_macros = [] |
| 19 | extra_link_args = [] | ||
| 17 | 20 | ||
| 18 | include_dirs += ['ext'] | 21 | include_dirs += ['ext'] |
| 19 | include_dirs += [ numpy.get_include() ] | 22 | include_dirs += [ numpy.get_include() ] |
| 20 | 23 | ||
| 24 | if sys.platform.startswith('darwin'): | ||
| 25 | extra_link_args += ['-framework','CoreFoundation', '-framework','AudioToolbox'] | ||
| 26 | |||
| 21 | output_path = 'gen' | 27 | output_path = 'gen' |
| 22 | generated_object_files = [] | 28 | generated_object_files = [] |
| 23 | 29 | ||
| @@ -37,54 +43,51 @@ if os.path.isfile('../src/aubio.h'): · 13 unmodified lines | |||
| 37 | library_dirs += ['../build/src'] | 43 | library_dirs += ['../build/src'] |
| 38 | 44 | ||
| 39 | aubio_extension = Extension("aubio._aubio", [ | 45 | aubio_extension = Extension("aubio._aubio", [ |
| 40 | "ext/aubiomodule.c", | 46 | "ext/aubiomodule.c", |
| 41 | "ext/aubioproxy.c", | 47 | "ext/aubioproxy.c", |
| 42 | "ext/ufuncs.c", | 48 | "ext/ufuncs.c", |
| 43 | "ext/py-cvec.c", | 49 | "ext/py-cvec.c", |
| 44 | # example without macro | 50 | # example without macro |
| 45 | "ext/py-filter.c", | 51 | "ext/py-filter.c", |
| 46 | # macroised | 52 | # macroised |
| 47 | "ext/py-filterbank.c", | 53 | "ext/py-filterbank.c", |
| 48 | "ext/py-fft.c", | 54 | "ext/py-fft.c", |
| 49 | "ext/py-phasevoc.c", | 55 | "ext/py-phasevoc.c", |
| 50 | # generated files | 56 | # generated files |
| 51 | ] + generated_object_files, | 57 | ] + generated_object_files, |
| 52 | include_dirs = include_dirs, | 58 | include_dirs = include_dirs, |
| 53 | library_dirs = library_dirs, | 59 | library_dirs = library_dirs, |
| 54 | define_macros = define_macros, | 60 | extra_link_args = extra_link_args, |
| 55 | libraries=['aubio']) | 61 | define_macros = define_macros, |
| 56 | 62 | libraries=['aubio']) | |
| 57 | if sys.platform.startswith('darwin'): | ||
| 58 | aubio_extension.extra_link_args = ['-framework','CoreFoundation', '-framework','AudioToolbox'] | ||
| 59 | 63 | ||
| 60 | classifiers = [ | 64 | classifiers = [ |
| 61 | 'Development Status :: 4 - Beta', | 65 | 'Development Status :: 4 - Beta', |
| 62 | 'Environment :: Console', | 66 | 'Environment :: Console', |
| 63 | 'Intended Audience :: Science/Research', | 67 | 'Intended Audience :: Science/Research', |
| 64 | 'Topic :: Software Development :: Libraries', | 68 | 'Topic :: Software Development :: Libraries', |
| 65 | 'Topic :: Multimedia :: Sound/Audio :: Analysis', | 69 | 'Topic :: Multimedia :: Sound/Audio :: Analysis', |
| 66 | 'Topic :: Multimedia :: Sound/Audio :: Sound Synthesis', | 70 | 'Topic :: Multimedia :: Sound/Audio :: Sound Synthesis', |
| 67 | 'Operating System :: POSIX', | 71 | 'Operating System :: POSIX', |
| 68 | 'Operating System :: MacOS :: MacOS X', | 72 | 'Operating System :: MacOS :: MacOS X', |
| 69 | 'Operating System :: Microsoft :: Windows', | 73 | 'Operating System :: Microsoft :: Windows', |
| 70 | 'Programming Language :: C', | 74 | 'Programming Language :: C', |
| 71 | 'Programming Language :: Python', | 75 | 'Programming Language :: Python', |
| 72 | 'License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)', | 76 | 'License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)', |
| 73 | ] | 77 | ] |
| 74 | 78 | ||
| 75 | distrib = setup(name='aubio', | 79 | distrib = setup(name='aubio', |
| 76 | version = __version__, | 80 | version = __version__, |
| 77 | packages = ['aubio'], | 81 | packages = ['aubio'], |
| 78 | ext_modules = [aubio_extension], | 82 | ext_modules = [aubio_extension], |
| 79 | description = 'interface to the aubio library', | 83 | description = 'interface to the aubio library', |
| 80 | long_description = 'interface to the aubio library', | 84 | long_description = 'interface to the aubio library', |
| 81 | license = 'GNU/GPL version 3', | 85 | license = 'GNU/GPL version 3', |
| 82 | author = 'Paul Brossier', | 86 | author = 'Paul Brossier', |
| 83 | author_email = 'piem@aubio.org', | 87 | author_email = 'piem@aubio.org', |
| 84 | maintainer = 'Paul Brossier', | 88 | maintainer = 'Paul Brossier', |
| 85 | maintainer_email = 'piem@aubio.org', | 89 | maintainer_email = 'piem@aubio.org', |
| 86 | url = 'http://aubio.org/', | 90 | url = 'http://aubio.org/', |
| 87 | platforms = 'any', | 91 | platforms = 'any', |
| 88 | classifiers = classifiers, | 92 | classifiers = classifiers, |
| 89 | ) | 93 | ) |
| 90 | |||