aconfig: create flag info file at build time

Previously flag info file is created at run time rather than at build
time due to two reasons:
1, it saves some storage space on each container
2, initially the flag info file does not container any flag non run time
info, so creating this file at run time on device is more efficient.

However, flag info file is fairly compact, 1 byte per flag. So the
storage footprint increase is minimal. Also, now flag info file contains
flag information known at the build time such as if the flag is read
write. To help create flag info file at run time, we actually have to
keep additional information on flag map file. Then use this information
to create flag info file at run time. Now it is more efficient to just
create flag info file at build time.

In addition, to create flag info file at run time, we need to maintain
an additional write api create_flag_info_file. Each time flag file
version changes, we have to keep the old version of this API as well. If
we create flag info file at build time, then we don't have to maintain
this API.

Overall the benefits outweight the 1 byte per flag storage overhead.
Therefore making this change to create flag info file at build time.

Bug: b/301491148
Test: m
Change-Id: I33993a438bbaf8697214655288ced30817b9592e
4 files changed
tree: 0c75912655bfca3509ebf327c394a62bcff79969
  1. ci/
  2. common/
  3. core/
  4. packaging/
  5. target/
  6. teams/
  7. tests/
  8. tools/
  9. .gitignore
  10. Android.bp
  11. banchanHelp.sh
  12. buildspec.mk.default
  13. Changes.md
  14. CleanSpec.mk
  15. cogsetup.sh
  16. Deprecation.md
  17. envsetup.sh
  18. help.sh
  19. navbar.md
  20. OWNERS
  21. PREUPLOAD.cfg
  22. rbesetup.sh
  23. README.md
  24. shell_utils.sh
  25. tapasHelp.sh
  26. Usage.txt
README.md

Android Make Build System

This is the Makefile-based portion of the Android Build System.

For documentation on how to run a build, see Usage.txt

For a list of behavioral changes useful for Android.mk writers see Changes.md

For an outdated reference on Android.mk files, see build-system.html. Our Android.mk files look similar, but are entirely different from the Android.mk files used by the NDK build system. When searching for documentation elsewhere, ensure that it is for the platform build system -- most are not.

This Makefile-based system is in the process of being replaced with Soong, a new build system written in Go. During the transition, all of these makefiles are read by Kati, and generate a ninja file instead of being executed directly. That's combined with a ninja file read by Soong so that the build graph of the two systems can be combined and run as one.