inherit rust CARGO = "cargo" # Cargo only supports in-tree builds at the moment B = "${S}" EXTRA_OECARGO_PATHS ??= "" oe_cargo_config () { mkdir -p .cargo # FIXME: we currently blow away the entire config because duplicate # sections are treated as a parse error by cargo (causing the entire # config to be silently ignored. # NOTE: we cannot pass more flags via this interface, the 'linker' is # assumed to be a path to a binary. If flags are needed, a wrapper must # be used. echo "paths = [" >.cargo/config for p in ${EXTRA_OECARGO_PATHS}; do printf "\"%s\" " "$p" done | sed -e 's/[ \n]+/,/g' -e 's/,$//' >>.cargo/config echo "]" >>.cargo/config } rust_cargo_patch () { cd "${S}" cat >>Cargo.toml <