-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.py
More file actions
executable file
·35 lines (33 loc) · 1.97 KB
/
setup.py
File metadata and controls
executable file
·35 lines (33 loc) · 1.97 KB
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
"""
setup.py for installing GERBLS
Most of the project settings/metadata are in `pyproject.toml`.
Currently, this file is included because the setuptools (v80) support for defining extention modules
inside `pyproject.toml` is still considered experimental and may be subject to change.
"""
from setuptools import Extension, setup
from Cython.Build import cythonize
import numpy as np
setup(name = "gerbls",
ext_modules = cythonize([Extension("gerbls.core",
["src/gerbls/core.pyx",
"src/gerbls/cpp/ffafunc.cpp",
"src/gerbls/cpp/model.cpp",
"src/gerbls/cpp/physfunc.cpp",
"src/gerbls/cpp/structure.cpp"],
include_dirs=[np.get_include()],
define_macros=[("NPY_NO_DEPRECATED_API",
"NPY_1_7_API_VERSION")],
extra_compile_args = ["-O3",
"-std=c++0x",
"-march=native",
"-fassociative-math",
"-fno-math-errno",
"-ffinite-math-only",
"-fno-rounding-math",
"-fno-signed-zeros",
"-fno-trapping-math"])],
annotate=False,
compiler_directives={"embedsignature": True}
),
zip_safe = False,
)