Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to compile a native recipe #134

Closed
krsh opened this issue Nov 22, 2022 · 3 comments
Closed

Unable to compile a native recipe #134

krsh opened this issue Nov 22, 2022 · 3 comments

Comments

@krsh
Copy link

krsh commented Nov 22, 2022

When I compile a native application, I get this error:

ERROR: Nothing PROVIDES 'cargo-bin-native-x86_64' (but virtual:native:/home/test/meta-example/recipes-app/app/app.bb DEPENDS on or otherwise requires it)
ERROR: Required build target 'core-image-minimal' has no buildable providers.
Missing or unbuildable dependency chain was: ['core-image-minimal', 'app-native', 'cargo-bin-native-x86_64']

Other info:

Build Configuration:
BB_VERSION           = "2.0.0"
BUILD_SYS            = "x86_64-linux"
NATIVELSBSTRING      = "universal"
TARGET_SYS           = "aarch64-poky-linux"
MACHINE              = "qemuarm64"
DISTRO               = "poky"
DISTRO_VERSION       = "4.0.3"
TUNE_FEATURES        = "aarch64 armv8a crc cortexa57"
TARGET_FPU           = ""
meta                 
meta-poky            
meta-yocto-bsp       
meta-oe              
meta-rust-bin        = "<unknown>:<unknown>"
@samliddicott
Copy link

samliddicott commented Dec 1, 2022

I find that a -native recipe can be compiled simply by adding:

PROVIDES += "cargo-bin-native-${TARGET_ARCH}"

to recipes-devtools/rust/cargo-bin-cross.inc

I'm not sure it is the right fix, but it is a simple one.

EDIT: It doesn't work for non-x86 builds

Maybe these lines in cargo-bin-cross.inc:

inherit native
...
PN_class-native = "cargo-bin-native-${BUILD_ARCH}"

@mangodan2003
Copy link

I have a pull request open for a change we've been using for a while, it works for both x86 and arm (Raspberry pi) builds.
#178

@nastevens
Copy link
Member

Resolved by #178. Thanks @mangodan2003!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants