2025 年 3 月 27 日より、AOSP のビルドとコントリビューションには aosp-main
ではなく android-latest-release
を使用することをおすすめします。詳細については、AOSP の変更をご覧ください。
Cuttlefish ハイブリッド デバイスを作成する
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
このページでは、Cuttlefish ハイブリッド デバイス(CHD)を作成する方法について説明します。
CHD は、デバイスの HAL の Cuttlefish システム イメージの代わりに実機のシステム イメージを実行する、ハイブリッドの Cuttlefish 仮想デバイスです。これには次のような利点があります。
CHD を作成する方法は次のとおりです。
make dist
を使用して、Cuttlefish デバイスと実機のターゲット ファイルを生成します。
この 2 つのターゲット ファイルを組み合わせて CHD のターゲット ファイルにして、以下のように build_cf_hybrid_device.py
スクリプトを実行することで、CHD のターゲット ファイルから CHD イメージを生成します。
python3 tools/treble/cuttlefish/build_cf_hybrid_device.py \
--framework_target_files_zip <physical_device_target_files.zip> \
--vendor_target_files_zip <cuttlefish_device_target_files.zip> \
--otatools_zip <cuttlefish_otatools.zip> \
--target chd \
--output_dir <output_directory>
このスクリプトでは、merge_target_files.py
を使用して 2 つのターゲット ファイルを CHD のターゲット ファイルにして、img_from_target_files
を使用して CHD のターゲット ファイルから CHD イメージを生成します。
このページのコンテンツやコードサンプルは、コンテンツ ライセンスに記載のライセンスに従います。Java および OpenJDK は Oracle および関連会社の商標または登録商標です。
最終更新日 2025-03-26 UTC。
[[["わかりやすい","easyToUnderstand","thumb-up"],["問題の解決に役立った","solvedMyProblem","thumb-up"],["その他","otherUp","thumb-up"]],[["必要な情報がない","missingTheInformationINeed","thumb-down"],["複雑すぎる / 手順が多すぎる","tooComplicatedTooManySteps","thumb-down"],["最新ではない","outOfDate","thumb-down"],["翻訳に関する問題","translationIssue","thumb-down"],["サンプル / コードに問題がある","samplesCodeIssue","thumb-down"],["その他","otherDown","thumb-down"]],["最終更新日 2025-03-26 UTC。"],[],[],null,["# Create a Cuttlefish hybrid device\n\nThis page describes how to create a Cuttlefish hybrid device (CHD).\n\nA CHD is a hybrid virtual Cuttlefish device, which runs a physical device's\nsystem image instead of a Cuttlefish system image on the device's HALs. This\noffers the following advantages:\n\n- **Early development and testing:** CHDs allow for early development and\n testing of next-generation system software before the physical hardware is\n available.\n\n- **Scalability:** CHDs facilitate easier expansion of development and\n testing capacity.\n\nTo create a CHD, do the following:\n\n1. Generate the target files for the Cuttlefish device and the physical device\n using `make dist`.\n\n2. Combine the two target files into a CHD target file and generate the CHD\n images from the CHD target file by running the\n [`build_cf_hybrid_device.py`](https://cs.android.com/android/platform/superproject/+/android-latest-release:tools/treble/cuttlefish/build_cf_hybrid_device.py)\n script:\n\n python3 tools/treble/cuttlefish/build_cf_hybrid_device.py \\\n --framework_target_files_zip \u003cphysical_device_target_files.zip\u003e \\\n --vendor_target_files_zip \u003ccuttlefish_device_target_files.zip\u003e \\\n --otatools_zip \u003ccuttlefish_otatools.zip\u003e \\\n --target chd \\\n --output_dir \u003coutput_directory\u003e\n\n This script combines the two target files into a CHD target file using\n [`merge_target_files.py`](https://cs.android.com/android/platform/superproject/+/android-latest-release:build/make/tools/releasetools/merge/merge_target_files.py)\n and generates the CHD images from the CHD target file using\n [`img_from_target_files`](https://cs.android.com/android/platform/superproject/+/android-latest-release:build/make/tools/releasetools/img_from_target_files.py)."]]