Skip to content

Commit 6e0739c

Browse files
committed
build py
1 parent c5ae432 commit 6e0739c

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ __pycache__
1313
/venv
1414
/dist
1515
*.egg-info
16+
/build
1617

1718
# binaries
1819
*.out

setup.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import os
33
import subprocess
44
from setuptools import setup, find_packages, Extension
5+
from setuptools.command.build_py import build_py as _build_py
56

67
module_name = "libparse"
78
__dir__ = os.path.dirname(os.path.abspath(__file__))
@@ -21,10 +22,16 @@
2122
extra_compile_args=["-std=c++11", "-DFILTERLIB"],
2223
)
2324

25+
26+
class build_py(_build_py):
27+
def run(self):
28+
self.run_command("build_ext")
29+
return super().run()
30+
2431
setup(
2532
name=module_name,
2633
packages=find_packages(),
27-
version="0.1.2",
34+
version="0.1.3",
2835
description="Python wrapper around Yosys' libparse module",
2936
long_description=open("Readme.md").read(),
3037
long_description_content_type="text/markdown",
@@ -40,4 +47,5 @@
4047
],
4148
python_requires=">3.6",
4249
ext_modules=[ext],
50+
build_py=build_py,
4351
)

0 commit comments

Comments
 (0)