Skip to content

Build failed for target x86_64-unknown-linux-musl #301

@yearsyan

Description

@yearsyan

cargo build --release --target x86_64-unknown-linux-musl

Compiling smartcols-sys v0.1.2
Compiling libmount-sys v0.1.1
Compiling uu_last v0.0.1 (/home/user/util-linux/src/uu/last)
Compiling uu_blockdev v0.0.1 (/home/user/util-linux/src/uu/blockdev)
Compiling uu_dmesg v0.0.1 (/home/user/util-linux/src/uu/dmesg)
Compiling uu_fsfreeze v0.0.1 (/home/user/util-linux/src/uu/fsfreeze)
error[E0433]: failed to resolve: could not find utmpx in uucore
--> src/uu/last/src/platform/unix.rs:13:13
|
13 | use uucore::utmpx::time::OffsetDateTime;
| ^^^^^ could not find utmpx in uucore
|
note: found an item that was configured out
--> /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/uucore-0.0.30/src/lib/lib.rs:98:26
|
98 | pub use crate::features::utmpx;
| ^^^^^
note: the item is gated here
--> /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/uucore-0.0.30/src/lib/lib.rs:89:1
|
89 | / #[cfg(all(
90 | | unix,
91 | | not(target_os = "android"),
92 | | not(target_os = "fuchsia"),
... |
96 | | feature = "utmpx"
97 | | ))]
| |___^

error[E0432]: unresolved import uucore::utmpx
--> src/uu/last/src/platform/unix.rs:14:13
|
14 | use uucore::utmpx::{time, Utmpx};
| ^^^^^ could not find utmpx in uucore
|
note: found an item that was configured out
--> /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/uucore-0.0.30/src/lib/lib.rs:98:26
|
98 | pub use crate::features::utmpx;
| ^^^^^
note: the item is gated here
--> /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/uucore-0.0.30/src/lib/lib.rs:89:1
|
89 | / #[cfg(all(
90 | | unix,
91 | | not(target_os = "android"),
92 | | not(target_os = "fuchsia"),
... |
96 | | feature = "utmpx"
97 | | ))]
| |___^

error[E0277]: the trait bound i32: From<u32> is not satisfied
--> src/uu/fsfreeze/src/fsfreeze.rs:33:55
|
33 | if unsafe { libc::ioctl(file.as_raw_fd(), op_code.into(), 0) } < 0 {
| ^^^^ the trait From<u32> is not implemented for i32
|
= help: the following other types implement trait From<T>:
i32 implements From<bool>
i32 implements From<i16>
i32 implements From<i8>
i32 implements From<nix::sys::socket::Backlog>
i32 implements From<nix::unistd::Pid>
i32 implements From<u16>
i32 implements From<u8>
= note: required for u32 to implement Into<i32>

error[E0433]: failed to resolve: could not find utmpx in uucore
--> src/uu/dmesg/src/time_formatter.rs:170:27
|
170 | for record in uucore::utmpx::Utmpx::iter_all_records() {
| ^^^^^ could not find utmpx in uucore
|
note: found an item that was configured out
--> /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/uucore-0.0.30/src/lib/lib.rs:98:26
|
98 | pub use crate::features::utmpx;
| ^^^^^
note: the item is gated here
--> /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/uucore-0.0.30/src/lib/lib.rs:89:1
|
89 | / #[cfg(all(
90 | | unix,
91 | | not(target_os = "android"),
92 | | not(target_os = "fuchsia"),
... |
96 | | feature = "utmpx"
97 | | ))]
| |___^

