#Tauri Mobile

38 messages · Page 1 of 1 (latest)

vapid canyon
#

Hello ya'll i am loving Tauri, huge boost to my development. I am working on a desktop app - which runs great.

I decided to try my hand at the new tauri mobile development system.

I am stuck at trying to run the dev server.

So, i run this command yarn tauri android dev [--open]

However, i get some issues.

First error on the VSCode side:

Info detected host target triple "x86_64-pc-windows-gnu"
Error Could not find an Android Emulator matching [--open]
Info Opening Android Studio
Info Accepting new connection 1/100
Info Accepting new connection 1/100
Error WS transport error: i/o error: An established connection was aborted by the software in your host machine. (os error 10053); terminate connection: 1

Seconds error on the android studio side: Cannot build selected target ABI: arm64-v8a,armeabi-v7a,armeabi, supported ABIs are: x86

I've tried an ARM emulator, an x86 emulator, and i tried to run it on my phone. No luck no matter what i do - with the same error.

Note, the project itself builds fine, and works in desktop mode. I simply can't get the android version's dev server to work.

#

If i run yarn tauri android dev and select my phone as the device - i get the following error:

#
BUILD FAILED in 31s
error Command failed with exit code 4294967295.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
       Error Failed to assemble APK: Command "I:\\Projects\\Squable\\src-tauri\\gen\\android\\app\\gradlew.bat --project-dir I:\\Projects\\Squable\\src-tauri\\gen\\android\\app assembleArm64Debug --warn" didn't complete successfully, exiting with code 1.
error Command failed with exit code 1.
fervent belfry
#

interesting, so for whatever reason it's missing from the docs, but you need to run ```sh
rustup target add aarch64-linux-android armv7-linux-androideabi i686-linux-android x86_64-linux-android

vapid canyon
vapid canyon
#

nope, that didn't fix it

fervent belfry
#

that's when you try to run on your phone right? Can you try an emulator again?

vapid canyon
#

actually, i got it to work

#

i had to remove the .cargo and gen folders

#

and re-run yarn tauri android init

#

now it works perfect 🙂

fervent belfry
#

cool 🥳

vapid canyon
#

this is exciting!

#

Thanks, is there any docs on the android-level API's that are currently supported?

fervent belfry
#

nope

vapid canyon
#

alright, into the black abyss i go.

fervent belfry
#

buuut there aren't many either actually

vapid canyon
#

Thanks again.

vapid canyon
#

So no HAL access?

fervent belfry
#

ohhh i misread your message actually

vapid canyon
#

I figured it would still be in a very early alpha - i'll have to play around with it.

fervent belfry
#

i'm not the best one to answer questions about mobile support anyway. still didn't have time to try it out myself (other than the prereqs installation)

#

but i guess the good thing is that you have full access to the actual android project so you can polyfill everything that's missing 🤷

vapid canyon
#

I can't wait until i never have to open the android studio again though xD

#

so, running yarn tauri android dev now works great - but yarn tauri android dev [--open] does not work. The project builds, but the emulator never turns on. Just builds and then stops.

#

So, must be a bug?

#

Runs fine on my phone - emulators don't work

fervent belfry
#

it used to work

#

but yeah, it's the first/second alpha so i do believe that it's possible that it doesn't always work

#

like real phones, many reports that that doesn't work

vapid canyon
vapid canyon
vapid canyon
#

I've done some debugging and it seems the apk only accepts emulators with the ARM abi - but arms abi emulators won't run on my machine. For some reason. So, i am 90% sure the issue is on my end.