From ddf349f8e051ab48ce9bb011551daa6f54875bc0 Mon Sep 17 00:00:00 2001 From: Daniel Micay Date: Sun, 17 Jan 2021 17:36:02 -0500 Subject: [PATCH] update build guide examples --- static/build.html | 58 ++++++++++++++++++++++++++--------------------- 1 file changed, 32 insertions(+), 26 deletions(-) diff --git a/static/build.html b/static/build.html index a157b5a3..98e43fc1 100644 --- a/static/build.html +++ b/static/build.html @@ -420,9 +420,9 @@ git submodule update --init --recursive
source script/envsetup.sh
-

Select the desired build target (aosp_crosshatch is the Pixel 3 XL):

+

Select the desired build target (aosp_sunfish is the Pixel 4a):

-
choosecombo release aosp_crosshatch user
+
choosecombo release aosp_sunfish user

For a development build, you may want to replace user with userdebug in order to have better debugging support. Production builds @@ -560,11 +560,11 @@ mv vendor/android-prepare-vendor/DEVICE/BUILD_ID/vendor/google_devices/* vendor/

The encryption passphrase for all the keys generated for a device needs to match for compatibility with the GrapheneOS scripts.

-

To generate keys for crosshatch (you should use unique keys per device +

To generate keys for sunfish (you should use unique keys per device variant):

-
mkdir -p keys/crosshatch
-cd keys/crosshatch
+                    
mkdir -p keys/sunfish
+cd keys/sunfish
 ../../development/tools/make_key releasekey '/CN=GrapheneOS/'
 ../../development/tools/make_key platform '/CN=GrapheneOS/'
 ../../development/tools/make_key shared '/CN=GrapheneOS/'
@@ -579,7 +579,7 @@ cd ../..

Generate a signify key for signing factory images:

-
signify -G -n -p keys/crosshatch/factory.pub -s keys/crosshatch/factory.sec
+
signify -G -n -p keys/sunfish/factory.pub -s keys/sunfish/factory.sec

Remove the -n switch to set a passphrase. The signify tool doesn't provide a way to change the passphrase without generating a new key, so @@ -594,7 +594,7 @@ cd ../..

You can (re-)encrypt your signing keys using the encrypt_keys script, which will prompt for the old passphrase (if any) and new passphrase:

-
script/encrypt_keys.sh keys/crosshatch
+
script/encrypt_keys.sh keys/sunfish

The script/decrypt_keys.sh script can be used to remove encryption, which is not recommended. The script exists primarily for internal usage to decrypt @@ -636,10 +636,10 @@ cd ../..

Generate a signed release build with the release.sh script:

-
script/release.sh crosshatch
+
script/release.sh sunfish

The factory images and update package will be in - out/release-crosshatch-$BUILD_NUMBER. The update zip performs a full OS + out/release-sunfish-$BUILD_NUMBER. The update zip performs a full OS installation so it can be used to update from any previous version. More efficient incremental updates are used for official over-the-air GrapheneOS updates and can be generated by keeping around past signed target_files zips and generating @@ -682,28 +682,34 @@ cd ../.. delta updates by passing the device, source version build number and target version build number. For example:

-
script/generate_delta.sh crosshatch 2019.09.25.00 2019.10.07.21
+
script/generate_delta.sh sunfish 2020.12.12.03 2021.01.05.03

The script assumes that the releases are organized in the following directory structure:

releases
-├── 2019.09.25.00
-│   └── release-crosshatch-2019.09.25.00
-│       ├── crosshatch-factory-2019.09.25.00.zip
-│       ├── crosshatch-factory-2019.09.25.00.zip.sig
-│       ├── crosshatch-img-2019.09.25.00.zip
-│       ├── crosshatch-ota_update-2019.09.25.00.zip
-│       ├── crosshatch-target_files-2019.09.25.00.zip
-│       └── crosshatch-testing
-└── 2019.10.07.21
-    └── release-crosshatch-2019.10.07.21
-        ├── crosshatch-factory-2019.10.07.21.zip
-        ├── crosshatch-factory-2019.10.07.21.zip.sig
-        ├── crosshatch-img-2019.10.07.21.zip
-        ├── crosshatch-ota_update-2019.10.07.21.zip
-        ├── crosshatch-target_files-2019.10.07.21.zip
-        └── crosshatch-testing
+├── 2020.12.12.03 +│   └── release-sunfish-2020.12.12.03 +│   ├── otatools +│   ├── sunfish-beta +│   ├── sunfish-factory-2020.12.12.03.zip +│   ├── sunfish-factory-2020.12.12.03.zip.sig +│   ├── sunfish-img-2020.12.12.03.zip +│   ├── sunfish-ota_update-2020.12.12.03.zip +│   ├── sunfish-stable +│   ├── sunfish-target_files-2020.12.12.03.zip +│   └── sunfish-testing +└── 2021.01.05.03 + └── release-sunfish-2021.01.05.03 + ├── otatools + ├── sunfish-beta + ├── sunfish-factory-2021.01.05.03.zip + ├── sunfish-factory-2021.01.05.03.zip.sig + ├── sunfish-img-2021.01.05.03.zip + ├── sunfish-ota_update-2021.01.05.03.zip + ├── sunfish-stable + ├── sunfish-target_files-2021.01.05.03.zip + └── sunfish-testing

Incremental updates are uploaded alongside the update packages and update metadata on the static web server used as an update server. The update client will