nabijaczleweli / cargo-update

A cargo subcommand for checking and applying updates to installed executables
MIT License
1.22k stars 42 forks source link

minor build issue with upstream openssl #177

Closed jstelzer closed 2 years ago

jstelzer commented 2 years ago

I have an m1 macbook.

I was running topgrade to update 'all the things' to latest.

I got a weird error upgrading cargo-update and ran it manually. It kept complaining about x86_64 libs trying to be ussed on aarch64 which seemed weird. IIRC this was building openssl's crate.

My work around is this:

export OPENSSL_DIR=/opt/homebrew/Cellar/openssl@1.1/1.1.1n
cargo install  --target aarch64-apple-darwin cargo-update

The above worked. Obviously this is the latest openssl from homebrew i'm using. Topgrade ran after this fine. This is mostly to help anyone else who runs into this.

nabijaczleweli commented 2 years ago

If your default target is already aarch64-apple-darwin (which I'm assuming it must be, otherwise you're running everything via rosetta) and you don't have an amd64 openssl installed, then I think you're best off opening an issue on https://github.com/sfackler/rust-openssl so it configures right.

jstelzer commented 2 years ago

yeah, i'm going to close this out as invalid because i'd inadvertently copied more than i should have out of a time machine backup when I changed cpu arch. %100 user error.