Qiita Teams that are logged in
You are not logged in to any team

Log in to Qiita Team
Community
OrganizationAdvent CalendarQiitadon (β)
Service
Qiita JobsQiita ZineQiita Blog
4
Help us understand the problem. What is going on with this article?
@k-yamada-github

CUI環境でAndroid Emulatorを起動する

More than 3 years have passed since last update.

やること

  • Ubuntu Server(16.04.1 LTS)上で、Android API 21(Android 5.0)のemulatorを起動する

前提条件

  • Android SDKをインストールしていること

手順

  • ABIをインストールする
# ABI名を調べる
$ android list sdk --extended --no-ui --all | grep abi
...
id: 97 or "sys-img-armeabi-v7a-android-21"
id: 100 or "sys-img-armeabi-v7a-google_apis-21"

# ABIをインストールする
$ echo "y" | android update sdk -a --no-ui --filter sys-img-armeabi-v7a-android-21
  • AVDを作る
$ echo n | android create avd --force --name emulator-android-21 --target android-21 -c 50M -s WXGA800 --abi armeabi-v7a
  • エミュレータを実行する
$ emulator -avd emulator-android-21 -no-skin -no-audio -no-window
  • adbで動作確認する
$ adb devices
List of devices attached
emulator-5554   offline

# device状態になるまで1分ぐらいかかる
$ adb devices
List of devices attached
emulator-5554   device

$ adb shell
root@generic:/ #

参考

4
Help us understand the problem. What is going on with this article?
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
k-yamada-github
Kotlin, Swift, Android, iOS, Vue.js, AWS
sonix
Mobility Tech Company「世界」をリードするイノベータ集団でありたい

Comments

No comments
Sign up for free and join this conversation.
Sign Up
If you already have a Qiita account Login
4
Help us understand the problem. What is going on with this article?