Summary: | dev-util/cargo-0.30.0 with dev-libs/libressl-2.8.3 - thread 'main' panicked at 'This crate is only compatible with OpenSSL 1.0.1 through 1.1.1, or LibreSSL 2.5 through 2.7, but a different version of OpenSSL was found. The build is now aborting due to ... | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | fkater <fkater> |
Component: | Current packages | Assignee: | Gentoo Rust Project <rust> |
Status: | RESOLVED WONTFIX | ||
Severity: | normal | CC: | libressl |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 561854 | ||
Attachments: |
build.log showing error
updated cargo ebuild |
Please attach the entire build log to this bug report. Created attachment 565718 [details]
build.log showing error
Created attachment 565908 [details] updated cargo ebuild I have created a -r1 version of cargo-0.30.0, with slight updates: # diff cargo-0.30.0.ebuild cargo-0.30.0-r1.ebuild 73,74c73,74 < openssl-src-110.0.7+1.1.0i < openssl-sys-0.9.36 --- > openssl-src-111.1.0+1.1.1a > openssl-sys-0.9.40 Works for me. I am using LibreSSL and get the same error * One or more packages are either masked or have missing dependencies: * * dev-libs/libressl:0/44= pulled in by: * (dev-util/cargo-0.30.0:0/0::gentoo, installed) * ... * Package: dev-util/cargo-0.30.0 * Repository: gentoo * Maintainer: rust@gentoo.org * USE: abi_x86_64 amd64 elibc_glibc kernel_linux libressl userland_GNU * FEATURES: preserve-libs sandbox userpriv usersandbox ... --- stderr thread 'main' panicked at ' This crate is only compatible with OpenSSL 1.0.1 through 1.1.1, or LibreSSL 2.5 through 2.7, but a different version of OpenSSL was found. The build is now aborting due to this version mismatch. I'll vouch for this error's existence. Updating cargo package 'openssl-sys' to v0.9.40 resolves the issue - that's the meaningful update in this ebuild. rust-1.32.0 had a similar error, but as the portage repos won't add that package, I had patched openssl-sys within to support libressl-2.8.x With LibreSSL 2.9.1: error: failed to run custom build command for `openssl-sys v0.9.36` process didn't exit successfully: `/var/tmp/portage/dev-util/cargo-0.30.0-r1/work/cargo-0.30.0/target/release/build/openssl-sys-541db8cb9e1825ee/build-script-main` (exit code: 101) --- stdout cargo:rerun-if-env-changed=X86_64_UNKNOWN_LINUX_GNU_OPENSSL_LIB_DIR cargo:rerun-if-env-changed=OPENSSL_LIB_DIR cargo:rerun-if-env-changed=X86_64_UNKNOWN_LINUX_GNU_OPENSSL_INCLUDE_DIR cargo:rerun-if-env-changed=OPENSSL_INCLUDE_DIR cargo:rerun-if-env-changed=X86_64_UNKNOWN_LINUX_GNU_OPENSSL_DIR cargo:rerun-if-env-changed=OPENSSL_DIR cargo:rustc-link-lib=ssl cargo:rustc-link-lib=crypto OPT_LEVEL = Some("3") TARGET = Some("x86_64-unknown-linux-gnu") HOST = Some("x86_64-unknown-linux-gnu") CC_x86_64-unknown-linux-gnu = None CC_x86_64_unknown_linux_gnu = None HOST_CC = None CC = None CFLAGS_x86_64-unknown-linux-gnu = None CFLAGS_x86_64_unknown_linux_gnu = None HOST_CFLAGS = None CFLAGS = Some("-march=skylake -O3 -pipe") DEBUG = Some("false") running: "cc" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-march=skylake" "-O3" "-pipe" "-m64" "-E" "/var/tmp/portage/dev-util/cargo-0.30.0-r1/work/cargo-0.30.0/target/release/build/openssl-sys-43945062714c9a5d/out/expando.c" exit code: 0 cargo:rustc-cfg=osslconf="OPENSSL_NO_BUF_FREELISTS" cargo:rustc-cfg=osslconf="OPENSSL_NO_COMP" cargo:rustc-cfg=osslconf="OPENSSL_NO_KRB5" cargo:rustc-cfg=osslconf="OPENSSL_NO_PSK" cargo:rustc-cfg=osslconf="OPENSSL_NO_RFC3779" cargo:rustc-cfg=osslconf="OPENSSL_NO_SRP" cargo:rustc-cfg=osslconf="OPENSSL_NO_SSL3_METHOD" cargo:conf=OPENSSL_NO_BUF_FREELISTS,OPENSSL_NO_COMP,OPENSSL_NO_KRB5,OPENSSL_NO_PSK,OPENSSL_NO_RFC3779,OPENSSL_NO_SRP,OPENSSL_NO_SSL3_METHOD cargo:rustc-cfg=libressl cargo:rustc-cfg=libressl251 cargo:rustc-cfg=libressl261 cargo:rustc-cfg=libressl270 cargo:rustc-cfg=libressl273 cargo:rustc-cfg=libressl280 cargo:libressl_version_number=2090100f --- stderr thread 'main' panicked at ' This crate is only compatible with OpenSSL 1.0.1 through 1.1.1, or LibreSSL 2.5 through 2.7, but a different version of OpenSSL was found. The build is now aborting due to this version mismatch. ', /var/tmp/portage/dev-util/cargo-0.30.0-r1/work/cargo_home/gentoo/openssl-sys-0.9.36/build/main.rs:537:5 note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace. warning: build failed, waiting for other jobs to finish... error: build failed The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/proj/libressl.git/commit/?id=bf14a415b362e75ddc6b7381dda86c045abfd7f0 commit bf14a415b362e75ddc6b7381dda86c045abfd7f0 Author: Quentin Retornaz <gentoo@retornaz.com> AuthorDate: 2019-05-07 20:04:01 +0000 Commit: Stefan Strogin <steils@gentoo.org> CommitDate: 2019-05-09 04:18:13 +0000 dev-util/cargo: update openssl-sys crate to 0.9.45 for libressl 2.9.1 Package-Manager: Portage-2.3.62, Repoman-2.3.11 Signed-off-by: Quentin Retornaz <gentoo@retornaz.com> Bug: https://bugs.gentoo.org/678286 Closes: https://github.com/gentoo/libressl/pull/293 Signed-off-by: Stefan Strogin <steils@gentoo.org> dev-util/cargo/Manifest | 5 +++-- dev-util/cargo/cargo-0.30.0-r1.ebuild | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) |
Current stable cargo 0.30.0 cannot be rebuilt against libressl-2.8.3 which just became stable. I believe this is major since at least firefox depends on cargo, and there is no unstable upstream cargo in portage yet to fix that. The relevant snippet from the build process: > [...] > > Compiling tempfile v3.0.4 > Compiling clap v2.32.0 > error: failed to run custom build command for `openssl-sys v0.9.36` > process didn't exit successfully: `/var/tmp/portage/dev-util/cargo-0.30.0/work/cargo-0.30.0/target/release/build/openssl-sys-289fa0e97cfedf35/build-script-main` (exit code: 101) > --- stdout > cargo:rerun-if-env-changed=X86_64_UNKNOWN_LINUX_GNU_OPENSSL_LIB_DIR > cargo:rerun-if-env-changed=OPENSSL_LIB_DIR > cargo:rerun-if-env-changed=X86_64_UNKNOWN_LINUX_GNU_OPENSSL_INCLUDE_DIR > cargo:rerun-if-env-changed=OPENSSL_INCLUDE_DIR > cargo:rerun-if-env-changed=X86_64_UNKNOWN_LINUX_GNU_OPENSSL_DIR > cargo:rerun-if-env-changed=OPENSSL_DIR > cargo:rustc-link-lib=ssl > cargo:rustc-link-lib=crypto > OPT_LEVEL = Some("3") > TARGET = Some("x86_64-unknown-linux-gnu") > HOST = Some("x86_64-unknown-linux-gnu") > CC_x86_64-unknown-linux-gnu = None > CC_x86_64_unknown_linux_gnu = None > HOST_CC = None > CC = None > CFLAGS_x86_64-unknown-linux-gnu = None > CFLAGS_x86_64_unknown_linux_gnu = None > HOST_CFLAGS = None > CFLAGS = Some("-march=native -g0 -O3 -pipe -fomit-frame-pointer -mindirect-branch=thunk -mfunction-return=thunk -mindirect-branch-register -fno-diagnostics-show-caret -flto=5 -fuse-linker-plugin -fno-lto -fno-use-linker-plugin") > DEBUG = Some("false") > running: "cc" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-march=native" "-g0" "-O3" "-pipe" "-fomit-frame-pointer" "-mindirect-branch=thunk" "-mfunction-return=thunk" "-mindirect-branch-register" "-fno-diagnostics-show-caret" "-flto=5" "-fuse-linker-plugin" "-fno-lto" "-fno-use-linker-plugin" "-m64" "-E" "/var/tmp/portage/dev-util/cargo-0.30.0/work/cargo-0.30.0/target/release/build/openssl-sys-c16fb61044f52df6/out/expando.c" > exit code: 0 > cargo:rustc-cfg=osslconf="OPENSSL_NO_BUF_FREELISTS" > cargo:rustc-cfg=osslconf="OPENSSL_NO_COMP" > cargo:rustc-cfg=osslconf="OPENSSL_NO_KRB5" > cargo:rustc-cfg=osslconf="OPENSSL_NO_PSK" > cargo:rustc-cfg=osslconf="OPENSSL_NO_RFC3779" > cargo:rustc-cfg=osslconf="OPENSSL_NO_SRP" > cargo:rustc-cfg=osslconf="OPENSSL_NO_SSL3_METHOD" > cargo:conf=OPENSSL_NO_BUF_FREELISTS,OPENSSL_NO_COMP,OPENSSL_NO_KRB5,OPENSSL_NO_PSK,OPENSSL_NO_RFC3779,OPENSSL_NO_SRP,OPENSSL_NO_SSL3_METHOD > cargo:rustc-cfg=libressl > cargo:rustc-cfg=libressl251 > cargo:rustc-cfg=libressl261 > cargo:rustc-cfg=libressl270 > cargo:rustc-cfg=libressl273 > cargo:rustc-cfg=libressl280 > cargo:libressl_version_number=2080300f > > --- stderr > thread 'main' panicked at ' > > This crate is only compatible with OpenSSL 1.0.1 through 1.1.1, or LibreSSL 2.5 > through 2.7, but a different version of OpenSSL was found. The build is now aborting > due to this version mismatch. > > ', /var/tmp/portage/dev-util/cargo-0.30.0/work/cargo_home/gentoo/openssl-sys-0.9.36/build/main.rs:537:5 > note: Run with `RUST_BACKTRACE=1` for a backtrace. > > warning: build failed, waiting for other jobs to finish... > error: build failed > * ERROR: dev-util/cargo-0.30.0::gentoo failed (compile phase): > * (no error message) > * > * Call stack: > * ebuild.sh, line 124: Called src_compile > * environment, line 2147: Called die > * The specific snippet of code: > * ${cargo} build -j$(makeopts_jobs) --release || die; > * > * If you need support, post the output of `emerge --info '=dev-util/cargo-0.30.0::gentoo'`, > * the complete build log and the output of `emerge -pqv '=dev-util/cargo-0.30.0::gentoo'`. > * The complete build log is located at '/var/tmp/portage/dev-util/cargo-0.30.0/temp/build.log'. > * The ebuild environment file is located at '/var/tmp/portage/dev-util/cargo-0.30.0/temp/environment'. > * Working directory: '/var/tmp/portage/dev-util/cargo-0.30.0/work/cargo-0.30.0' > * S: '/var/tmp/portage/dev-util/cargo-0.30.0/work/cargo-0.30.0' > > >>> Failed to emerge dev-util/cargo-0.30.0, Log file: