← back to Exo
Moving conditonal apple silicon logic to setup.py
ae47fe11e643a891cf57e23a599dbcbb50a556c9 · 2024-10-22 14:04:30 -0400 · willschneider15
Files touched
Diff
commit ae47fe11e643a891cf57e23a599dbcbb50a556c9
Author: willschneider15 <willschneider15@gmail.com>
Date: Tue Oct 22 14:04:30 2024 -0400
Moving conditonal apple silicon logic to setup.py
---
install.sh | 10 +---------
setup.py | 5 +++++
2 files changed, 6 insertions(+), 9 deletions(-)
diff --git a/install.sh b/install.sh
index 22efbdfa..ce83eed8 100755
--- a/install.sh
+++ b/install.sh
@@ -2,12 +2,4 @@
python3 -m venv .venv
source .venv/bin/activate
-
-# Check if running on macOS with Apple Silicon
-if [[ "$(uname)" == "Darwin" && "$(uname -m)" == "arm64" ]]; then
- echo "Installing with Apple Silicon support..."
- pip install -e ".[apple_silicon]"
-else
- echo "Installing without Apple Silicon support..."
- pip install -e .
-fi
+pip install -e .
diff --git a/setup.py b/setup.py
index ae2ad3a8..1a34806b 100644
--- a/setup.py
+++ b/setup.py
@@ -1,4 +1,5 @@
import sys
+import platform
from setuptools import find_packages, setup
@@ -40,6 +41,10 @@ extras_require = {
],
}
+# Check if running on macOS with Apple Silicon
+if sys.platform.startswith("darwin") and platform.machine() == "arm64":
+ install_requires.extend(extras_require["apple_silicon"])
+
setup(
name="exo",
version="0.0.1",
← 6dd2f7ab changes to inference engine
·
back to Exo
·
added error a03f3a2a →