ubercas.blogg.se

Android studio ubuntu 18.04
Android studio ubuntu 18.04












Start the emulator with the custom kernel and the custom device emulator -writable-system -no-snapshot -show-kernel -verbose -kernel arch/x86/boot/bzImage -qemu -usb -device usb-host,vendorid=0x1546 # Unplug and replug your device before continuing # We add an udev rule to configure group for our deviceĮcho 'SUBSYSTEM="usb", ATTRS="000b", GROUP="kvm"' | sudo tee /etc/udev/rules.d/les # We know our VendorId is 1546 and productId 000b # Find the VendorId and ProductId of your usb device # If you are not in the kvm group you can add yourself in it by doing # As you use android emulator, I suppose your user is in the `kvm` group. Permission to access the device # First you need to add an udev rule to allow your user to access the usb device # Please edit the line of the path if you cloned x86_64-linux-android-4.9 somewhere elseĮxport CROSS_COMPILE=x86_64-linux-android-Įxport PATH=$PATH:$(pwd)/./x86_64-linux-android-4.9/bin # We need to add some variables to our env # Note: Press space to enable it until you have a starīuild it # Ensure you are at the root of the goldfish directory # Device Drivers > USB Support > USB Modem (CDC ACM) support # In our case we wanted to enable USB ACM devices, so I enabled # Open the menu to edit the configuration Git checkout f41f5aa46e3076e17e5f1eea5b0a879e3a383ac4Ĭonfigure it # Generate default configuration # I choosed the one that was just before the build date (commit named 4.4.124 didn't work) # To show the list of commits in this branch

android studio ubuntu 18.04

# I choosed `android-goldfish-4.4-dev` because we are on linux 4.4 # We have to choose the branch in the list found here # Goldfish is the name of the kernel for android emulator

android studio ubuntu 18.04

# Then we need to clone the kernel sources

android studio ubuntu 18.04

# I choose the most recent that matched my android version # You can go here to see the list of versions: # I've took the most recent version of x86_64-linux-android gcc prebuilt We will use those informations later Get sources and move to the right commit # First we need to get prebuilt of gcc toolchain for x86_64 arch Start the emulator without modifications, go intoĬonfiguration > System > About emulated device > Android version My goal was to build the same version as it was before, but with just configuration modifications. So we need to build it with another configuration. The android emulator doesn't support all usb devices because they are disabled in the kernel. Use custom USB device with Android emulator by using custom built kernel on Ubuntu 18.04














Android studio ubuntu 18.04