error[E0433]: failed to resolve: could not find utmpx in uucore
--> src/uu/dmesg/src/time_formatter.rs:171:44
|
171 | if record.record_type() == uucore::utmpx::BOOT_TIME {
| ^^^^^ could not find utmpx in uucore
|
note: found an item that was configured out
--> /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/uucore-0.0.30/src/lib/lib.rs:98:26
|
98 | pub use crate::features::utmpx;
| ^^^^^
note: the item is gated here
--> /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/uucore-0.0.30/src/lib/lib.rs:89:1
|
89 | / #[cfg(all(
90 | | unix,
91 | | not(target_os = "android"),
92 | | not(target_os = "fuchsia"),
... |
96 | | feature = "utmpx"
97 | | ))]
| |___^
help: consider importing this struct
|
6 + use crate::libc::utmpx;
|
help: if you import utmpx, refer to it directly
|
171 - if record.record_type() == uucore::utmpx::BOOT_TIME {
171 + if record.record_type() == utmpx::BOOT_TIME {
|

error[E0277]: the trait bound i32: From<u32> is not satisfied
--> src/uu/blockdev/src/blockdev.rs:202:60
|
202 | ...l_code.into(), input) < 0 {
| ^^^^ the trait From<u32> is not implemented for i32
|
= help: the following other types implement trait From<T>:
i32 implements From<bool>
i32 implements From<i16>
i32 implements From<i8>
i32 implements From<nix::sys::socket::Backlog>
i32 implements From<nix::unistd::Pid>
i32 implements From<u16>
i32 implements From<u8>
= note: required for u32 to implement Into<i32>

For more information about this error, try rustc --explain E0277.
error: could not compile uu_fsfreeze (lib) due to 1 previous error
warning: build failed, waiting for other jobs to finish...
error: failed to run custom build command for libmount-sys v0.1.1

Caused by:
process didn't exit successfully: /home/user/util-linux/target/release/build/libmount-sys-4146f3ae2dc8d19e/build-script-build (exit status: 101)
--- stdout
cargo:root=/home/user/util-linux/target/x86_64-unknown-linux-musl/release/build/libmount-sys-077a051538977eaa/out
cargo:rerun-if-env-changed=SYSROOT_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=SYSROOT_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_SYSROOT
cargo:rerun-if-env-changed=SYSROOT
cargo:rerun-if-env-changed=LIBMOUNT_STATIC_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=LIBMOUNT_STATIC_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_LIBMOUNT_STATIC
cargo:rerun-if-env-changed=LIBMOUNT_STATIC
cargo:rerun-if-env-changed=LIBMOUNT_PATH_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=LIBMOUNT_PATH_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_LIBMOUNT_PATH
cargo:rerun-if-env-changed=LIBMOUNT_PATH
cargo:rerun-if-env-changed=LIBMOUNT_INCLUDE_DIR_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=LIBMOUNT_INCLUDE_DIR_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_LIBMOUNT_INCLUDE_DIR
cargo:rerun-if-env-changed=LIBMOUNT_INCLUDE_DIR
cargo:rerun-if-env-changed=LIBMOUNT_LIB_DIR_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=LIBMOUNT_LIB_DIR_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_LIBMOUNT_LIB_DIR
cargo:rerun-if-env-changed=LIBMOUNT_LIB_DIR
cargo:rerun-if-env-changed=CC_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=CC_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_CC
cargo:rerun-if-env-changed=CC
cargo:rerun-if-env-changed=CFLAGS_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=CFLAGS_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_CFLAGS
cargo:rerun-if-env-changed=CFLAGS
OPT_LEVEL = Some(3)
OUT_DIR = Some(/home/user/util-linux/target/x86_64-unknown-linux-musl/release/build/libmount-sys-077a051538977eaa/out)
TARGET = Some(x86_64-unknown-linux-musl)
HOST = Some(x86_64-unknown-linux-gnu)
cargo:rerun-if-env-changed=CC_x86_64-unknown-linux-musl
CC_x86_64-unknown-linux-musl = None
cargo:rerun-if-env-changed=CC_x86_64_unknown_linux_musl
CC_x86_64_unknown_linux_musl = 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
PATH = Some(/home/user/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl)
cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT
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(fxsr,sse,sse2)
cargo:rerun-if-env-changed=CFLAGS
CFLAGS = None
cargo:rerun-if-env-changed=TARGET_CFLAGS
TARGET_CFLAGS = None
cargo:rerun-if-env-changed=CFLAGS_x86_64_unknown_linux_musl
CFLAGS_x86_64_unknown_linux_musl = None
cargo:rerun-if-env-changed=CFLAGS_x86_64-unknown-linux-musl
CFLAGS_x86_64-unknown-linux-musl = None
CARGO_ENCODED_RUSTFLAGS = Some()
OPT_LEVEL = Some(3)
OUT_DIR = Some(/home/user/util-linux/target/x86_64-unknown-linux-musl/release/build/libmount-sys-077a051538977eaa/out)
TARGET = Some(x86_64-unknown-linux-musl)
HOST = Some(x86_64-unknown-linux-gnu)
cargo:rerun-if-env-changed=CC_x86_64-unknown-linux-musl
CC_x86_64-unknown-linux-musl = None
cargo:rerun-if-env-changed=CC_x86_64_unknown_linux_musl
CC_x86_64_unknown_linux_musl = 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
PATH = Some(/home/user/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl)
cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT
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(fxsr,sse,sse2)
cargo:rerun-if-env-changed=CFLAGS
CFLAGS = None
cargo:rerun-if-env-changed=TARGET_CFLAGS
TARGET_CFLAGS = None
cargo:rerun-if-env-changed=CFLAGS_x86_64_unknown_linux_musl
CFLAGS_x86_64_unknown_linux_musl = None
cargo:rerun-if-env-changed=CFLAGS_x86_64-unknown-linux-musl
CFLAGS_x86_64-unknown-linux-musl = None
CARGO_ENCODED_RUSTFLAGS = Some()

--- stderr

thread 'main' panicked at /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/libmount-sys-0.1.1/build.rs:260:37:
libmount-sys: Failed to find 'libmount/libmount.h'. Please make sure the C header files of libmount are installed and accessible: Kind(NotFound)
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
error: failed to run custom build command for smartcols-sys v0.1.2

Caused by:
process didn't exit successfully: /home/user/util-linux/target/release/build/smartcols-sys-c01c93fc07ac1944/build-script-build (exit status: 101)
--- stdout
cargo:root=/home/user/util-linux/target/x86_64-unknown-linux-musl/release/build/smartcols-sys-ecc585ab5f6738d6/out
cargo:rerun-if-env-changed=SYSROOT_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=SYSROOT_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_SYSROOT
cargo:rerun-if-env-changed=SYSROOT
cargo:rerun-if-env-changed=SMARTCOLS_STATIC_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=SMARTCOLS_STATIC_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_SMARTCOLS_STATIC
cargo:rerun-if-env-changed=SMARTCOLS_STATIC
cargo:rerun-if-env-changed=SMARTCOLS_PATH_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=SMARTCOLS_PATH_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_SMARTCOLS_PATH
cargo:rerun-if-env-changed=SMARTCOLS_PATH
cargo:rerun-if-env-changed=SMARTCOLS_INCLUDE_DIR_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=SMARTCOLS_INCLUDE_DIR_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_SMARTCOLS_INCLUDE_DIR
cargo:rerun-if-env-changed=SMARTCOLS_INCLUDE_DIR
cargo:rerun-if-env-changed=SMARTCOLS_LIB_DIR_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=SMARTCOLS_LIB_DIR_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_SMARTCOLS_LIB_DIR
cargo:rerun-if-env-changed=SMARTCOLS_LIB_DIR
cargo:rerun-if-env-changed=CC_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=CC_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_CC
cargo:rerun-if-env-changed=CC
cargo:rerun-if-env-changed=CFLAGS_x86_64-unknown-linux-musl
cargo:rerun-if-env-changed=CFLAGS_x86_64_unknown_linux_musl
cargo:rerun-if-env-changed=TARGET_CFLAGS
cargo:rerun-if-env-changed=CFLAGS
OPT_LEVEL = Some(3)
OUT_DIR = Some(/home/user/util-linux/target/x86_64-unknown-linux-musl/release/build/smartcols-sys-ecc585ab5f6738d6/out)
TARGET = Some(x86_64-unknown-linux-musl)
HOST = Some(x86_64-unknown-linux-gnu)
cargo:rerun-if-env-changed=CC_x86_64-unknown-linux-musl
CC_x86_64-unknown-linux-musl = None
cargo:rerun-if-env-changed=CC_x86_64_unknown_linux_musl
CC_x86_64_unknown_linux_musl = 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
PATH = Some(/home/user/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl)
cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT
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(fxsr,sse,sse2)
cargo:rerun-if-env-changed=CFLAGS
CFLAGS = None
cargo:rerun-if-env-changed=TARGET_CFLAGS
TARGET_CFLAGS = None
cargo:rerun-if-env-changed=CFLAGS_x86_64_unknown_linux_musl
CFLAGS_x86_64_unknown_linux_musl = None
cargo:rerun-if-env-changed=CFLAGS_x86_64-unknown-linux-musl
CFLAGS_x86_64-unknown-linux-musl = None
CARGO_ENCODED_RUSTFLAGS = Some()
OPT_LEVEL = Some(3)
OUT_DIR = Some(/home/user/util-linux/target/x86_64-unknown-linux-musl/release/build/smartcols-sys-ecc585ab5f6738d6/out)
TARGET = Some(x86_64-unknown-linux-musl)
HOST = Some(x86_64-unknown-linux-gnu)
cargo:rerun-if-env-changed=CC_x86_64-unknown-linux-musl
CC_x86_64-unknown-linux-musl = None
cargo:rerun-if-env-changed=CC_x86_64_unknown_linux_musl
CC_x86_64_unknown_linux_musl = 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
PATH = Some(/home/user/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl)
cargo:rerun-if-env-changed=CC_ENABLE_DEBUG_OUTPUT
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(fxsr,sse,sse2)
cargo:rerun-if-env-changed=CFLAGS
CFLAGS = None
cargo:rerun-if-env-changed=TARGET_CFLAGS
TARGET_CFLAGS = None
cargo:rerun-if-env-changed=CFLAGS_x86_64_unknown_linux_musl
CFLAGS_x86_64_unknown_linux_musl = None
cargo:rerun-if-env-changed=CFLAGS_x86_64-unknown-linux-musl
CFLAGS_x86_64-unknown-linux-musl = None
CARGO_ENCODED_RUSTFLAGS = Some()

--- stderr

thread 'main' panicked at /home/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/smartcols-sys-0.1.2/build.rs:289:22:
smartcols-sys: Failed to find 'libsmartcols/libsmartcols.h'. Please make sure the C header files of libsmartcols are installed and accessible: Kind(NotFound)
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
Some errors have detailed explanations: E0432, E0433.
For more information about an error, try rustc --explain E0432.
error: could not compile uu_last (lib) due to 2 previous errors
error: could not compile uu_blockdev (lib) due to 1 previous error
For more information about this error, try rustc --explain E0433.
error: could not compile uu_dmesg (lib) due to 2 previous errors

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions