-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.py
38 lines (34 loc) · 1.09 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
"""Setup File"""
from setuptools import Extension, setup
from Cython.Build import cythonize
import os
def package_files(directory):
paths = []
for (path, _, filenames) in os.walk(directory):
for filename in filenames:
paths.append(os.path.join("..", path, filename))
return paths
setup(
package_data={"rubato": [*package_files("rubato/static"),
os.path.join("..", "rubato/c_src/", "cdraw.pxd")]},
ext_modules=[
*cythonize(
Extension(
"rubato.c_src.c_draw",
["rubato/c_src/c_draw.py", "rubato/c_src/cdraw.cpp"],
extra_compile_args=["-std=c++14"],
language="c++",
),
),
*cythonize(
"rubato/**/*.py",
exclude=["rubato/__pyinstaller/**/*", "rubato/static/**/*", "rubato/c_src/**/*"],
compiler_directives={
"embedsignature": True,
"language_level": 3,
"linetrace": True,
"emit_code_comments": True,
},
),
]
)