SWxTREC/pymsis

macOS installation error

Closed this issue · 2 comments

I tried to install Pymsis on a mac with M1 pro, and I got this error:
##############################
Running command git clone --filter=blob:none --quiet https://github.com/SWxTREC/pymsis.git /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0
Resolved https://github.com/SWxTREC/pymsis.git to commit 2da42d3
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error

× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [26 lines of output]
The Meson build system
Version: 1.0.1
Source dir: /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0
Build dir: /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0/.mesonpy-hn5iune5/build
Build type: native build
Project name: pymsis
Project version: 0.6.0
C compiler for the host machine: cc (clang 14.0.0 "Apple clang version 14.0.0 (clang-1400.0.29.202)")
C linker for the host machine: cc ld64 820.1
Host machine cpu family: aarch64
Host machine cpu: aarch64
Compiler for C supports arguments -Wno-unused-but-set-variable: YES
Compiler for C supports arguments -Wno-unused-function: YES
Compiler for C supports arguments -Wno-conversion: YES
Compiler for C supports arguments -Wno-misleading-indentation: YES
Compiler for C supports arguments -Wno-incompatible-pointer-types: YES
Fortran compiler for the host machine: gfortran (gcc 12.2.0 "GNU Fortran (GCC) 12.2.0")
Fortran linker for the host machine: gfortran ld64 820.1
Compiler for Fortran supports arguments -Wno-conversion: YES
Program python found: YES (/Users/liwenbo/miniconda/envs/TFmacPy310/bin/python)
Found pkg-config: /Users/liwenbo/miniconda/envs/TFmacPy310/bin/pkg-config (0.29.2)

  ../../meson.build:82:0: ERROR: Command `/Users/liwenbo/miniconda/envs/TFmacPy310/bin/python /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0/tools/download_source.py` failed with status 1.
  
  A full log can be found at /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0/.mesonpy-hn5iune5/build/meson-logs/meson-log.txt
  + meson setup --prefix=/Users/liwenbo/miniconda/envs/TFmacPy310 /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0 /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0/.mesonpy-hn5iune5/build --native-file=/private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0/.mesonpy-native-file.ini -Ddebug=false -Doptimization=2
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.
##############################
Is there a problem with pkg-config (0.29.2)? What is the correct version required at present?

Thanks a lot

That seems to be an error from downloading the original source files. Do you have internet access restricted or go through a VPN/proxy that may need to be required to download external resources? I've had issues on remote CI systems where the source location seems to block certain IP blocks.

../../meson.build:82:0: ERROR: Command /Users/liwenbo/miniconda/envs/TFmacPy310/bin/python /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0/tools/download_source.py failed with status 1.

Can you open the full log output to see what the actual error is? /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0/.mesonpy-hn5iune5/build/meson-logs/meson-log.txt

There is a section for remote installation that may help if you need to download the source files manually: https://github.com/SWxTREC/pymsis#remote-installation

I don't think this is related, but #20 indicates you may need to install with this command on an M1 architecture: ARCHFLAGS="-arch arm64" pip install pymsis

That seems to be an error from downloading the original source files. Do you have internet access restricted or go through a VPN/proxy that may need to be required to download external resources? I've had issues on remote CI systems where the source location seems to block certain IP blocks.

../../meson.build:82:0: ERROR: Command /Users/liwenbo/miniconda/envs/TFmacPy310/bin/python /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0/tools/download_source.py failed with status 1.

Can you open the full log output to see what the actual error is? /private/var/folders/nd/22ptn6_j6955k4pchc6v20f80000gn/T/pip-req-build-c5z4x4r0/.mesonpy-hn5iune5/build/meson-logs/meson-log.txt

There is a section for remote installation that may help if you need to download the source files manually: https://github.com/SWxTREC/pymsis#remote-installation

I don't think this is related, but #20 indicates you may need to install with this command on an M1 architecture: ARCHFLAGS="-arch arm64" pip install pymsis

Thank you! It was a network problem, and it's been fixed. I have successfully installed pymsis.