Differences between revisions 5 and 6
Revision 5 as of 2021-08-21 18:05:17
Size: 8302
Comment:
Revision 6 as of 2021-08-21 18:22:34
Size: 9322
Comment: Added links to commits and updated issue statuses.
Deletions are marked like this. Additions are marked like this.
Line 22: Line 22:
        [[https://salsa.debian.org/android-tools-team/admin/-/issues/40|Issue #40]] lists the old repositories that were adapted into the new [[https://salsa.debian.org/android-tools-team/android-platform-tools|android-platform-tools]] repository. Merged commits of interest:         [[https://salsa.debian.org/android-tools-team/admin/-/issues/40|Issue #40 (closed: Apr 28, 2021)]] lists the old repositories that were adapted into the new [[https://salsa.debian.org/android-tools-team/android-platform-tools|android-platform-tools]] repository. Merged commits of interest:
Line 27: Line 27:
        The phase 1 sources used the android-10.0.0_r36 tag. Starting with platform-tools-29.0.1, Google releases the sources that are used to create the Platform Tools zip that they distribute under platform-tools-* tags. As of April 28, 2021, the latest tag is platform-tools-31.0.1. In order to not have too many changes to the current makefiles, the upgrade to v31.0.x was done via an intermediate upgrade to v29.0.6, tracked in [[https://salsa.debian.org/android-tools-team/admin/-/issues/44|Issue #44]]. Merged commits of interest:         The phase 1 sources used the android-10.0.0_r36 tag. Starting with platform-tools-29.0.1, Google releases the sources that are used to create the Platform Tools zip that they distribute under platform-tools-* tags. As of April 28, 2021, the latest tag is platform-tools-31.0.1. In order to not have too many changes to the current makefiles, the upgrade to v31.0.x was done via an intermediate upgrade to v29.0.6, tracked in [[https://salsa.debian.org/android-tools-team/admin/-/issues/44|Issue #44 (closed: Jul 24, 2021)]]. Merged commits of interest:
Line 33: Line 33:
        Due to the intermediate update in phase 2, updating to v31.0.2 became as simple as changing the source lists to use the new source lists. [[https://salsa.debian.org/android-tools-team/admin/-/issues/47|Issue #47]] tracks the progress of phase 3. As of Aug 19, 2021, all target binaries compile with the updated sources, and cleanup work to include this work in the repository is in progress.         Due to the intermediate update in phase 2, updating to v31.0.2 became as simple as changing the source lists to use the new source lists. [[https://salsa.debian.org/android-tools-team/admin/-/issues/47|Issue #47 (open)]] tracks the progress of phase 3. As of Aug 19, 2021, all target binaries compile with the updated sources, and cleanup work to include this work in the repository is in progress.
Line 38: Line 38:
The packaging of Build Tools was done from the android-* tags since no dedicated tags are available to build the same tools as in the official zip releases of android-build-tools by Google. The [[https://salsa.debian.org/android-tools-team/android-build-tools|android-build-tools]] repository contains the GNU make based adaptation of the v10.0.0+r41 upstream sources. The packaging of Build Tools was done from the android-* tags since no dedicated tags are available to build the same tools as in the official zip releases of android-build-tools by Google. The [[https://salsa.debian.org/android-tools-team/android-build-tools|android-build-tools]] repository contains the GNU make based adaptation of the v10.0.0+r41 upstream sources. Phases of the work on this are:
 '''1. Import existing packages''':
        [[https://salsa.debian.org/android-tools-team/android-build-tools/-/commit/3eb196d3979ef7f9d9239101d1eb647b3ddcddf4|Import files for libselinux]]: Similar to phase 1 of Platform Tools, all existing individual repositories were adapted into a single repository for ease of updating the sources. [[https://salsa.debian.org/android-tools-team/admin/-/issues/42| Issue #42 (closed: Apr 30, 2021)]] tracked the progress of this phase.
 '''1. Remove unnecessary dependencies and upload final Debian packages''':
        Similar to phase 2 of Platform Tools, the library dependencies of Build Tools will be made to use statically linked versions of those libraries created during the build in order to make future updates to sources easy to incorporate into the Debian repository. [[https://salsa.debian.org/android-tools-team/admin/-/issues/45| Issue #45 (open)]] tracks the progress on this.

Google Summer of Code 2021

This page serves as a description of the work done by me during the 3 months of Google Summer of Code 2021 under the project, Android SDK Tools in Debian.

Packaging of these tools involved setting up a GNU make based build system to compile the upstream sources, the commits for which are available under the following repositories at salsa.debian.org.

Overall, the main achievements during this period were:

  • Combined individual repositories related to Android Platform Tools into a single repository.
  • Updated upstream sources from the former android-* tags to the new platform-tools-* tags.

Git Repositories


Platform Tools

The packaging of Platform Tools expanded on the work done by former GSoC students and Debian maintainers in 3 phases:

  • 1. Consolidation of all existing android-platform-tools repositories into one:

    2. Updating upstream sources from android-* tags to dedicated platform-tools-* tags:

    • The phase 1 sources used the android-10.0.0_r36 tag. Starting with platform-tools-29.0.1, Google releases the sources that are used to create the Platform Tools zip that they distribute under platform-tools-* tags. As of April 28, 2021, the latest tag is platform-tools-31.0.1. In order to not have too many changes to the current makefiles, the upgrade to v31.0.x was done via an intermediate upgrade to v29.0.6, tracked in Issue #44 (closed: Jul 24, 2021). Merged commits of interest:

      • Update patches for platform-tools-29.0.6: Since the existing patches no longer cleanly apply on top of the updated sources, the affected patch files had to be recreated.

      • Update art/libart.mk sources for platform-tools-29.0.6: This and many similar commits updated the source lists in the individual makefiles to use the updated sources.

      • Static link libs in `art`: First of 11 such commits. Since the libraries created during the build process to build the binaries, that are shipped in Google's official Platform Tools zip releases, are not required by any other Debian packages, it was decided that these library-only Debian packages would no longer be created in favor of statically linking them with the final binaries. While working on this, I also restructured all the makefiles to compile all objects separately using build rule patterns. This allowed for better utilization of parallel threads for compilation, bringing down the CI build time from 10 minutes to 4 minutes.

      • Apply minor housekeeping: This, and some similar commits, removed unnecessary source files and non-source files from the imported upstream sources, removed obsolete glob patterns in files used by the build system, added missing descriptions to patch files, and removed all remaining unnecessary dependencies of the build.

    3. Updating upstream sources from v29.0.6 to v31.0.2:

    • Due to the intermediate update in phase 2, updating to v31.0.2 became as simple as changing the source lists to use the new source lists. Issue #47 (open) tracks the progress of phase 3. As of Aug 19, 2021, all target binaries compile with the updated sources, and cleanup work to include this work in the repository is in progress.


Build Tools

The packaging of Build Tools was done from the android-* tags since no dedicated tags are available to build the same tools as in the official zip releases of android-build-tools by Google. The android-build-tools repository contains the GNU make based adaptation of the v10.0.0+r41 upstream sources. Phases of the work on this are:

  • 1. Import existing packages:

    1. Remove unnecessary dependencies and upload final Debian packages:

    • Similar to phase 2 of Platform Tools, the library dependencies of Build Tools will be made to use statically linked versions of those libraries created during the build in order to make future updates to sources easy to incorporate into the Debian repository. Issue #45 (open) tracks the progress on this.


Having the latest Android SDK tools available in the Debian repositories means that users can use these tools by installing them via apt, rather than having to install the zip releases from Google into non-standard and hard to maintain and update locations.
All the work that I did to accomplish this was done under the guidance and instruction of my mentors, Hans-Christoph Steiner, Chirayu Desai, Andrej Shadura, and Phil Morrell.