Skip to content

Commit

Permalink
update setup.py to allow "wheel" construction on mac (#1088)
Browse files Browse the repository at this point in the history
* update setup.py to allow "wheel" construction on mac

* PR feedback

---------

Co-authored-by: andy <andy@neuralmagic.com>
  • Loading branch information
andy-neuma and andy committed Jun 21, 2023
1 parent 7aa8ac4 commit ac4062c
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,13 +180,17 @@ def _check_supported_system():
)

if sys.platform.startswith("darwin"):
# mac is not supported, raise error on install
raise OSError(
"Native Mac is currently unsupported for DeepSparse. "
"Please run on a Linux system or within a Linux container on Mac. "
"More info can be found in our docs here: "
"https://docs.neuralmagic.com/deepsparse/source/hardware.html"
)
if os.getenv("NM_ALLOW_DARWIN", "0") != "0":
# experimental support for mac, allow install to go through
return
else:
# mac is not supported, raise error on install
raise OSError(
"Native Mac is currently unsupported for DeepSparse. "
"Please run on a Linux system or within a Linux container on Mac. "
"More info can be found in our docs here: "
"https://docs.neuralmagic.com/deepsparse/source/hardware.html"
)

# unknown system, raise error on install
raise OSError(
Expand Down

0 comments on commit ac4062c

Please sign in to comment.