zstd
zstd copied to clipboard
Compiling zstd-sys v2.0.1+zstd.1.5.2 failure
C:/Users/yymt/.cargo/bin/cargo.exe build --color=always --message-format=json-diagnostic-rendered-ansi --package minigrep --bin minigrep
Compiling zstd-sys v2.0.1+zstd.1.5.2
The following warnings were emitted during compilation:
warning: during RTL pass: final
warning: zstd/lib/common\entropy_common.c: In function 'FSE_readNCount':
warning: zstd/lib/common\entropy_common.c:252:1: internal compiler error: in based_loc_descr, at dwarf2out.c:14264
warning: }
warning: ^
warning: libbacktrace could not find executable to open
warning: Please submit a full bug report,
warning: with preprocessed source if appropriate.
warning: See https://sourceforge.net/projects/mingw-w64 for instructions.
warning: during RTL pass: final
warning: zstd/lib/common\fse_decompress.c: In function 'FSE_buildDTable_wksp':
warning: zstd/lib/common\fse_decompress.c:179:1: internal compiler error: in based_loc_descr, at dwarf2out.c:14264
warning: }
warning: ^
warning: libbacktrace could not find executable to open
warning: Please submit a full bug report,
warning: with preprocessed source if appropriate.
warning: See https://sourceforge.net/projects/mingw-w64 for instructions.
warning: during RTL pass: final
warning: zstd/lib/compress\huf_compress.c: In function 'HUF_compress1X_usingCTable':
warning: zstd/lib/compress\huf_compress.c:1075:1: internal compiler error: in based_loc_descr, at dwarf2out.c:14264
warning: }
warning: ^
warning: libbacktrace could not find executable to open
warning: Please submit a full bug report,
warning: with preprocessed source if appropriate.
warning: See https://sourceforge.net/projects/mingw-w64 for instructions.
error: failed to run custom build command for zstd-sys v2.0.1+zstd.1.5.2
Caused by:
process didn't exit successfully: D:\code\rust\minigrep\target\debug\build\zstd-sys-f37cc8bfd3eec6ac\build-script-build
(exit code: 1)
--- stdout
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")
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/common\debug.o" "-c" "zstd/lib/common\debug.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/common\threading.o" "-c" "zstd/lib/common\threading.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\hist.o" "-c" "zstd/lib/compress\hist.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/common\zstd_common.o" "-c" "zstd/lib/common\zstd_common.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/common\pool.o" "-c" "zstd/lib/common\pool.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\huf_compress.o" "-c" "zstd/lib/compress\huf_compress.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\fse_compress.o" "-c" "zstd/lib/compress\fse_compress.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/common\fse_decompress.o" "-c" "zstd/lib/common\fse_decompress.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/common\error_private.o" "-c" "zstd/lib/common\error_private.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/common\entropy_common.o" "-c" "zstd/lib/common\entropy_common.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\zstdmt_compress.o" "-c" "zstd/lib/compress\zstdmt_compress.c"
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\zstd_compress.o" "-c" "zstd/lib/compress\zstd_compress.c"
exit code: 0
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\zstd_compress_literals.o" "-c" "zstd/lib/compress\zstd_compress_literals.c"
exit code: 0
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\zstd_compress_sequences.o" "-c" "zstd/lib/compress\zstd_compress_sequences.c"
exit code: 0
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\zstd_compress_superblock.o" "-c" "zstd/lib/compress\zstd_compress_superblock.c"
exit code: 0
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\zstd_double_fast.o" "-c" "zstd/lib/compress\zstd_double_fast.c"
exit code: 0
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\zstd_fast.o" "-c" "zstd/lib/compress\zstd_fast.c"
cargo:warning=during RTL pass: final
cargo:warning=zstd/lib/common\entropy_common.c: In function 'FSE_readNCount':
cargo:warning=zstd/lib/common\entropy_common.c:252:1: internal compiler error: in based_loc_descr, at dwarf2out.c:14264
cargo:warning= }
cargo:warning= ^
cargo:warning=libbacktrace could not find executable to open
cargo:warning=Please submit a full bug report,
cargo:warning=with preprocessed source if appropriate.
cargo:warning=See https://sourceforge.net/projects/mingw-w64 for instructions.
exit code: 1
running: "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/compress\zstd_lazy.o" "-c" "zstd/lib/compress\zstd_lazy.c"
exit code: 0
exit code: 0
exit code: 0
exit code: 0
exit code: 0
cargo:warning=during RTL pass: final
cargo:warning=zstd/lib/common\fse_decompress.c: In function 'FSE_buildDTable_wksp':
cargo:warning=zstd/lib/common\fse_decompress.c:179:1: internal compiler error: in based_loc_descr, at dwarf2out.c:14264
cargo:warning= }
cargo:warning= ^
cargo:warning=libbacktrace could not find executable to open
cargo:warning=Please submit a full bug report,
cargo:warning=with preprocessed source if appropriate.
cargo:warning=See https://sourceforge.net/projects/mingw-w64 for instructions.
exit code: 1
exit code: 0
cargo:warning=during RTL pass: final
cargo:warning=zstd/lib/compress\huf_compress.c: In function 'HUF_compress1X_usingCTable':
cargo:warning=zstd/lib/compress\huf_compress.c:1075:1: internal compiler error: in based_loc_descr, at dwarf2out.c:14264
cargo:warning= }
cargo:warning= ^
cargo:warning=libbacktrace could not find executable to open
cargo:warning=Please submit a full bug report,
cargo:warning=with preprocessed source if appropriate.
cargo:warning=See https://sourceforge.net/projects/mingw-w64 for instructions.
exit code: 1
exit code: 0
exit code: 0
exit code: 0
exit code: 0
--- stderr
error occurred: Command "gcc.exe" "-O3" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "zstd/lib/" "-I" "zstd/lib/common" "-I" "zstd/lib/legacy" "-fvisibility=hidden" "-DZSTD_DISABLE_ASM=" "-DZSTD_LIB_DEPRECATED=0" "-DXXH_PRIVATE_API=" "-DZSTDLIB_VISIBILITY=" "-DZDICTLIB_VISIBILITY=" "-DZSTDERRORLIB_VISIBILITY=" "-DZSTD_LEGACY_SUPPORT=1" "-o" "D:\code\rust\minigrep\target\debug\build\zstd-sys-4cb1700b66fb53b7\out\zstd/lib/common\entropy_common.o" "-c" "zstd/lib/common\entropy_common.c" with args "gcc.exe" did not execute successfully (status code exit code: 1).
For context: this seems to happen when building the rust binding for zstd. The building process starts by building the zstd C library itself, which apparently in this case causes a GCC internal compiler error.
I've seen it before in CI when using old versions of gcc. You could try updating gcc, it's possible the bug was already fixed.
What version of gcc is this? I'd second updating your gcc version
Unfortunately, upgrading gcc
did not solve this issue for me:
$ gcc --version
gcc-12 (Homebrew GCC 12.2.0) 12.2.0
Same for me.
Are you still having these issues?
This is definitely a compiler bug, but if you can figure out a workaround in the C code that is failing, and is otherwise a no-op, we'd likely merge it.
Not anymore. But I don't remember how I fixed it. Probably download something different.
@js-writer I am facing the same bug , do u know a solution ?