Skip to content

Add a script to update the forks of AOSP sources - #1818

Open
adelva1984 wants to merge 3 commits into
google:mainfrom
adelva1984:aosp-update-script
Open

adelva1984 wants to merge 3 commits into
google:mainfrom
adelva1984:aosp-update-script

Conversation

@adelva1984

@adelva1984 adelva1984 commented Nov 19, 2025 •

Copy link
Copy Markdown
Collaborator

Update and automate synchronization of the forked AOSP sources under base/cvd/.

Commits in this series

  1. Add patches for non-upstream changes
    Captures existing downstream Cuttlefish divergences from AOSP in numbered patch stacks for adb (0001-drop-fastdeploy.patch, 0002-drop-incremental-update.patch), fastboot (0001-restore-license-banner.patch, 0002-drop-libziparchive-dependency.patch, 0003-spell-string-view-the-absl-way.patch), and mkbootfs (0001-restore-license-banner.patch).

  2. Add a script to update the forks of AOSP sources
    Adds base/cvd/update_aosp_sources.sh to stage, prune, preserve (BUILD.bazel, patches/, and project-specific stubbed/generated headers), and re-apply patches from an AOSP checkout, with guards against accidentally running against an internal Android tree.

  3. Update AOSP sources to android-latest-release
    Runs update_aosp_sources.sh against ToT AOSP (android-latest-release) to update adb, fastboot, and fec, updates BUILD.bazel files for added/removed sources, refreshes adb/patches/0002-drop-incremental-update.patch, and adds patches for adb (0003-drop-adbmdns.patch, 0004-drop-socket-local-client-timeout.patch), fastboot (0004-use-pinned-libbase-and-liblp.patch), and fec (0001-define-stringify-locally.patch) to keep compatibility with the pinned @android_system_libbase and @android_system_core revisions.

Comment thread base/cvd/update_aosp_sources.sh Resolved
Comment thread base/cvd/update_aosp_sources.sh Resolved
@adelva1984
adelva1984 force-pushed the aosp-update-script branch 2 times, most recently from 3bf11ce to 101337f Compare November 20, 2025 23:25
For various code forked from AOSP, some changes have been made. Track
them in numbered patch stacks.
Various AOSP sources are fully copied and forked, and some are also
patched. Make updating these files easier.
Import updated adb, fastboot, and fec sources from ToT AOSP
(android-latest-release) using base/cvd/update_aosp_sources.sh:
- Update adb (adding client/adb_wifi.h, openscreen/mdns_service.{cpp,h},
  transport_mdns.h, usb_linux_netlink.{cpp,h}; removing old adb_wifi.h,
  mdns_service_info.{cpp,h}, incfs/util/map_ptr.h), refresh
  0002-drop-incremental-update.patch, and add patches to stub out the
  Rust adbmdns backend and socket_local_client_timeout.
- Update fastboot (adding h2h_workaround.{cpp,h}) and add
  0004-use-pinned-libbase-and-liblp.patch for compatibility with the
  pinned @android_system_libbase and @android_system_core revisions.
- Update fec and add 0001-define-stringify-locally.patch to define
  STRINGIFY locally without android-base/stringify.h.

Assisted-by: Jetski:gemini

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants