forked from vamp-plugins/vampy-host
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
62 lines (54 loc) · 2.27 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
import os
from setuptools import setup, find_packages, Extension
sdkdir = 'vamp-plugin-sdk/src/vamp-hostsdk/'
vpydir = 'native/'
sdkfiles = [ 'Files', 'PluginBufferingAdapter', 'PluginChannelAdapter',
'PluginHostAdapter', 'PluginInputDomainAdapter', 'PluginLoader',
'PluginSummarisingAdapter', 'PluginWrapper', 'RealTime' ]
vpyfiles = [ 'PyPluginObject', 'PyRealTime', 'VectorConversion', 'vampyhost' ]
srcfiles = [
sdkdir + f + '.cpp' for f in sdkfiles
] + [
vpydir + f + '.cpp' for f in vpyfiles
]
def read(*paths):
with open(os.path.join(*paths), 'r') as f:
return f.read()
class get_numpy_include(object):
"""Defer numpy.get_include() until after numpy is installed."""
def __str__(self):
import numpy
return numpy.get_include()
def get_extension():
vampyhost = Extension('vampyhost',
sources = srcfiles,
define_macros = [ ('_USE_MATH_DEFINES', 1) ],
include_dirs = [ 'vamp-plugin-sdk', get_numpy_include() ])
return vampyhost
setup (name = 'vamp',
version = '1.1.0',
url = 'https://code.soundsoftware.ac.uk/projects/vampy-host',
description = 'Use Vamp plugins for audio feature analysis.',
long_description = ( read('README.rst') + '\n\n' + read('COPYING.rst') ),
license = 'MIT',
packages = find_packages(exclude = [ '*test*' ]),
ext_modules = [get_extension() ],
requires = [ 'numpy' ],
setup_requires=["numpy"], # Just numpy here
install_requires=["numpy"], # Add any of your other dependencies here
author = 'Chris Cannam, George Fazekas',
author_email = '[email protected]',
classifiers = [
'Development Status :: 4 - Beta',
'Intended Audience :: Science/Research',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: Microsoft :: Windows',
'Operating System :: POSIX',
'Programming Language :: Python',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 3',
'Topic :: Multimedia :: Sound/Audio :: Analysis'
]
)