rust-mobile/android-rs-glue

Does not work with cargo package renaming

icefoxen opened this issue · 2 comments

Such as this line: https://github.com/alexheretic/glyph-brush/blob/master/glyph-brush/Cargo.toml#L16

Reproduction:

mkdir foo
cd foo
cargo init
echo 'glyph_brush = "0.2"' >> Cargo.toml
cargo build

Output:

> docker run --rm -v "$(pwd):/root/src" -w /root/src tomaka/cargo-apk cargo apk build
Compiling android_native_app_glue.c
Compiling injected-glue
Compiling glue_obj
Compiling crate
warning: unused manifest key: package.edition
    Updating registry `https://github.com/rust-lang/crates.io-index`
    Updating registry `https://github.com/rust-lang/crates.io-index`
    Updating registry `https://github.com/rust-lang/crates.io-index`
error: no matching package named `full_rusttype` found (required by `glyph_brush`)
location searched: registry https://github.com/rust-lang/crates.io-index
version required: ^0.7
est31 commented

warning: unused manifest key: package.edition

This reads like too old cargo. I'd suggest using cargo-apk from git which has an updated version of cargo.

As mentioned by @est31, this has been resolved in the git version.

The current git now references a new docker image which is more up to date and will resolve the issue:
docker run --rm -v "$(pwd):/root/src" -w /root/src philipalldredge/cargo-apk cargo apk build

See #221.

Recommend closing if this resolves the issue.