Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit aa26990

Browse filesBrowse files
authored
make it possible to compile from sources against numpy on macOS aarch64 (opencv#475)
1 parent 4262df8 commit aa26990
Copy full SHA for aa26990

File tree

Expand file treeCollapse file tree

2 files changed

+7
-2
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+7
-2
lines changed

‎pyproject.toml

Copy file name to clipboardExpand all lines: pyproject.toml
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ requires = [
33
"setuptools", "wheel", "scikit-build", "cmake", "pip",
44
"numpy==1.13.3; python_version=='3.6' and platform_machine != 'aarch64'",
55
"numpy==1.19.3; python_version>='3.6' and sys_platform == 'linux' and platform_machine == 'aarch64'",
6+
"numpy==1.20.1; python_version>='3.6' and sys_platform == 'darwin' and platform_machine == 'aarch64'",
67
"numpy==1.14.5; python_version=='3.7' and platform_machine != 'aarch64'",
78
"numpy==1.17.3; python_version=='3.8' and platform_machine != 'aarch64'",
89
"numpy==1.19.3; python_version>='3.9' and platform_machine != 'aarch64'"

‎setup.py

Copy file name to clipboardExpand all lines: setup.py
+6-2Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,14 @@ def main():
3131
if sys.version_info[:2] >= (3, 9):
3232
minimum_supported_numpy = "1.19.3"
3333

34-
# arm64 is a special case
35-
if sys.version_info[:2] >= (3, 6) and platform.machine() == "aarch64":
34+
# linux arm64 is a special case
35+
if sys.platform.startswith("linux") and sys.version_info[:2] >= (3, 6) and platform.machine() == "aarch64":
3636
minimum_supported_numpy = "1.19.3"
3737

38+
# macos arm64 is a special case
39+
if sys.platform == "darwin" and sys.version_info[:2] >= (3, 6) and platform.machine() == "aarch64":
40+
minimum_supported_numpy = "1.20.1"
41+
3842
numpy_version = "numpy>=%s" % minimum_supported_numpy
3943

4044
python_version = cmaker.CMaker.get_python_version()

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.