If the default value for RELEASE_ACONFIG_VALUE_SETS is not a string,
the resulting value is the empty string.
Bug: 328495189
Test: manual
Change-Id: Ie8f262d6408b1564ec7a3918f8654ccfa9bc5940
When writing all makefiles, we also need to write the makefile for
${TARGET_RELEASE}. We can skip writing it a second time if it is not
an alias.
Bug: 328495189
Test: manual, TH
Change-Id: Ia5d1955f419312c76eb9c8a33b1c8a6bcc5efe0b
The default directory for flag values is the last of:
- Where the flag is declared,
- Where the release config is first declared,
- Where the flag value is currently being set for this release config.
Bug: 328495189
Test: manual
Change-Id: Ida1f906b75704f658e7fa1de703e0c789dce06a6
When the passed release name is an alias, write
release_config-PRODUCT-RELEASE.mk using the alias, since that is where
core/release_config.mk is going to look for it.
Bug: 328495189
Test: manual
Change-Id: I4e6909f43bf136974323754e06fa538e39e0faab
Disallow setting the flag via protobuf files, and adjust it internally
to be more like any other build flag. This makes the generated output
more consistent.
Also default to TARGET_RELEASE if no release is given to `build-flag`.
Bug: 328495189
Test: manual
Change-Id: I9db57137fc4e5ed42a38adc939c430826afe4f63
If false, then we output an empty file, which will cause
release_config.mk to do the old process.
Bug: 328495189
Test: manual
Change-Id: I4aa82301f3bbb29633a275a801431a6667feb48d
- Allow scl and textproto data to coexist for now
- Print warnings to stderr instead of stdout.
- Improve formatting of output
- Set displays the new value for all configs, and what file changed.
- Use prettier error messages for better UX
- put build-flag on the path.
Bug: 328495189
Test: manual
Change-Id: I4c38860c2fb24db5111e0cecf790660a4ff2b8b2
Release configs with `aconfig_flags_only: true` can inherit build flag
values, but cannot set them.
Bug: 328495189
Test: manual
Change-Id: I2bdc88761d61fb20f10dc734f2ba87114f51b859
- Automatically determine the top of the workspace.
- build-flag defaults to using `get_build_var` to get product specific
release config maps.
- release-config defaults to using PRODUCT_RELEASE_CONFIG_MAPS but does
not use `get_build_var` unless the argument is given.
Bug: 328495189
Test: manual
Change-Id: I4ba3c5dfab43c4ebc3eeda13318f42e886dada4e
- Parse release_config_map.textproto files only once
- Fix inheritance
- Sort flag artifacts by flag name
- Add --all_make option for testing
- Fix value() parsing in crunch_flags
Bug: 328495189
Test: manual
Change-Id: I577e7fb07171bea9a53d61eaf77ec728b60d7a26
When set, this removes all traces of the flag from the release config.
Bug: 328495189
Test: manual
Change-Id: Iab39d06e134bfc020ba4875c1b8e89c5cdf18924
- crunch-flags automates converting build flags from starlark to protobuf.
- build-flag is used to set, get and trace flag values.
Bug: 328495189
Test: manual
Change-Id: I941a4420a8bdfa2df73d94e52b3f34a6d1ea3278
- Allow each of the formats (json, pb, textproto) to be individually
controlled.
- Include product and release in the name of the aritfact.
Bug: 328495189
Test: manual
Change-Id: Ia08e7224200a48994bea882a61b8199d53576d38
This will allow the `build-flag` command to use release_config_lib code.
Bug: 328495189
Test: manual
Change-Id: If068597b1d68c52c941788931997b7f77c73d2b3
flag_declaration needs to include the namespace, and origin is not
needed.
Bug: 328495189
Test: manual
Change-Id: Icbadbe6d9888323874c07d84ccd6f50c284e1a1c
This is no longer used since the roboleaf cancellation.
Bug: 315353489
Test: m nothing --no-skip-soong-tests
Change-Id: Ie6ee093c2810498306ea4a2288050eed17a35357
A map iteration was causing a non-deterministic order
in output entries. The default behaviour is to preserve
the same order of the input zips, which is necessary
to ensure a deterministic output for deterministic inputs.
Bug: b/322788229
Test: Ran a couple of builds and confirmed no cache misses from
the output of merge_zips.
Change-Id: I3217e6887ab108d213a290b59da5b33d51b8241f
In order to use soongdbg, you must run analysis with GENERATE_SOONG_DEBUG=true set
in the environment.
Test: GENERATE_SOONG_DEBUG=true m nothing ; soongdbg ...
Change-Id: If43676fe2784f05cd87c0ecb4a46ab676b91023f
n2 (a reimplemntation of ninja) adds a check that depfiles only add
dependencies on source files, not generated files, because generated
files are not guaranteed to exist before an action runs if there isn't
an explicit dependency between the two.
This is the case for our glob result files. However, we can rework the
build so that they're directly depended on instead of using a depfile.
Bug: 318434287
Test: rm -rf out && m nothing && m nothing
Change-Id: I513fa5536136e6bf19c347710f0722d696199612
Generate module_info.json for some Soong modules in Soong in order to
pass fewer properties to Kati, which can prevent Kati reanalysis when
some Android.bp changes are made.
Soong modules can export a ModuleInfoJSONProvider containing the
data that should be included in module-info.json. During the androidmk
singleton the providers are collected and written to a single JSON
file. Make then merges the Soong modules into its own modules.
For now, to keep the result as similar as possible to the
module-info.json currently being generated by Make, only modules that
are exported to Make are written to the Soong module-info.json.
Bug: 309006256
Test: Compare module-info.json
Change-Id: I996520eb48e04743d43ac11c9aba0f3ada7745de
This reverts commit dd9529050d.
Reason for revert: There are at least b/315337725 and b/315036698 issues, reverting this cl while I fix them.
Change-Id: I644bbbe594b9dd53a99a3b6513fbcba68afe0b4a
Previously, sbox would follow the symlink and copy the symlink's target
into the sbox, instead of the symlink itself.
camera-its is a genrule that zips up a folder that includes a symlink,
so we want the symlink to still be there instead of a copy of the file
it points to.
Bug: 307824623
Test: ./build/soong/tests/genrule_sandbox_test.py camera-its
Change-Id: Ib81f6fd6745ec2c58580082c73e33760d5051f5e
Go 1.21 modifies the file limit but restores the original when
execing subprocesses if it hasn't be overridden. Call Setrlimit
even if it doesn't appear to be necessary so that the syscall package
considers it set.
Bug: 309895579
Test: m nothing
Change-Id: I4d0b27bac90a2a88bfc68a8491d54dc106e1ec13
This change defaults Java stubs to be generated from API text files
during build. Using the `--build-from-source-stubs` flag, users can
toggle between the feature.
This change relands aosp/2617457.
Test: m nothing && verify ninja path exists between android_stubs_current and android_stubs_current.from-text, and does not exist between android_stubs_current.from-source, m nothing --build-from-source-stub && verify the opposite
Bug: 301522358
Change-Id: Ic129dafc3231e71470af982374739930947b69cb
This allows product config to determine what build flags are present in
a product's build, as well as their value.
As product config moves to a declarative specification, this can be
handled with less unnecessary work.
Bug: b/302593603, b/308849337, b/309477343
Test: manual
Change-Id: Ic0551990864bba6d03b6bf49fcfd4ae2523d9c6d