#Error when cargo tauri android dev

5 messages · Page 1 of 1 (latest)

potent river
#

Make sure all dependencies are set up properly, including the CLI version. And make sure you've ran tauri android init

stoic tide
#

Did you install the alpha version of the tauri cli?

merry sage
#

Have you got Android Studio installed?

#

This seems to be happening before that stage but it doesn't hurt to check the whole flow.

merry sage
#

You can get a bit more info with RUST_BACKTRACE=1 yarn tauri android dev but I would also recommend changing the call to tauri_build::build() in build.rs to the code block below. It should give more info if it's Tauri itself failing.

if let Err(e) = tauri_build::try_build(tauri_build::Attributes::default()) {
  let mut file_result = std::fs::File::create("build-log");
  match file_result {
    Ok(ref mut file) => {
      for e in e.chain() {
        if let Err(e) = std::io::Write::write_all(file, e.to_string().as_bytes()) {
          println!("write fail: {}", e);
        }
      }
    },
    Err(ref e) => {
      println!("create fail: {:?}", e);
    },
  }
}