Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to build for armv7-unknown-linux-gnueabihf #132

Open
JohnTheCoolingFan opened this issue Mar 31, 2022 · 1 comment
Open

Unable to build for armv7-unknown-linux-gnueabihf #132

JohnTheCoolingFan opened this issue Mar 31, 2022 · 1 comment

Comments

@JohnTheCoolingFan
Copy link

Compiled using cargo-zigbuild as it's easier to set up and use.
Command: cargo zigbuild --target armv7-unknown-linux-gnueabihf
Here's the error that I get when trying to compile a project that depends on openssl-sys:

error: failed to run custom build command for `openssl-sys v0.9.72`

Caused by:
  process didn't exit successfully: `/home/jtcf/rustworks/rusted-motorchik/target/debug/build/openssl-sys-7685c3558ec24905/build-script-main` (exit status: 101)
  --- stdout
  cargo:rustc-cfg=const_fn
  cargo:rerun-if-env-changed=ARMV7_UNKNOWN_LINUX_GNUEABIHF_OPENSSL_NO_VENDOR
  ARMV7_UNKNOWN_LINUX_GNUEABIHF_OPENSSL_NO_VENDOR unset
  cargo:rerun-if-env-changed=OPENSSL_NO_VENDOR
  OPENSSL_NO_VENDOR unset
  CC_armv7-unknown-linux-gnueabihf = None
  CC_armv7_unknown_linux_gnueabihf = Some("/root/.cache/cargo-zigbuild/0.7.0/zigcc-armv7-unknown-linux-gnueabihf.sh")
  CFLAGS_armv7-unknown-linux-gnueabihf = None
  CFLAGS_armv7_unknown_linux_gnueabihf = None
  TARGET_CFLAGS = None
  CFLAGS = None
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some("true")
  CARGO_CFG_TARGET_FEATURE = None
  running "perl" "./Configure" "--prefix=/home/jtcf/rustworks/rusted-motorchik/target/armv7-unknown-linux-gnueabihf/debug/build/openssl-sys-8cac96e5bf8a3062/out/openssl-build/install" "no-dso" "no-shared" "no-ssl3" "no-unit-test" "no-comp" "no-zlib" "no-zlib-dynamic" "no-md2" "no-rc5" "no-weak-ssl-ciphers" "no-camellia" "no-idea" "no-seed" "linux-armv4" "-O2" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-fno-omit-frame-pointer" "-march=armv7-a" "-mfpu=vfpv3-d16"
  Configuring OpenSSL version 1.1.1n (0x101010efL) for linux-armv4
  Using os-specific seed configuration
  Creating configdata.pm
  Creating Makefile

  **********************************************************************
  ***                                                                ***
  ***   OpenSSL has been successfully configured                     ***
  ***                                                                ***
  ***   If you encounter a problem while building, please open an    ***
  ***   issue on GitHub <https://github.com/openssl/openssl/issues>  ***
  ***   and include the output from the following command:           ***
  ***                                                                ***
  ***       perl configdata.pm --dump                                ***
  ***                                                                ***
  ***   (If you are new to OpenSSL, you might want to consult the    ***
  ***   'Troubleshooting' section in the INSTALL file first)         ***
  ***                                                                ***
  **********************************************************************
  running "make" "depend"
  running "make" "build_libs"
  /usr/bin/perl "-I." -Mconfigdata "util/dofile.pl" \
      "-oMakefile" include/crypto/bn_conf.h.in > include/crypto/bn_conf.h
  /usr/bin/perl "-I." -Mconfigdata "util/dofile.pl" \
      "-oMakefile" include/crypto/dso_conf.h.in > include/crypto/dso_conf.h
  /usr/bin/perl "-I." -Mconfigdata "util/dofile.pl" \
      "-oMakefile" include/openssl/opensslconf.h.in > include/openssl/opensslconf.h
  make depend && make _build_libs
  make[1]: Entering directory '/home/jtcf/rustworks/rusted-motorchik/target/armv7-unknown-linux-gnueabihf/debug/build/openssl-sys-8cac96e5bf8a3062/out/openssl-build/build/src'
  make[1]: Leaving directory '/home/jtcf/rustworks/rusted-motorchik/target/armv7-unknown-linux-gnueabihf/debug/build/openssl-sys-8cac96e5bf8a3062/out/openssl-build/build/src'
  make[1]: Entering directory '/home/jtcf/rustworks/rusted-motorchik/target/armv7-unknown-linux-gnueabihf/debug/build/openssl-sys-8cac96e5bf8a3062/out/openssl-build/build/src'
  /root/.cache/cargo-zigbuild/0.7.0/zigcc-armv7-unknown-linux-gnueabihf.sh  -I. -Iinclude -fPIC -pthread -Wall -O3 -O2 -ffunction-sections -fdata-sections -fPIC -g -fno-omit-frame-pointer -march=armv7-a -mfpu=vfpv3-d16 -DOPENSSL_USE_NODELETE -DOPENSSL_PIC -DOPENSSL_CPUID_OBJ -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DKECCAK1600_ASM -DAES_ASM -DBSAES_ASM -DGHASH_ASM -DECP_NISTZ256_ASM -DPOLY1305_ASM -DOPENSSLDIR="\"/home/jtcf/rustworks/rusted-motorchik/target/armv7-unknown-linux-gnueabihf/debug/build/openssl-sys-8cac96e5bf8a3062/out/openssl-build/install/ssl\"" -DENGINESDIR="\"/home/jtcf/rustworks/rusted-motorchik/target/armv7-unknown-linux-gnueabihf/debug/build/openssl-sys-8cac96e5bf8a3062/out/openssl-build/install/lib/engines-1.1\"" -DNDEBUG   -c -o apps/app_rand.o apps/app_rand.c
  make[1]: Leaving directory '/home/jtcf/rustworks/rusted-motorchik/target/armv7-unknown-linux-gnueabihf/debug/build/openssl-sys-8cac96e5bf8a3062/out/openssl-build/build/src'

  --- stderr
  error: UnknownArchitecture
  make[1]: *** [Makefile:671: apps/app_rand.o] Error 1
  make: *** [Makefile:175: build_libs] Ошибка 2
  thread 'main' panicked at '


  Error building OpenSSL:
      Command: "make" "build_libs"
      Exit status: exit status: 2


      ', /root/.cargo/registry/src/git.luolix.top-1ecc6299db9ec823/openssl-src-111.18.0+1.1.1n/src/lib.rs:479:13
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: build failed
@messense
Copy link
Contributor

messense commented Apr 1, 2022

FYI, this is a zig issue: ziglang/zig#4911

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants