Skip to content

1.0.58/#527 broke building openssl on macOS #529

Closed
@benesch

Description

@benesch

Build log here: https://github.com/MaterializeInc/rust-krb5-src/pull/11/checks?check_run_id=850555939

2020-07-08T16:08:37.5993460Z error: failed to run custom build command for `openssl-sys v0.9.58`
2020-07-08T16:08:37.5994010Z 
2020-07-08T16:08:37.5994410Z Caused by:
2020-07-08T16:08:37.5995340Z   process didn't exit successfully: `/Users/runner/work/rust-krb5-src/rust-krb5-src/target/debug/build/openssl-sys-6d10d87696b11ef2/build-script-main` (exit code: 101)
2020-07-08T16:08:37.5996130Z --- stdout
2020-07-08T16:08:37.5996900Z cargo:rustc-cfg=const_fn
2020-07-08T16:08:37.5997720Z cargo:rerun-if-env-changed=X86_64_APPLE_DARWIN_OPENSSL_NO_VENDOR
2020-07-08T16:08:37.5998170Z X86_64_APPLE_DARWIN_OPENSSL_NO_VENDOR unset
2020-07-08T16:08:37.5998940Z cargo:rerun-if-env-changed=OPENSSL_NO_VENDOR
2020-07-08T16:08:37.5999350Z OPENSSL_NO_VENDOR unset
2020-07-08T16:08:37.6000060Z CC_x86_64-apple-darwin = None
2020-07-08T16:08:37.6000480Z CC_x86_64_apple_darwin = None
2020-07-08T16:08:37.6000830Z HOST_CC = None
2020-07-08T16:08:37.6001150Z CC = None
2020-07-08T16:08:37.6001860Z CFLAGS_x86_64-apple-darwin = None
2020-07-08T16:08:37.6002380Z CFLAGS_x86_64_apple_darwin = None
2020-07-08T16:08:37.6002760Z HOST_CFLAGS = None
2020-07-08T16:08:37.6003110Z CFLAGS = None
2020-07-08T16:08:37.6003460Z CRATE_CC_NO_DEFAULTS = None
2020-07-08T16:08:37.6003810Z DEBUG = Some("true")
2020-07-08T16:08:37.6004170Z CARGO_CFG_TARGET_FEATURE = Some("fxsr,sse,sse2,sse3,ssse3")
2020-07-08T16:08:37.6005220Z running "perl" "./Configure" "--prefix=/Users/runner/work/rust-krb5-src/rust-krb5-src/target/debug/build/openssl-sys-95f633180738d2b8/out/openssl-build/install" "no-dso" "no-ssl3" "no-unit-test" "no-comp" "no-zlib" "no-zlib-dynamic" "no-shared" "darwin64-x86_64-cc" "-O2" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-fno-omit-frame-pointer" "-m64" "-arch" "x86_64"
2020-07-08T16:08:37.6005640Z 
2020-07-08T16:08:37.6006280Z --- stderr
2020-07-08T16:08:37.6007140Z 
2020-07-08T16:08:37.6007920Z Failure!  build file wasn't produced.
2020-07-08T16:08:37.6008900Z Please read INSTALL and associated NOTES files.  You may also have to look over
2020-07-08T16:08:37.6009300Z your available compiler tool chain or change your configuration.
2020-07-08T16:08:37.6009570Z 
2020-07-08T16:08:37.6010350Z target already defined - darwin64-x86_64-cc (offending arg: x86_64)
2020-07-08T16:08:37.6011110Z thread 'main' panicked at '
2020-07-08T16:08:37.6011490Z 
2020-07-08T16:08:37.6011740Z 
2020-07-08T16:08:37.6012100Z Error configuring OpenSSL build:
2020-07-08T16:08:37.6013880Z     Command: "perl" "./Configure" "--prefix=/Users/runner/work/rust-krb5-src/rust-krb5-src/target/debug/build/openssl-sys-95f633180738d2b8/out/openssl-build/install" "no-dso" "no-ssl3" "no-unit-test" "no-comp" "no-zlib" "no-zlib-dynamic" "no-shared" "darwin64-x86_64-cc" "-O2" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-fno-omit-frame-pointer" "-m64" "-arch" "x86_64"
2020-07-08T16:08:37.6014410Z     Exit status: exit code: 255
2020-07-08T16:08:37.6014740Z 
2020-07-08T16:08:37.6015010Z 
2020-07-08T16:08:37.6015830Z     ', /Users/runner/.cargo/registry/src/github.com-1ecc6299db9ec823/openssl-src-111.10.0+1.1.1g/src/lib.rs:386:13
2020-07-08T16:08:37.6016290Z note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
2020-07-08T16:08:37.6016620Z 
2020-07-08T16:08:37.6016970Z warning: build failed, waiting for other jobs to finish...
2020-07-08T16:08:37.8390070Z error: build failed
2020-07-08T16:08:37.8444360Z ##[error]Process completed with exit code 101.
2020-07-08T16:08:37.8467870Z Cleaning up orphan processes

The issue is that OpenSSL's configure command does not allow specifying both darwin64-x86_64-cc and -arch x86_64. The reason -arch appears in there at all is because of #527, as far as I can tell.

Possibly the solution is to adjust openssl-src to skip the -arch flag here, but figured I'd raise the issue here since it was a patch release of cc that caused the breakage.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions