gpoesia / peano

An environment for learning formal mathematical reasoning from scratch
MIT License
49 stars 5 forks source link

Unable to compile peano on Apple M1 #5

Closed nileshtrivedi closed 2 months ago

nileshtrivedi commented 2 months ago

Running cargo build on Apple M1 machine throws this error:

Undefined symbols for architecture arm64: "_PyBaseObject_Type", referenced from

I tried this answer from StackOverflow but it did not work.

System details:

% python --version
Python 3.10.14
% rustc --version
rustc 1.79.0 (129f3b996 2024-06-10)
% cargo --version
cargo 1.79.0 (ffa9cf99a 2024-06-03)
% uname -a
Darwin workbox.local 23.5.0 Darwin Kernel Version 23.5.0: Wed May  1 20:12:58 PDT 2024; root:xnu-10063.121.3~5/RELEASE_ARM64_T6000 arm64
nileshtrivedi commented 2 months ago

Changing Pyo3 version to 0.20.2 in Cargo.toml did not help.

nileshtrivedi commented 2 months ago

Relevant links:

nileshtrivedi commented 2 months ago

Closing. Just needed to add rustflags to ~/.cargo/config.toml (which had to be created).