Comments (9)
After updating to fix/mac-openssl
branch, while having the esp
toolchain active, the command cargo version
has the following output on mac:
dyld: Library not loaded: /usr/local/opt/openssl@3/lib/libssl.3.dylib
Referenced from: /Users/paazmaya/.rustup/toolchains/esp/bin/cargo
Reason: image not found
Abort trap: 6
from espup.
Ack, found existing bug esp-rs/rust-build#157
For @paazmaya , using homebrew to install openssl is a work-around that is working for me. (All the LLVM stuff for xtensa is resole, right? So we shouldn't need a special toolchain much longer?)
from espup.
(I've copied the files over myself and have working cargo, but this could possibly block others)
from espup.
Hi @tschundler!
Thanks for reporting this issue, could you try the installation with the PR branch to verify that it solves the issue?
cargo install espup --git https://github.com/esp-rs/espup --branch fix/mac-openssl
espup install
. ~/export-esp.sh
from espup.
oops. I probably should have been more specific about running cargo.
I create a new esp32s3 project, eg
cargo generate --git https://github.com/esp-rs/esp-template -n esps3-test
cd esps3-test
then run
cargo version
and that's what isn't statically linked, when it uses cargo in ~/.espressif/dist/rust/rust-nightly-x86_64-apple-darwin/cargo/bin/cargo
$ otool -L ~/.espressif/dist/rust/rust-nightly-x86_64-apple-darwin/cargo/bin/cargo
/Users/ted/.espressif/dist/rust/rust-nightly-x86_64-apple-darwin/cargo/bin/cargo:
/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
/System/Library/Frameworks/Security.framework/Versions/A/Security (compatibility version 1.0.0, current version 59306.101.1)
/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 1675.129.0)
/usr/local/opt/openssl@3/lib/libssl.3.dylib (compatibility version 3.0.0, current version 3.0.0)
/usr/local/opt/openssl@3/lib/libcrypto.3.dylib (compatibility version 3.0.0, current version 3.0.0)
/usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.11)
/usr/lib/libcurl.4.dylib (compatibility version 7.0.0, current version 9.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
(on an M1 mac, it's fine. otool -L ~/.espressif/dist/rust/rust-nightly-aarch64-apple-darwin/cargo/bin/cargo
doesn't list libssl, libcrypto or libz, so they must be statically linked)
...digging more, /usr/local/opt/lib seems to be a homebrew thing, so I tried brew install openssl
and that put it in the expected location. Still, it should probably be static linked.
I'm not sure who owns building that special nightly rust toolchain - maybe this bug should be in a different place?
from espup.
oops. I probably should have been more specific about running cargo.
I create a new esp32s3 project, eg
cargo generate --git https://github.com/esp-rs/esp-template -n esps3-test cd esps3-test
then run
cargo version
and that's what isn't statically linked, when it uses cargo in
~/.espressif/dist/rust/rust-nightly-x86_64-apple-darwin/cargo/bin/cargo
$ otool -L ~/.espressif/dist/rust/rust-nightly-x86_64-apple-darwin/cargo/bin/cargo /Users/ted/.espressif/dist/rust/rust-nightly-x86_64-apple-darwin/cargo/bin/cargo: /usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0) /System/Library/Frameworks/Security.framework/Versions/A/Security (compatibility version 1.0.0, current version 59306.101.1) /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 1675.129.0) /usr/local/opt/openssl@3/lib/libssl.3.dylib (compatibility version 3.0.0, current version 3.0.0) /usr/local/opt/openssl@3/lib/libcrypto.3.dylib (compatibility version 3.0.0, current version 3.0.0) /usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.11) /usr/lib/libcurl.4.dylib (compatibility version 7.0.0, current version 9.0.0) /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
(on an M1 mac, it's fine.
otool -L ~/.espressif/dist/rust/rust-nightly-aarch64-apple-darwin/cargo/bin/cargo
doesn't list libssl, libcrypto or libz, so they must be statically linked)...digging more, /usr/local/opt/lib seems to be a homebrew thing, so I tried
brew install openssl
and that put it in the expected location. Still, it should probably be static linked.I'm not sure who owns building that special nightly rust toolchain - maybe this bug should be in a different place?
Sorry, is this the output of testing the fix/mac-openssl
branch? In this branch, openssl
should be statically linked
from espup.
The problem isn't with espup itself, but with the rust-nightly that espup installs. That cargo, that it puts in ~/.rustup/toolchains/esp/bin/cargo is what doesn't have openssl static linked.
The location it expects is where http://brew.sh puts it, not a standard MacOS location. I have no problem otherwise with cargo
from https://rustup.rs/, only what espup installs.
Is there somewhere better for the bug to be?
from espup.
Is there somewhere better for the bug to be?
Probably, could you open up an issue in https://github.com/esp-rs/rust-build with your conclusions? I will still merge #153 as I think its an improvement
from espup.
Ack, found existing bug esp-rs/rust-build#157
Sorry I completely forgot about that issue, where I also participated
All the LLVM stuff for xtensa is resole, right? So we shouldn't need a special toolchain much longer?
Yes, the first 10 patches have now been accepted, hopefully, we will have Xtensa support in LLVM and Rust in the future!
from espup.
Related Issues (20)
- Temporary directory doesn't seem to be cleaned after installation / update HOT 5
- Compiling it on macOS-arm64 HOT 3
- espup uses large amounts of space in $TMPDIR HOT 6
- If rustup toolchain dir includes non-directory entries, `espup install` panics HOT 4
- On CI systems running in AWS, `XtensaRust::parse_version()` repeatedly times out and panics espup HOT 2
- `espup install` detects and re-uses existing gcc, but always re-installs rust toolchain when it fails to execute it HOT 14
- Add CHANGELOG
- Installation fails when providing an incomplete Xtensa Rust
- Installation fails when $RUSTUP_HOME/tmp is not created
- Update GCC
- Fix export script log typo
- ESP32 and lv-binding-rs does not build HOT 5
- espup installs potential riscv targets that are never used HOT 2
- `skip_version_parse` argument should require `toolchain_version`
- Check for component on `install` and `update`
- If there is a minified LLVM installation `--extended-llvm` doesn't install the full LLVM HOT 1
- Install python3 and python3-venv. HOT 3
- Add support for ESP32-P4
- cargo install espup doesn't work on M1 HOT 1
- Installation duplicates contents of PATH environment variable on Windows HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from espup.