rustup icon indicating copy to clipboard operation
rustup copied to clipboard

Error: failed to run custom build command for `wepoll-ffi v0.1.2`

Open rainrisa opened this issue 3 years ago • 1 comments

Problem

$ cargo build
   Compiling ring v0.16.20
   Compiling wepoll-ffi v0.1.2
   Compiling num-integer v0.1.45
   Compiling blocking v1.2.0
The following warnings were emitted during compilation:

warning: vendor/wepoll/wepoll.c:1:0: sorry, unimplemented: 64-bit mode not compiled in
warning:  /*
warning:  

error: failed to run custom build command for `wepoll-ffi v0.1.2`

Caused by:
  process didn't exit successfully: `C:\Users\rain\Documents\rainft\kanji-api\target\debug\build\wepoll-ffi-5c3bb1c3a1789194\build-script-build` (exit code: 
1)
  --- stdout
  TARGET = Some("x86_64-pc-windows-gnu")
  OPT_LEVEL = Some("0")
  HOST = Some("x86_64-pc-windows-gnu")
  CC_x86_64-pc-windows-gnu = None
  CC_x86_64_pc_windows_gnu = None
  HOST_CC = None
  CC = None
  CFLAGS_x86_64-pc-windows-gnu = None
  CFLAGS_x86_64_pc_windows_gnu = None
  HOST_CFLAGS = None
  CFLAGS = None
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some("true")
  CARGO_CFG_TARGET_FEATURE = Some("fxsr,sse,sse2")
  running: "gcc.exe" "-O0" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-Wall" "-Wextra" "-DNULL_OVERLAPPED_WAKEUPS_PATCH" "-o" "C:\\Users\\rain\\Documents\\rainft\\kanji-api\\target\\debug\\build\\wepoll-ffi-6f0639f4a4f44b6a\\out\\vendor/wepoll/wepoll.o" "-c" "vendor/wepoll/wepoll.c"   
  cargo:warning=vendor/wepoll/wepoll.c:1:0: sorry, unimplemented: 64-bit mode not compiled in
  cargo:warning= /*
  cargo:warning=
  exit code: 1

  --- stderr


  error occurred: Command "gcc.exe" "-O0" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-Wall" "-Wextra" "-DNULL_OVERLAPPED_WAKEUPS_PATCH" "-o" "C:\\Users\\rain\\Documents\\rainft\\kanji-api\\target\\debug\\build\\wepoll-ffi-6f0639f4a4f44b6a\\out\\vendor/wepoll/wepoll.o" "-c" "vendor/wepoll/wepoll.c" with args "gcc.exe" did not execute successfully (status code exit code: 1).


warning: build failed, waiting for other jobs to finish...
error: failed to run custom build command for `ring v0.16.20`

Caused by:
  process didn't exit successfully: `C:\Users\rain\Documents\rainft\kanji-api\target\debug\build\ring-73de7a1979771a94\build-script-build` (exit code: 101)  
  --- stdout
  OPT_LEVEL = Some("0")
  TARGET = Some("x86_64-pc-windows-gnu")
  HOST = Some("x86_64-pc-windows-gnu")
  CC_x86_64-pc-windows-gnu = None
  CC_x86_64_pc_windows_gnu = None
  HOST_CC = None
  CC = None
  CFLAGS_x86_64-pc-windows-gnu = None
  CFLAGS_x86_64_pc_windows_gnu = None
  HOST_CFLAGS = None
  CFLAGS = None
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some("true")
  CARGO_CFG_TARGET_FEATURE = Some("fxsr,sse,sse2")

  --- stderr
  running "gcc.exe" "-O0" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "include" "-Wall" "-Wextra" "-std=c1x" "-Wbad-function-cast" "-Wnested-externs" "-Wstrict-prototypes" "-pedantic" "-pedantic-errors" "-Wall" "-Wextra" "-Wcast-align" "-Wcast-qual" "-Wconversion" "-Wenum-compare" "-Wfloat-equal" "-Wformat=2" "-Winline" "-Winvalid-pch" "-Wmissing-field-initializers" "-Wmissing-include-dirs" "-Wredundant-decls" "-Wshadow" "-Wsign-compare" "-Wsign-conversion" "-Wundef" "-Wuninitialized" "-Wwrite-strings" "-fno-strict-aliasing" "-fvisibility=hidden" "-g3" "-DNDEBUG" "-c" "-oC:\\Users\\rain\\Documents\\rainft\\kanji-api\\target\\debug\\build\\ring-45dd95470277b939\\out\\aes_nohw.o" "crypto/fipsmodule/aes/aes_nohw.c"
  crypto/fipsmodule/aes/aes_nohw.c:1:0: sorry, unimplemented: 64-bit mode not compiled in
   /* Copyright (c) 2019, Google Inc.

  thread 'main' panicked at 'execution failed', C:\Users\rain\.cargo\registry\src\github.com-1ecc6299db9ec823\ring-0.16.20\build.rs:656:9
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Steps

  1. Run cargo new kanji-api
  2. Add this to Cargo.toml
[package]
name = "kanji-api"
version = "0.1.0"
edition = "2021"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
async-std = "1.12.0"
dotenvy = "0.15.1"

[dependencies.mongodb]
version = "2.1.0"
default-features = false
features = ["async-std-runtime"]
  1. Run cargo build

Possible Solution(s)

No response

Notes

I'm new to Rust and this is my first project

Rustup version

$ rustup --version
rustup 1.25.1 (bb60b1e89 2022-07-12)
info: This is the version for the rustup toolchain manager, not the rustc compiler.
info: The currently active `rustc` version is `rustc 1.62.1 (e092d0b6b 2022-07-16)`

Installed toolchains

$ rustup show
Default host: x86_64-pc-windows-gnu
rustup home:  C:\Users\rain\.rustup

installed toolchains
--------------------

stable-x86_64-pc-windows-gnu (default)
stable-x86_64-pc-windows-msvc

active toolchain
----------------

stable-x86_64-pc-windows-gnu (default)
rustc 1.62.1 (e092d0b6b 2022-07-16)

rainrisa avatar Aug 09 '22 13:08 rainrisa

This looks to be an issue with your environment configuration and using gcc. https://stackoverflow.com/questions/38589886/sorry-unimplemented-64-bit-mode-not-compiled-in appears to have some suggestions for how to resolve it.

This issue tracker is for rustup, the tool for choosing different Rust toolchains. I might suggest using one of the user forums such as https://users.rust-lang.org/ for questions about setting up your environment.

ehuss avatar Aug 09 '22 20:08 ehuss

Looks like this is not rustup issue. So I am going to close it. Thanks! If you have any other questions please feel free to comment.

0xPoe avatar Oct 09 '22 02:10 0xPoe