Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error installing from source on ARM Mac #33

Open
stenczelt opened this issue Oct 8, 2023 · 0 comments
Open

Error installing from source on ARM Mac #33

stenczelt opened this issue Oct 8, 2023 · 0 comments

Comments

@stenczelt
Copy link

stenczelt commented Oct 8, 2023

I am having trouble installing from source on an M2 Mac.

pip install .                                                                                                                                             sella-issue-1 09:06:50 am
Processing /private/tmp/sella-issue-1/sella
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Collecting numpy>=1.14.0 (from Sella==2.3.2)
  Obtaining dependency information for numpy>=1.14.0 from https://files.pythonhosted.org/packages/35/21/9e150d654da358beb29fe216f339dc17f2b2ac13fff2a89669401a910550/numpy-1.26.0-cp311-cp311-macosx_11_0_arm64.whl.metadata
  Using cached numpy-1.26.0-cp311-cp311-macosx_11_0_arm64.whl.metadata (99 kB)
Collecting scipy>=1.1.0 (from Sella==2.3.2)
  Obtaining dependency information for scipy>=1.1.0 from https://files.pythonhosted.org/packages/50/8b/2057417a07a6fee8ed8be40e37bac4a502cae4cf44468a02962bbe81b8af/scipy-1.11.3-cp311-cp311-macosx_12_0_arm64.whl.metadata
  Using cached scipy-1.11.3-cp311-cp311-macosx_12_0_arm64.whl.metadata (165 kB)
Collecting ase>=3.18.0 (from Sella==2.3.2)
  Using cached ase-3.22.1-py3-none-any.whl (2.2 MB)
Collecting jax>=0.2.3 (from Sella==2.3.2)
  Obtaining dependency information for jax>=0.2.3 from https://files.pythonhosted.org/packages/b5/5b/5131520dd9a384a640399e5efe4324fdee9e8a48685a33d08eb47140ccc3/jax-0.4.18-py3-none-any.whl.metadata
  Using cached jax-0.4.18-py3-none-any.whl.metadata (23 kB)
Collecting jaxlib>=0.1.56 (from Sella==2.3.2)
  Obtaining dependency information for jaxlib>=0.1.56 from https://files.pythonhosted.org/packages/a0/8b/909e428f04212587941841239ffe99806784cd49d0a8ace305f913d88c9b/jaxlib-0.4.18-cp311-cp311-macosx_11_0_arm64.whl.metadata
  Using cached jaxlib-0.4.18-cp311-cp311-macosx_11_0_arm64.whl.metadata (2.0 kB)
Collecting matplotlib>=3.1.0 (from ase>=3.18.0->Sella==2.3.2)
  Obtaining dependency information for matplotlib>=3.1.0 from https://files.pythonhosted.org/packages/af/f3/fb27b3b902fc759bbca3f9d0336c48069c3022e57552c4b0095d997c7ea8/matplotlib-3.8.0-cp311-cp311-macosx_11_0_arm64.whl.metadata
  Using cached matplotlib-3.8.0-cp311-cp311-macosx_11_0_arm64.whl.metadata (5.8 kB)
Collecting ml-dtypes>=0.2.0 (from jax>=0.2.3->Sella==2.3.2)
  Obtaining dependency information for ml-dtypes>=0.2.0 from https://files.pythonhosted.org/packages/22/54/f50df872e42beffe566e29b6ef6cc9daf3901160c9e5290e254aad54560f/ml_dtypes-0.3.1-cp311-cp311-macosx_10_9_universal2.whl.metadata
  Using cached ml_dtypes-0.3.1-cp311-cp311-macosx_10_9_universal2.whl.metadata (20 kB)
Collecting opt-einsum (from jax>=0.2.3->Sella==2.3.2)
  Using cached opt_einsum-3.3.0-py3-none-any.whl (65 kB)
Collecting contourpy>=1.0.1 (from matplotlib>=3.1.0->ase>=3.18.0->Sella==2.3.2)
  Obtaining dependency information for contourpy>=1.0.1 from https://files.pythonhosted.org/packages/2c/8e/656f8e7cd316aa68d9824744773e90dbd71f847429d10c82001e927480a2/contourpy-1.1.1-cp311-cp311-macosx_11_0_arm64.whl.metadata
  Using cached contourpy-1.1.1-cp311-cp311-macosx_11_0_arm64.whl.metadata (5.9 kB)
Collecting cycler>=0.10 (from matplotlib>=3.1.0->ase>=3.18.0->Sella==2.3.2)
  Obtaining dependency information for cycler>=0.10 from https://files.pythonhosted.org/packages/e7/05/c19819d5e3d95294a6f5947fb9b9629efb316b96de511b418c53d245aae6/cycler-0.12.1-py3-none-any.whl.metadata
  Using cached cycler-0.12.1-py3-none-any.whl.metadata (3.8 kB)
Collecting fonttools>=4.22.0 (from matplotlib>=3.1.0->ase>=3.18.0->Sella==2.3.2)
  Obtaining dependency information for fonttools>=4.22.0 from https://files.pythonhosted.org/packages/49/ba/ebe5599acf47371393191091ae95fca08eb6f12fd151b52c8dbebb990d25/fonttools-4.43.1-cp311-cp311-macosx_10_9_universal2.whl.metadata
  Using cached fonttools-4.43.1-cp311-cp311-macosx_10_9_universal2.whl.metadata (152 kB)
Collecting kiwisolver>=1.0.1 (from matplotlib>=3.1.0->ase>=3.18.0->Sella==2.3.2)
  Obtaining dependency information for kiwisolver>=1.0.1 from https://files.pythonhosted.org/packages/4a/fe/23d7fa78f7c66086d196406beb1fb2eaf629dd7adc01c3453033303d17fa/kiwisolver-1.4.5-cp311-cp311-macosx_11_0_arm64.whl.metadata
  Using cached kiwisolver-1.4.5-cp311-cp311-macosx_11_0_arm64.whl.metadata (6.4 kB)
Collecting packaging>=20.0 (from matplotlib>=3.1.0->ase>=3.18.0->Sella==2.3.2)
  Obtaining dependency information for packaging>=20.0 from https://files.pythonhosted.org/packages/ec/1a/610693ac4ee14fcdf2d9bf3c493370e4f2ef7ae2e19217d7a237ff42367d/packaging-23.2-py3-none-any.whl.metadata
  Using cached packaging-23.2-py3-none-any.whl.metadata (3.2 kB)
Collecting pillow>=6.2.0 (from matplotlib>=3.1.0->ase>=3.18.0->Sella==2.3.2)
  Obtaining dependency information for pillow>=6.2.0 from https://files.pythonhosted.org/packages/e4/93/9226cc667ed8785333969c03deb2a36af2f3757284d3a2cf2ebd70331c32/Pillow-10.0.1-cp311-cp311-macosx_11_0_arm64.whl.metadata
  Using cached Pillow-10.0.1-cp311-cp311-macosx_11_0_arm64.whl.metadata (9.5 kB)
Collecting pyparsing>=2.3.1 (from matplotlib>=3.1.0->ase>=3.18.0->Sella==2.3.2)
  Obtaining dependency information for pyparsing>=2.3.1 from https://files.pythonhosted.org/packages/39/92/8486ede85fcc088f1b3dba4ce92dd29d126fd96b0008ea213167940a2475/pyparsing-3.1.1-py3-none-any.whl.metadata
  Using cached pyparsing-3.1.1-py3-none-any.whl.metadata (5.1 kB)
Collecting python-dateutil>=2.7 (from matplotlib>=3.1.0->ase>=3.18.0->Sella==2.3.2)
  Using cached python_dateutil-2.8.2-py2.py3-none-any.whl (247 kB)
Collecting six>=1.5 (from python-dateutil>=2.7->matplotlib>=3.1.0->ase>=3.18.0->Sella==2.3.2)
  Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
