diff options
| author | Gus Smith <gus@normalcomputing.ai> | 2026-05-29 10:26:32 -0700 |
|---|---|---|
| committer | Gus Smith <gus@normalcomputing.ai> | 2026-05-29 10:26:32 -0700 |
| commit | ac29b5a73986bf6c9413751078c9a234842bcbe4 (patch) | |
| tree | a59924bc1d0991fcdf5ebcd60dbe0858881bf44a /sources/api/pySoftMC/setup.py | |
| parent | 45dc9b808298c237af404e45111833526e8151c0 (diff) | |
| download | dram-bender-ac29b5a73986bf6c9413751078c9a234842bcbe4.tar.gz | |
Try a different approach via setup.py
Diffstat (limited to 'sources/api/pySoftMC/setup.py')
| -rw-r--r-- | sources/api/pySoftMC/setup.py | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/sources/api/pySoftMC/setup.py b/sources/api/pySoftMC/setup.py new file mode 100644 index 0000000..c353396 --- /dev/null +++ b/sources/api/pySoftMC/setup.py @@ -0,0 +1,22 @@ +from setuptools import setup, Extension +import os + +here = os.path.dirname(os.path.abspath(__file__)) +api_dir = os.path.join(here, "..") +pybind11_include = os.path.join(here, "../ext/pybind11/include") + +ext = Extension( + "pySoftMC", + sources=[ + os.path.join(api_dir, "board.cpp"), + os.path.join(api_dir, "instruction.cpp"), + os.path.join(api_dir, "platform.cpp"), + os.path.join(api_dir, "prog.cpp"), + os.path.join(here, "pySoftMC.cpp"), + ], + include_dirs=[here, api_dir, pybind11_include], + language="c++", + extra_compile_args=["-std=c++14", "-pthread", "-O3", "-DPYSMC"], +) + +setup(name="pySoftMC", ext_modules=[ext]) |
