Build problem on M2 Mac with Meson 1.3.2
Closed this issue · 2 comments
Please add the line
version = "0.26.1" to the [project] section of your pyproject.toml file
When I try to install your package using pip I get the following error:
pip install ./pygrappa
Processing ./pygrappa
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [53 lines of output]
+ meson setup /Users/doug/Documents/Development/Python/pygrappa /Users/doug/Documents/Development/Python/pygrappa/.mesonpy-mjp94sf1 -Dbuildtype=release -Db_ndebug=if-release -Db_vscrt=md --native-file=/Users/doug/Documents/Development/Python/pygrappa/.mesonpy-mjp94sf1/meson-python-native-file.ini
The Meson build system
Version: 1.3.2
Source dir: /Users/doug/Documents/Development/Python/pygrappa
Build dir: /Users/doug/Documents/Development/Python/pygrappa/.mesonpy-mjp94sf1
Build type: native build
Project name: pygrappa
Project version: 0.26.1
C compiler for the host machine: cc (clang 15.0.0 "Apple clang version 15.0.0 (clang-1500.1.0.2.5)")
C linker for the host machine: cc ld64 1022.1
C++ compiler for the host machine: c++ (clang 15.0.0 "Apple clang version 15.0.0 (clang-1500.1.0.2.5)")
C++ linker for the host machine: c++ ld64 1022.1
Host machine cpu family: aarch64
Host machine cpu: aarch64
Program cython found: YES (/private/var/folders/rf/h90r9kfj6gj7qtt8csjzlhgc0000gn/T/pip-build-env-5xrqw7ue/overlay/bin/cython)
Program python found: YES (/opt/homebrew/Caskroom/miniforge/base/bin/python3.10)
Found pkg-config: YES (/opt/homebrew/bin/pkg-config) 0.29.2
Run-time dependency python found: YES 3.10
Program pygrappa/utils/cythoner.py found: YES (/opt/homebrew/Caskroom/miniforge/base/bin/python3.10 /Users/doug/Documents/Development/Python/pygrappa/pygrappa/utils/cythoner.py)
Compiler for C supports arguments -Wno-maybe-uninitialized: NO
Compiler for C supports arguments -Wno-discarded-qualifiers: NO
Compiler for C supports arguments -Wno-empty-body: YES
Compiler for C supports arguments -Wno-implicit-function-declaration: YES
Compiler for C supports arguments -Wno-parentheses: YES
Compiler for C supports arguments -Wno-switch: YES
Compiler for C supports arguments -Wno-unused-label: YES
Compiler for C supports arguments -Wno-unused-variable: YES
Compiler for C++ supports arguments -Wno-cpp: YES
Compiler for C++ supports arguments -Wno-deprecated-declarations: YES
Compiler for C++ supports arguments -Wno-class-memaccess: NO
Compiler for C++ supports arguments -Wno-format-truncation: NO
Compiler for C++ supports arguments -Wno-non-virtual-dtor: YES
Compiler for C++ supports arguments -Wno-sign-compare: YES
Compiler for C++ supports arguments -Wno-switch: YES
Compiler for C++ supports arguments -Wno-terminate: NO
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-unused-local-typedefs: YES
Compiler for C++ supports arguments -Wno-unused-variable: YES
Compiler for C++ supports arguments -Wno-int-in-bool-context: YES
Build targets in project: 4
pygrappa 0.26.1
User defined options
Native files: /Users/doug/Documents/Development/Python/pygrappa/.mesonpy-mjp94sf1/meson-python-native-file.ini
buildtype : release
b_ndebug : if-release
b_vscrt : md
Found ninja-1.11.1.git.kitware.jobserver-1 at /private/var/folders/rf/h90r9kfj6gj7qtt8csjzlhgc0000gn/T/pip-build-env-5xrqw7ue/overlay/bin/ninja
('\x1b[31m',)meson-python: error: Required "project.version" field is missing and not declared as dynamic
[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.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
Adding the version line to my local copy allows the build to proceed.
Thanks.
Hi @kelleydac, thanks for reporting this!
I've added the version
filed to the pyproject.toml
and uploaded a new release to pypi, version 0.26.2. Please let me know if this resolves the issues you were seeing in your build environment.
This appears to have been resolved -- please reopen if it's still an issue