IQ.Pilot Release Commit @ bec7652
This commit is contained in:
19
artifacts/package_sources/msgq/setup.py
Normal file
19
artifacts/package_sources/msgq/setup.py
Normal file
@@ -0,0 +1,19 @@
|
||||
import os
|
||||
import subprocess
|
||||
|
||||
from setuptools import Distribution, setup
|
||||
from setuptools.command.build_py import build_py
|
||||
|
||||
|
||||
class BinaryDistribution(Distribution):
|
||||
def has_ext_modules(self):
|
||||
return True
|
||||
|
||||
|
||||
class BuildPyWithScons(build_py):
|
||||
def run(self):
|
||||
subprocess.check_call(["scons", f"-j{os.cpu_count() or 1}", "--minimal"], cwd=os.path.dirname(os.path.abspath(__file__)))
|
||||
super().run()
|
||||
|
||||
|
||||
setup(cmdclass={"build_py": BuildPyWithScons}, distclass=BinaryDistribution)
|
||||
Reference in New Issue
Block a user