當前位置:首頁 » 安卓系統 » 編譯androidx86

編譯androidx86

發布時間: 2025-03-15 16:19:01

㈠ 如何編譯android x86模擬器

首先你需要設置一下emulator工具的目錄之類的,這個不細說了,
要在.bashrc中新增環境變數,如下
ANDROID_PRODUCT_OUT=~/android/out/target/proct/generic
ANDROID_PRODUCT_OUT_BIN=~/android/out/host/linux-x86/bin
這里是設置你的輸出文件的位置和bin工具目錄,不用多解釋吧?
然後在命令行輸入:
export PATH=${PATH}:${ANDROID_PRODUCT_OUT_BIN}:${ANDROID_PRODUCT_OUT};
上面是導入了相關的配置,然後使之生效。
source ~/.bashrc
接著切換到輸出的system文件夾
cd ~/android/out/target/proct/generic
然後來創建模擬器
emulator -system system.img -data userdata.img -ramdisk ramdisk.img
如果你運氣夠好的話,也許現在已經在運行了,不過我運氣明顯不夠好。
提示一:
emulator: ERROR: You did not specify a virtual device name, and the system
directory could not be found.
If you are an Android SDK user, please use 『@』 or 『-avd 』
to start a given virtual device (see -help-avd for details).
Otherwise, follow the instructions in -help-disk-images to start the emulator

既然人家提示了,那就按照步驟走吧,輸入命令:
emulator -help-avd
接著提示如下:
use 『-avd 』 to start the emulator program with a given Android
Virtual Device (a.k.a. AVD), where must correspond to the name
of one of the existing AVDs available on your host machine.
See -help-virtual-device to learn how to create/list/manage AVDs.
As a special convenience, using 『@』 is equivalent to using
『-avd 』.
跟著提示繼續走,輸入命令:
emulator -help-virtual-device
又是提示了:
An Android Virtual Device (AVD) models a single virtual
device running the Android platform that has, at least, its own
kernel, system image and data partition.
Only one emulator process can run a given AVD at a time, but
you can create several AVDs and run them concurrently.
You can invoke a given AVD at startup using either 『-avd 』
or 『@』, both forms being equivalent. For example, to launch
the AVD named 『foo』, type:
emulator @foo
The 『android』 helper tool can be used to manage virtual devices.
For example:
android create avd -n -t 1 # creates a new virtual device.
android list avd # list all virtual devices available.
Try 『android –help』 for more commands.
Each AVD really corresponds to a content directory which stores
persistent and writable disk images as well as configuration files.
Each AVD must be created against an existing SDK platform or add-on.
For more information on this topic, see -help-sdk-images.

熱點內容
php傳輸 發布:2025-07-11 10:25:40 瀏覽:239
計演算法框圖 發布:2025-07-11 10:08:32 瀏覽:549
電容觸摸安卓一體機市場前景如何 發布:2025-07-11 10:08:27 瀏覽:840
c程序的編譯單位是 發布:2025-07-11 10:07:42 瀏覽:901
怎麼看網站的伺服器 發布:2025-07-11 10:03:16 瀏覽:604
紅米手機wlan輸入密碼在哪裡 發布:2025-07-11 10:02:32 瀏覽:433
懶人學編程 發布:2025-07-11 09:44:58 瀏覽:333
android命令行簽名 發布:2025-07-11 09:44:15 瀏覽:881
應用密碼怎麼取消密碼 發布:2025-07-11 09:28:33 瀏覽:797
pythonubuntumysql 發布:2025-07-11 09:23:47 瀏覽:531