OS: macOS 11.0.1
rustc: 1.48.0-nightly (dbb73f8f7 2020-09-12)
Happens when trying to use the rodio
crate.
Attempt 1
error: failed to run custom build command for `minimp3-sys v0.3.2`
Caused by:
process didn't exit successfully: `<project path>/target/debug/build/minimp3-sys-1d780ec51db6778d/build-script-build` (exit code: 1)
--- stdout
TARGET = Some("x86_64-apple-darwin")
OPT_LEVEL = Some("0")
HOST = Some("x86_64-apple-darwin")
CC_x86_64-apple-darwin = None
CC_x86_64_apple_darwin = None
HOST_CC = None
CC = Some("/usr/local/Cellar/gcc/9.2.0_3/bin/gcc-9")
CFLAGS_x86_64-apple-darwin = None
CFLAGS_x86_64_apple_darwin = None
HOST_CFLAGS = None
CFLAGS = None
CRATE_CC_NO_DEFAULTS = None
DEBUG = Some("true")
CARGO_CFG_TARGET_FEATURE = Some("cmpxchg16b,fxsr,mmx,sse,sse2,sse3,ssse3")
running: "/usr/local/Cellar/gcc/9.2.0_3/bin/gcc-9" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-fno-omit-frame-pointer" "-m64" "-arch" "x86_64" "-I" "minimp3/" "-Wall" "-Wextra" "-DMINIMP3_IMPLEMENTATION" "-o" "<project path>/target/debug/build/minimp3-sys-1a06bf2a4367be65/out/minimp3.o" "-c" "minimp3.c"
--- stderr
error occurred: Failed to find tool. Is `gcc-9` installed?
I've installed gcc@9
using brew, created a directory /usr/local/Cellar/gcc/9.2.0_3/
and linked the bin/
folder from the installed version there. I did it because the script was looking for this specific version of gcc despite it not being installed. I'm pretty sure it's not the proper way to do it but I didn't know how else to make minimp3-sys
build script look for a default version of gcc (under gcc
alias) without making a custom version of the minimp3-sys
crate with a modified build script. Anyway, that error went away but there was another one now.
Attempt 2
Compiling minimp3-sys v0.3.2
The following warnings were emitted during compilation:
warning: In file included from /usr/local/Cellar/gcc@9/9.3.0/lib/gcc/9/gcc/x86_64-apple-darwin20/9.3.0/include/stdint.h:9,
warning: from minimp3/minimp3.h:9,
warning: from minimp3.c:1:
warning: /usr/local/Cellar/gcc@9/9.3.0/lib/gcc/9/gcc/x86_64-apple-darwin20/9.3.0/include-fixed/stdint.h:27:10: fatal error: sys/_types/_int8_t.h: No such file or directory
warning: 27 | #include <sys/_types/_int8_t.h>
warning: | ^~~~~~~~~~~~~~~~~~~~~~
warning: compilation terminated.
error: failed to run custom build command for `minimp3-sys v0.3.2`
Caused by:
process didn't exit successfully: `<project path>/target/debug/build/minimp3-sys-1d780ec51db6778d/build-script-build` (exit code: 1)
--- stdout
TARGET = Some("x86_64-apple-darwin")
OPT_LEVEL = Some("0")
HOST = Some("x86_64-apple-darwin")
CC_x86_64-apple-darwin = None
CC_x86_64_apple_darwin = None
HOST_CC = None
CC = Some("/usr/local/Cellar/gcc/9.2.0_3/bin/gcc-9")
CFLAGS_x86_64-apple-darwin = None
CFLAGS_x86_64_apple_darwin = None
HOST_CFLAGS = None
CFLAGS = None
CRATE_CC_NO_DEFAULTS = None
DEBUG = Some("true")
CARGO_CFG_TARGET_FEATURE = Some("cmpxchg16b,fxsr,mmx,sse,sse2,sse3,ssse3")
running: "/usr/local/Cellar/gcc/9.2.0_3/bin/gcc-9" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-fno-omit-frame-pointer" "-m64" "-arch" "x86_64" "-I" "minimp3/" "-Wall" "-Wextra" "-DMINIMP3_IMPLEMENTATION" "-o" "<project path>/target/debug/build/minimp3-sys-1a06bf2a4367be65/out/minimp3.o" "-c" "minimp3.c"
cargo:warning=In file included from /usr/local/Cellar/gcc@9/9.3.0/lib/gcc/9/gcc/x86_64-apple-darwin20/9.3.0/include/stdint.h:9,
cargo:warning= from minimp3/minimp3.h:9,
cargo:warning= from minimp3.c:1:
cargo:warning=/usr/local/Cellar/gcc@9/9.3.0/lib/gcc/9/gcc/x86_64-apple-darwin20/9.3.0/include-fixed/stdint.h:27:10: fatal error: sys/_types/_int8_t.h: No such file or directory
cargo:warning= 27 | #include <sys/_types/_int8_t.h>
cargo:warning= | ^~~~~~~~~~~~~~~~~~~~~~
cargo:warning=compilation terminated.
exit code: 1
--- stderr
error occurred: Command "/usr/local/Cellar/gcc/9.2.0_3/bin/gcc-9" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-fno-omit-frame-pointer" "-m64" "-arch" "x86_64" "-I" "minimp3/" "-Wall" "-Wextra" "-DMINIMP3_IMPLEMENTATION" "-o" "<project path>/target/debug/build/minimp3-sys-1a06bf2a4367be65/out/minimp3.o" "-c" "minimp3.c" with args "gcc-9" did not execute successfully (status code exit code: 1).