Using cached jax-0.4.18-py3-none-any.whl (1.7 MB)
Using cached jaxlib-0.4.18-cp311-cp311-macosx_11_0_arm64.whl (65.9 MB)
Using cached numpy-1.26.0-cp311-cp311-macosx_11_0_arm64.whl (14.0 MB)
Using cached scipy-1.11.3-cp311-cp311-macosx_12_0_arm64.whl (29.7 MB)
Using cached matplotlib-3.8.0-cp311-cp311-macosx_11_0_arm64.whl (7.5 MB)
Using cached ml_dtypes-0.3.1-cp311-cp311-macosx_10_9_universal2.whl (348 kB)
Using cached contourpy-1.1.1-cp311-cp311-macosx_11_0_arm64.whl (233 kB)
Using cached cycler-0.12.1-py3-none-any.whl (8.3 kB)
Using cached fonttools-4.43.1-cp311-cp311-macosx_10_9_universal2.whl (2.7 MB)
Using cached kiwisolver-1.4.5-cp311-cp311-macosx_11_0_arm64.whl (66 kB)
Using cached packaging-23.2-py3-none-any.whl (53 kB)
Using cached Pillow-10.0.1-cp311-cp311-macosx_11_0_arm64.whl (3.3 MB)
Using cached pyparsing-3.1.1-py3-none-any.whl (103 kB)
Building wheels for collected packages: Sella
  Building wheel for Sella (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for Sella (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [50 lines of output]
      /private/var/folders/83/sdc3psbx0h74nbfnh5hh6rc40000gn/T/pip-build-env-9h9dwvt6/overlay/lib/python3.11/site-packages/setuptools/dist.py:498: SetuptoolsDeprecationWarning: Invalid dash-separated options
      !!

              ********************************************************************************
              Usage of dash-separated 'description-file' will not be supported in future
              versions. Please use the underscore name 'description_file' instead.

              This deprecation is overdue, please update your project and remove deprecated
              calls to avoid build errors in the future.

              See https://setuptools.pypa.io/en/latest/userguide/declarative_config.html for details.
              ********************************************************************************

      !!
        opt = self.warn_dash_deprecation(opt, section)
      running bdist_wheel
      running build
      running build_py
      creating build
      creating build/lib.macosx-13-arm64-cpython-311
      creating build/lib.macosx-13-arm64-cpython-311/sella
      copying sella/internal.py -> build/lib.macosx-13-arm64-cpython-311/sella
      copying sella/__init__.py -> build/lib.macosx-13-arm64-cpython-311/sella
      copying sella/linalg.py -> build/lib.macosx-13-arm64-cpython-311/sella
      copying sella/hessian_update.py -> build/lib.macosx-13-arm64-cpython-311/sella
      copying sella/samd.py -> build/lib.macosx-13-arm64-cpython-311/sella
      copying sella/peswrapper.py -> build/lib.macosx-13-arm64-cpython-311/sella
      copying sella/eigensolvers.py -> build/lib.macosx-13-arm64-cpython-311/sella
      creating build/lib.macosx-13-arm64-cpython-311/sella/optimize
      copying sella/optimize/optimize.py -> build/lib.macosx-13-arm64-cpython-311/sella/optimize
      copying sella/optimize/stepper.py -> build/lib.macosx-13-arm64-cpython-311/sella/optimize
      copying sella/optimize/irc.py -> build/lib.macosx-13-arm64-cpython-311/sella/optimize
      copying sella/optimize/__init__.py -> build/lib.macosx-13-arm64-cpython-311/sella/optimize
      copying sella/optimize/restricted_step.py -> build/lib.macosx-13-arm64-cpython-311/sella/optimize
      creating build/lib.macosx-13-arm64-cpython-311/sella/utilities
      copying sella/utilities/__init__.py -> build/lib.macosx-13-arm64-cpython-311/sella/utilities
      running build_ext
      building 'sella.force_match' extension
      creating build/temp.macosx-13-arm64-cpython-311
      creating build/temp.macosx-13-arm64-cpython-311/sella
      clang -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk -I/private/var/folders/83/sdc3psbx0h74nbfnh5hh6rc40000gn/T/pip-build-env-9h9dwvt6/overlay/lib/python3.11/site-packages/numpy/core/include -I/private/var/folders/83/sdc3psbx0h74nbfnh5hh6rc40000gn/T/pip-build-env-9h9dwvt6/overlay/lib/python3.11/site-packages/numpy/core/include -I/private/tmp/sella-issue-1/venv/include -I/opt/homebrew/opt/[email protected]/Frameworks/Python.framework/Versions/3.11/include/python3.11 -c sella/force_match.c -o build/temp.macosx-13-arm64-cpython-311/sella/force_match.o
      In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk/usr/include/Availability.h:166,
                       from /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk/usr/include/stdlib.h:61,
                       from /opt/homebrew/opt/[email protected]/Frameworks/Python.framework/Versions/3.11/include/python3.11/Python.h:23,
                       from sella/force_match.c:38:
      /opt/homebrew/Cellar/gcc/13.2.0/lib/gcc/current/gcc/aarch64-apple-darwin23/13/include-fixed/AvailabilityInternal.h:162:10: fatal error: AvailabilityInternalLegacy.h: No such file or directory
        162 | #include <AvailabilityInternalLegacy.h>
            |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      compilation terminated.
      error: command '/opt/homebrew/bin/clang' failed with exit code 1
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for Sella
Failed to build Sella
ERROR: Could not build wheels for Sella, which is required to install pyproject.toml-based projects

Same happens if I am using gcc and if I am using the setup.py directly with python setup.py install (after installing dependencies).

How to get around this, have you seen it on any ARM Mac?

versions of software:

  • gcc (Homebrew GCC 13.2.0) 13.2.0
  • MacOS 14.0
  • Python 3.11.5

Tried on 723756f

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant