thepowersgang/mrustc

minicargo build fails on WSLv2 - Ubuntu 22.04 due to OpenSSL

iVoider opened this issue · 6 comments

Failed to find OpenSSL development headers.

You can try fixing this setting the `OPENSSL_DIR` environment variable
pointing to your OpenSSL installation or installing OpenSSL headers package
specific to your distribution:

This happens with the clean configured Ubuntu instance using WSL2, Windows 11.
All needed packages libssl-dev and pkg-config included are installed.
I'd tried to play with env variables and custom homebrew openssl installation. As well as changing triple and "vendored" flag inside Cargo.toml files. I've visited all similar issues with same problem in other repos. Nothing helps.

That looks like the error you get with building 1.19 with a too-new version of OpenSSL. It's not minicargo's problem, it's that the openssl-sys crate used by 1.19's cargo is too old to understand how to link to modern OpenSSL

Yes, I've tried to install v1.1.0 with no difference.

Can you provide the full output and the command you are running? The above gives very little information as to what the source of the error is.

Thanks for pointing the direction. I bruteforced all versions and building 1.1.1f-1ubuntu2_amd64 from source helped.

Side note: Building 1.19 isn't really the best idea, 1.29 is the default - and 1.54 is the latest supported version.

(All are "supported" for purposes of ensuring that mrustc doesn't regress in supported syntax)

Actually, I'm building 1.54.0.