-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathsetup.py
More file actions
34 lines (30 loc) · 957 Bytes
/
setup.py
File metadata and controls
34 lines (30 loc) · 957 Bytes
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
#!/usr/bin/env python3
"""
File: setup.py
Description: This file contains the setup required for distributing the
package on PyPi.org.
License: This file is licensed under the GNU LGPL V3 license by
Okke van Eck (2020 - 2023). See the LICENSE file for the
specifics.
"""
import os
from setuptools import setup
from pybind11.setup_helpers import Pybind11Extension, build_ext
module = Pybind11Extension(
name="prospr_core",
sources=[
"prospr/core/core_module.cpp",
"prospr/core/src/utils.cpp",
],
language="c++",
cxx_std=17,
)
# Check enable debugging
# (Console output and pausing in depth_first_bnb(...))
if os.getenv("PROSPR_DEBUG_STEPS", "0") == "1":
module.define_macros = list(module.define_macros or [])
module.define_macros.append(("PROSPR_DEBUG_STEPS", None))
setup(
ext_modules=[module],
cmdclass={"build_ext": build_ext},
)