[DOCKER rustdesk-builder] error occurred: Failed to find tool. Is x86_64-w64-mingw32-gcc installed? #3090

Closed
opened 2026-02-21 01:06:52 -05:00 by deekerman · 1 comment
Owner

Originally created by @gowy222 on GitHub (Nov 5, 2024).

Bug Description

Is cross-compilation supported?

   Compiling target_build_utils v0.3.1
   Compiling zstd-sys v2.0.11+zstd.1.5.6
   Compiling libsodium-sys v0.2.7
   Compiling backtrace v0.3.73
   Compiling ring v0.17.8
   Compiling bzip2-sys v0.1.11+1.0.8
   Compiling webm-sys v1.0.4 (https://github.com/rustdesk-org/rust-webm#d2c4d3ac)
   Compiling clipboard v0.1.0 (/home/user/rustdesk/libs/clipboard)
   Compiling impersonate_system v0.1.0 (https://github.com/rustdesk-org/impersonate-system#2f429010)
   Compiling pbkdf2 v0.11.0
   Compiling windows v0.54.0
The following warnings were emitted during compilation:

warning: bzip2-sys@0.1.11+1.0.8: Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed?

error: failed to run custom build command for `bzip2-sys v0.1.11+1.0.8`

Caused by:
  process didn't exit successfully: `/home/user/rustdesk/target/release/build/bzip2-sys-ad356055eac8df80/build-script-build` (exit status: 1)
  --- stdout
  TARGET = Some(x86_64-pc-windows-gnu)
  OPT_LEVEL = Some(3)
  HOST = Some(x86_64-unknown-linux-gnu)
  cargo:rerun-if-env-changed=CC_x86_64-pc-windows-gnu
  CC_x86_64-pc-windows-gnu = None
  cargo:rerun-if-env-changed=CC_x86_64_pc_windows_gnu
  CC_x86_64_pc_windows_gnu = None
  cargo:rerun-if-env-changed=TARGET_CC
  TARGET_CC = None
  cargo:rerun-if-env-changed=CC
  CC = None
  cargo:rerun-if-env-changed=CROSS_COMPILE
  CROSS_COMPILE = None
  RUSTC_LINKER = None
  cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT
  cargo:warning=Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed?
  RUSTC_WRAPPER = None
  cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some(false)
  CARGO_CFG_TARGET_FEATURE = Some(cmpxchg16b,fxsr,sse,sse2,sse3)
  cargo:rerun-if-env-changed=CFLAGS_x86_64-pc-windows-gnu
  CFLAGS_x86_64-pc-windows-gnu = None
  cargo:rerun-if-env-changed=CFLAGS_x86_64_pc_windows_gnu
  CFLAGS_x86_64_pc_windows_gnu = None
  cargo:rerun-if-env-changed=TARGET_CFLAGS
  TARGET_CFLAGS = None
  cargo:rerun-if-env-changed=CFLAGS
  CFLAGS = None

  --- stderr


  error occurred: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed?


warning: build failed, waiting for other jobs to finish...
The following warnings were emitted during compilation:

warning: webm-sys@1.0.4: Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-g++` installed?

error: failed to run custom build command for `webm-sys v1.0.4 (https://github.com/rustdesk-org/rust-webm#d2c4d3ac)`

Caused by:
  process didn't exit successfully: `/home/user/rustdesk/target/release/build/webm-sys-40c146c2461ca9ca/build-script-build` (exit status: 1)
  --- stdout
  cargo:rerun-if-changed=ffi.cpp
  OUT_DIR = Some(/home/user/rustdesk/target/x86_64-pc-windows-gnu/release/build/webm-sys-105b457495e027bf/out)
  TARGET = Some(x86_64-pc-windows-gnu)
  OPT_LEVEL = Some(3)
  HOST = Some(x86_64-unknown-linux-gnu)
  cargo:rerun-if-env-changed=CXX_x86_64-pc-windows-gnu
  CXX_x86_64-pc-windows-gnu = None
  cargo:rerun-if-env-changed=CXX_x86_64_pc_windows_gnu
  CXX_x86_64_pc_windows_gnu = None
  cargo:rerun-if-env-changed=TARGET_CXX
  TARGET_CXX = None
  cargo:rerun-if-env-changed=CXX
  CXX = None
  cargo:rerun-if-env-changed=CROSS_COMPILE
  CROSS_COMPILE = None
  RUSTC_LINKER = None
  cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT
  cargo:warning=Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-g++` installed?
  RUSTC_WRAPPER = None
  cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some(false)
  CARGO_CFG_TARGET_FEATURE = Some(cmpxchg16b,fxsr,sse,sse2,sse3)
  cargo:rerun-if-env-changed=CXXFLAGS_x86_64-pc-windows-gnu
  CXXFLAGS_x86_64-pc-windows-gnu = None
  cargo:rerun-if-env-changed=CXXFLAGS_x86_64_pc_windows_gnu
  CXXFLAGS_x86_64_pc_windows_gnu = None
  cargo:rerun-if-env-changed=TARGET_CXXFLAGS
  TARGET_CXXFLAGS = None
  cargo:rerun-if-env-changed=CXXFLAGS
  CXXFLAGS = None

  --- stderr


  error occurred: Failed to find tool. Is `x86_64-w64-mingw32-g++` installed?


The following warnings were emitted during compilation:

warning: impersonate_system@0.1.0: Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed?

error: failed to run custom build command for `impersonate_system v0.1.0 (https://github.com/rustdesk-org/impersonate-system#2f429010)`

Caused by:
  process didn't exit successfully: `/home/user/rustdesk/target/release/build/impersonate_system-3b7332f77bd47875/build-script-build` (exit status: 1)
  --- stdout
  cargo:rustc-link-lib=advapi32
  OUT_DIR = Some(/home/user/rustdesk/target/x86_64-pc-windows-gnu/release/build/impersonate_system-941b4c8777949180/out)
  TARGET = Some(x86_64-pc-windows-gnu)
  OPT_LEVEL = Some(3)
  HOST = Some(x86_64-unknown-linux-gnu)
  cargo:rerun-if-env-changed=CC_x86_64-pc-windows-gnu
  CC_x86_64-pc-windows-gnu = None
  cargo:rerun-if-env-changed=CC_x86_64_pc_windows_gnu
  CC_x86_64_pc_windows_gnu = None
  cargo:rerun-if-env-changed=TARGET_CC
  TARGET_CC = None
  cargo:rerun-if-env-changed=CC
  CC = None
  cargo:rerun-if-env-changed=CROSS_COMPILE
  CROSS_COMPILE = None
  RUSTC_LINKER = None
  cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT
  cargo:warning=Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed?
  RUSTC_WRAPPER = None
  cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some(false)
  CARGO_CFG_TARGET_FEATURE = Some(cmpxchg16b,fxsr,sse,sse2,sse3)
  cargo:rerun-if-env-changed=CFLAGS_x86_64-pc-windows-gnu
  CFLAGS_x86_64-pc-windows-gnu = None
  cargo:rerun-if-env-changed=CFLAGS_x86_64_pc_windows_gnu
  CFLAGS_x86_64_pc_windows_gnu = None
  cargo:rerun-if-env-changed=TARGET_CFLAGS
  TARGET_CFLAGS = None
  cargo:rerun-if-env-changed=CFLAGS
  CFLAGS = None

  --- stderr


  error occurred: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed?


root@2f0926f5487b:/workspace/rustdesk# 

How to Reproduce

rustdesk-builder --release --target x86_64-pc-windows-gnu

git clone https://github.com/rustdesk/rustdesk
cd rustdesk
docker build -t "rustdesk-builder" .

docker run --rm -it -v $PWD:/home/user/rustdesk -v rustdesk-git-cache:/home/user/.cargo/git -v rustdesk-registry-cache:/home/user/.cargo/registry -e PUID="$(id -u)" -e PGID="$(id -g)" rustdesk-builder --release --target x86_64-pc-windows-gnu

Expected Behavior

docker style rustdesk-builder can build for all os/target
here this action is build for windows x86_64 exe release file in debian

Operating system(s) on local side and remote side

debian + docker

RustDesk Version(s) on local side and remote side

git clone -> master -> newest?

Screenshots

see full log in Bug Description

Additional Context

if you need to specify different arguments to the build command, you may do so at the end of the command in the <OPTIONAL-ARGS> position.

where can i find the doc for OPTIONAL-ARGS..?

Originally created by @gowy222 on GitHub (Nov 5, 2024). ### Bug Description Is cross-compilation supported? ``` Compiling target_build_utils v0.3.1 Compiling zstd-sys v2.0.11+zstd.1.5.6 Compiling libsodium-sys v0.2.7 Compiling backtrace v0.3.73 Compiling ring v0.17.8 Compiling bzip2-sys v0.1.11+1.0.8 Compiling webm-sys v1.0.4 (https://github.com/rustdesk-org/rust-webm#d2c4d3ac) Compiling clipboard v0.1.0 (/home/user/rustdesk/libs/clipboard) Compiling impersonate_system v0.1.0 (https://github.com/rustdesk-org/impersonate-system#2f429010) Compiling pbkdf2 v0.11.0 Compiling windows v0.54.0 The following warnings were emitted during compilation: warning: bzip2-sys@0.1.11+1.0.8: Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed? error: failed to run custom build command for `bzip2-sys v0.1.11+1.0.8` Caused by: process didn't exit successfully: `/home/user/rustdesk/target/release/build/bzip2-sys-ad356055eac8df80/build-script-build` (exit status: 1) --- stdout TARGET = Some(x86_64-pc-windows-gnu) OPT_LEVEL = Some(3) HOST = Some(x86_64-unknown-linux-gnu) cargo:rerun-if-env-changed=CC_x86_64-pc-windows-gnu CC_x86_64-pc-windows-gnu = None cargo:rerun-if-env-changed=CC_x86_64_pc_windows_gnu CC_x86_64_pc_windows_gnu = None cargo:rerun-if-env-changed=TARGET_CC TARGET_CC = None cargo:rerun-if-env-changed=CC CC = None cargo:rerun-if-env-changed=CROSS_COMPILE CROSS_COMPILE = None RUSTC_LINKER = None cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT cargo:warning=Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed? RUSTC_WRAPPER = None cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS CRATE_CC_NO_DEFAULTS = None DEBUG = Some(false) CARGO_CFG_TARGET_FEATURE = Some(cmpxchg16b,fxsr,sse,sse2,sse3) cargo:rerun-if-env-changed=CFLAGS_x86_64-pc-windows-gnu CFLAGS_x86_64-pc-windows-gnu = None cargo:rerun-if-env-changed=CFLAGS_x86_64_pc_windows_gnu CFLAGS_x86_64_pc_windows_gnu = None cargo:rerun-if-env-changed=TARGET_CFLAGS TARGET_CFLAGS = None cargo:rerun-if-env-changed=CFLAGS CFLAGS = None --- stderr error occurred: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed? warning: build failed, waiting for other jobs to finish... The following warnings were emitted during compilation: warning: webm-sys@1.0.4: Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-g++` installed? error: failed to run custom build command for `webm-sys v1.0.4 (https://github.com/rustdesk-org/rust-webm#d2c4d3ac)` Caused by: process didn't exit successfully: `/home/user/rustdesk/target/release/build/webm-sys-40c146c2461ca9ca/build-script-build` (exit status: 1) --- stdout cargo:rerun-if-changed=ffi.cpp OUT_DIR = Some(/home/user/rustdesk/target/x86_64-pc-windows-gnu/release/build/webm-sys-105b457495e027bf/out) TARGET = Some(x86_64-pc-windows-gnu) OPT_LEVEL = Some(3) HOST = Some(x86_64-unknown-linux-gnu) cargo:rerun-if-env-changed=CXX_x86_64-pc-windows-gnu CXX_x86_64-pc-windows-gnu = None cargo:rerun-if-env-changed=CXX_x86_64_pc_windows_gnu CXX_x86_64_pc_windows_gnu = None cargo:rerun-if-env-changed=TARGET_CXX TARGET_CXX = None cargo:rerun-if-env-changed=CXX CXX = None cargo:rerun-if-env-changed=CROSS_COMPILE CROSS_COMPILE = None RUSTC_LINKER = None cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT cargo:warning=Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-g++` installed? RUSTC_WRAPPER = None cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS CRATE_CC_NO_DEFAULTS = None DEBUG = Some(false) CARGO_CFG_TARGET_FEATURE = Some(cmpxchg16b,fxsr,sse,sse2,sse3) cargo:rerun-if-env-changed=CXXFLAGS_x86_64-pc-windows-gnu CXXFLAGS_x86_64-pc-windows-gnu = None cargo:rerun-if-env-changed=CXXFLAGS_x86_64_pc_windows_gnu CXXFLAGS_x86_64_pc_windows_gnu = None cargo:rerun-if-env-changed=TARGET_CXXFLAGS TARGET_CXXFLAGS = None cargo:rerun-if-env-changed=CXXFLAGS CXXFLAGS = None --- stderr error occurred: Failed to find tool. Is `x86_64-w64-mingw32-g++` installed? The following warnings were emitted during compilation: warning: impersonate_system@0.1.0: Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed? error: failed to run custom build command for `impersonate_system v0.1.0 (https://github.com/rustdesk-org/impersonate-system#2f429010)` Caused by: process didn't exit successfully: `/home/user/rustdesk/target/release/build/impersonate_system-3b7332f77bd47875/build-script-build` (exit status: 1) --- stdout cargo:rustc-link-lib=advapi32 OUT_DIR = Some(/home/user/rustdesk/target/x86_64-pc-windows-gnu/release/build/impersonate_system-941b4c8777949180/out) TARGET = Some(x86_64-pc-windows-gnu) OPT_LEVEL = Some(3) HOST = Some(x86_64-unknown-linux-gnu) cargo:rerun-if-env-changed=CC_x86_64-pc-windows-gnu CC_x86_64-pc-windows-gnu = None cargo:rerun-if-env-changed=CC_x86_64_pc_windows_gnu CC_x86_64_pc_windows_gnu = None cargo:rerun-if-env-changed=TARGET_CC TARGET_CC = None cargo:rerun-if-env-changed=CC CC = None cargo:rerun-if-env-changed=CROSS_COMPILE CROSS_COMPILE = None RUSTC_LINKER = None cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT cargo:warning=Compiler family detection failed due to error: ToolNotFound: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed? RUSTC_WRAPPER = None cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS CRATE_CC_NO_DEFAULTS = None DEBUG = Some(false) CARGO_CFG_TARGET_FEATURE = Some(cmpxchg16b,fxsr,sse,sse2,sse3) cargo:rerun-if-env-changed=CFLAGS_x86_64-pc-windows-gnu CFLAGS_x86_64-pc-windows-gnu = None cargo:rerun-if-env-changed=CFLAGS_x86_64_pc_windows_gnu CFLAGS_x86_64_pc_windows_gnu = None cargo:rerun-if-env-changed=TARGET_CFLAGS TARGET_CFLAGS = None cargo:rerun-if-env-changed=CFLAGS CFLAGS = None --- stderr error occurred: Failed to find tool. Is `x86_64-w64-mingw32-gcc` installed? root@2f0926f5487b:/workspace/rustdesk# ``` ### How to Reproduce rustdesk-builder --release --target x86_64-pc-windows-gnu ``` git clone https://github.com/rustdesk/rustdesk cd rustdesk docker build -t "rustdesk-builder" . docker run --rm -it -v $PWD:/home/user/rustdesk -v rustdesk-git-cache:/home/user/.cargo/git -v rustdesk-registry-cache:/home/user/.cargo/registry -e PUID="$(id -u)" -e PGID="$(id -g)" rustdesk-builder --release --target x86_64-pc-windows-gnu ``` ### Expected Behavior docker style rustdesk-builder can build for all os/target here this action is build for windows x86_64 exe release file in debian ### Operating system(s) on local side and remote side debian + docker ### RustDesk Version(s) on local side and remote side git clone -> master -> newest? ### Screenshots see full log in Bug Description ### Additional Context ``` if you need to specify different arguments to the build command, you may do so at the end of the command in the <OPTIONAL-ARGS> position. ``` where can i find the doc for OPTIONAL-ARGS..?
deekerman 2026-02-21 01:06:52 -05:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@rustdesk commented on GitHub (Nov 5, 2024):

#763

@rustdesk commented on GitHub (Nov 5, 2024): #763
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/rustdesk-rustdesk#3090
No description provided.