-
Notifications
You must be signed in to change notification settings - Fork 422
Closed
Description
I have a simple GTK-based app that I'm attempting to cross-compile for the raspberry-pi, and while I see there have been similar issues raised, it's not clear to me what needs to be done to get this to work. This is the cross
command output...
% cross build --target armv7-unknown-linux-gnueabihf -v
+ "rustc" "--print" "sysroot"
+ "rustup" "toolchain" "list"
+ "rustup" "target" "list" "--toolchain" "stable-x86_64-unknown-linux-gnu"
+ "rustup" "component" "list" "--toolchain" "stable-x86_64-unknown-linux-gnu"
+ "/usr/bin/podman" "run" "--userns" "host" "-e" "PKG_CONFIG_LIBDIR" "-e" "PKG_CONFIG_ALLOW_CROSS=1" "--rm" "-e" "XARGO_HOME=/xargo" "-e" "CARGO_HOME=/cargo" "-e" "CARGO_TARGET_DIR=/target" "-e" "USER=ggt" "-e" "CROSS_RUNNER=" "-v" "/home/ggt/.xargo:/xargo:Z" "-v" "/home/ggt/.cargo:/cargo:Z" "-v" "/cargo/bin" "-v" "/home/ggt/src/rust/gtk_test:/project:Z" "-v" "/home/ggt/.rustup/toolchains/stable-x86_64-unknown-linux-gnu:/rust:Z,ro" "-v" "/home/ggt/src/rust/gtk_test/target:/target:Z" "-w" "/project" "-i" "-t" "rustembedded/cross:armv7-unknown-linux-gnueabihf-0.2.1" "sh" "-c" "PATH=$PATH:/rust/bin cargo build --target armv7-unknown-linux-gnueabihf -v"
Fresh unicode-xid v0.2.1
Fresh unicode-segmentation v1.7.1
Fresh pkg-config v0.3.19
Fresh version-compare v0.0.10
Fresh strum v0.18.0
Fresh version_check v0.9.3
Fresh futures-core v0.3.13
Fresh futures-sink v0.3.13
Fresh futures-task v0.3.13
Fresh pin-project-lite v0.2.6
Fresh slab v0.4.2
Fresh pin-utils v0.1.0
Fresh futures-io v0.3.13
Fresh either v1.6.1
Fresh once_cell v1.7.2
Fresh heck v0.3.2
Fresh futures-channel v0.3.13
Fresh itertools v0.9.0
Fresh proc-macro2 v1.0.24
Fresh serde v1.0.125
Fresh libc v0.2.91
Fresh proc-macro-hack v0.5.19
Fresh quote v1.0.9
Fresh toml v0.5.8
Fresh memchr v2.3.4
Fresh proc-macro-nested v0.1.7
Fresh anyhow v1.0.40
Fresh bitflags v1.2.1
Fresh syn v1.0.67
Fresh proc-macro-error-attr v1.0.4
Fresh proc-macro-crate v0.1.5
Fresh thiserror-impl v1.0.24
Fresh strum_macros v0.18.0
Fresh futures-macro v0.3.13
Fresh proc-macro-error v1.0.4
Fresh futures-util v0.3.13
Fresh glib-macros v0.10.1
Fresh thiserror v1.0.24
Fresh system-deps v1.3.2
Fresh futures-executor v0.3.13
Compiling futures v0.3.13
Compiling glib-sys v0.10.1
Running `/target/debug/build/glib-sys-33bebe2a7fba54b8/build-script-build`
Running `rustc --crate-name futures --edition=2018 /cargo/registry/src/mygithub.libinneed.workers.dev-1ecc6299db9ec823/futures-0.3.13/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C embed-bitcode=no -C debuginfo=2 --cfg 'feature="alloc"' --cfg 'feature="async-await"' --cfg 'feature="default"' --cfg 'feature="executor"' --cfg 'feature="futures-executor"' --cfg 'feature="std"' -C metadata=3423ecd045e1b5cd -C extra-filename=-3423ecd045e1b5cd --out-dir /target/armv7-unknown-linux-gnueabihf/debug/deps --target armv7-unknown-linux-gnueabihf -C linker=arm-linux-gnueabihf-gcc -L dependency=/target/armv7-unknown-linux-gnueabihf/debug/deps -L dependency=/target/debug/deps --extern futures_channel=/target/armv7-unknown-linux-gnueabihf/debug/deps/libfutures_channel-f189d41ff35a6c0b.rmeta --extern futures_core=/target/armv7-unknown-linux-gnueabihf/debug/deps/libfutures_core-3a885e5bd72985b1.rmeta --extern futures_executor=/target/armv7-unknown-linux-gnueabihf/debug/deps/libfutures_executor-cff4e2c6ba37b9a5.rmeta --extern futures_io=/target/armv7-unknown-linux-gnueabihf/debug/deps/libfutures_io-1eed0afce94baa81.rmeta --extern futures_sink=/target/armv7-unknown-linux-gnueabihf/debug/deps/libfutures_sink-7ac238c70ab37ef1.rmeta --extern futures_task=/target/armv7-unknown-linux-gnueabihf/debug/deps/libfutures_task-d83bd6dbf63addb2.rmeta --extern futures_util=/target/armv7-unknown-linux-gnueabihf/debug/deps/libfutures_util-e62ed39fdbd8d16f.rmeta --cap-lints allow`
error: failed to run custom build command for `glib-sys v0.10.1`
Caused by:
process didn't exit successfully: `/target/debug/build/glib-sys-33bebe2a7fba54b8/build-script-build` (exit code: 1)
--- stdout
cargo:rerun-if-env-changed=GLIB_2.0_NO_PKG_CONFIG
cargo:rerun-if-env-changed=PKG_CONFIG_ALLOW_CROSS_armv7-unknown-linux-gnueabihf
cargo:rerun-if-env-changed=PKG_CONFIG_ALLOW_CROSS_armv7_unknown_linux_gnueabihf
cargo:rerun-if-env-changed=TARGET_PKG_CONFIG_ALLOW_CROSS
cargo:rerun-if-env-changed=PKG_CONFIG_ALLOW_CROSS
cargo:rerun-if-env-changed=PKG_CONFIG
cargo:rerun-if-env-changed=GLIB_2.0_STATIC
cargo:rerun-if-env-changed=GLIB_2.0_DYNAMIC
cargo:rerun-if-env-changed=PKG_CONFIG_ALL_STATIC
cargo:rerun-if-env-changed=PKG_CONFIG_ALL_DYNAMIC
cargo:rerun-if-env-changed=PKG_CONFIG_PATH_armv7-unknown-linux-gnueabihf
cargo:rerun-if-env-changed=PKG_CONFIG_PATH_armv7_unknown_linux_gnueabihf
cargo:rerun-if-env-changed=TARGET_PKG_CONFIG_PATH
cargo:rerun-if-env-changed=PKG_CONFIG_PATH
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_armv7-unknown-linux-gnueabihf
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_armv7_unknown_linux_gnueabihf
cargo:rerun-if-env-changed=TARGET_PKG_CONFIG_LIBDIR
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_armv7-unknown-linux-gnueabihf
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_armv7_unknown_linux_gnueabihf
cargo:rerun-if-env-changed=TARGET_PKG_CONFIG_SYSROOT_DIR
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
--- stderr
`"pkg-config" "--libs" "--cflags" "glib-2.0" "glib-2.0 >= 2.44"` did not exit successfully: exit code: 1
--- stderr
Package glib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `glib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glib-2.0' found
Package glib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `glib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glib-2.0' found
warning: build failed, waiting for other jobs to finish...
error: build failed
Any help would be appreciated.
zoechi, zezic, ChriFo and art-den