我已经从https://www.android-x86.org/.它建造得很好。我想知道我是如何设置config
或.mk
的,这样我就可以编译或构建具有Android Automotive OS风格的Android。
有指针吗?
请参阅提供AOSP汽车模拟器配置的/device/generic/car/repository。
以下目标变体可用:
aosp_car_arm-userdebug
aosp_car_arm64-userdebug
aosp_car_x86-userdebug
aosp_car_x86_64-userdebug
我建议按照官方文档下载和构建AOSP:为Android开发设置。您可以选择汽车模拟器作为您的构建目标。
简而言之:
下载一些Android存储库。在Android 10的情况下,这可能是例如使用回购:
$ repo init -u https://android.googlesource.com/platform/manifest -b android-10.0.0_r14 $ repo sync
设置一个环境并选择与您的CPU架构匹配的汽车模拟器目标变体,例如
$ . build/envsetup.sh $ lunch aosp_car_x86-userdebug
构建目标:
$ make
成功构建后,从命令行运行模拟器:
$ emulator
注意:通常,出于开发目的,您希望运行带有一些附加选项的模拟器,例如
-selinux permissive
(未强制执行SELinux(或-writable-system
(可写系统映像(。有关更多详细信息,请参阅命令行文档中的启动模拟器。