diff options
author | Dan Willemsen <dwillemsen@google.com> | 2018-05-18 11:00:17 -0700 |
---|---|---|
committer | Dan Willemsen <dwillemsen@google.com> | 2018-05-18 11:09:01 -0700 |
commit | 5039ef4d289ade8fee3fcf9f99c6c02c5cc0ecbc (patch) | |
tree | 1c322965847dcfa578971895e08a115fe4e0132a /Changes.md | |
parent | 3d840c6b98ca97d6b8ce3bbf239fe51861c91140 (diff) | |
download | platform_build-5039ef4d289ade8fee3fcf9f99c6c02c5cc0ecbc.tar.gz platform_build-5039ef4d289ade8fee3fcf9f99c6c02c5cc0ecbc.tar.bz2 platform_build-5039ef4d289ade8fee3fcf9f99c6c02c5cc0ecbc.zip |
Add documentation around PATH restrictions
Test: view markdown through gitiles
Change-Id: If9ef146d8993d0dbfde85660d5c87b05c1c11888
Diffstat (limited to 'Changes.md')
-rw-r--r-- | Changes.md | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/Changes.md b/Changes.md index 37bbad09f4..7519096c76 100644 --- a/Changes.md +++ b/Changes.md @@ -1,5 +1,32 @@ # Build System Changes for Android.mk Writers +## PATH Tools {#PATH_Tools} + +The build has started restricting the external host tools usable inside the +build. This will help ensure that build results are reproducible across +different machines, and catch mistakes before they become larger issues. + +To start with, this includes replacing the $PATH with our own directory of +tools, mirroring that of the host PATH. The only difference so far is the +removal of the host GCC tools. Anything that is not explicitly in the +configuration as allowed will continue functioning, but will generate a log +message. This is expected to become more restrictive over time. + +The configuration is located in build/soong/ui/build/paths/config.go, and +contains all the common tools in use in many builds. Anything not in that list +will currently print a warning in the `$OUT_DIR/soong.log` file, including the +command and arguments used, and the process tree in order to help locate the +usage. + +In order to fix any issues brought up by these checks, the best way to fix them +is to use tools checked into the tree -- either as prebuilts, or building them +as host tools during the build. + +As a temporary measure, you can set `TEMPORARY_DISABLE_PATH_RESTRICTIONS=true` +in your environment to temporarily turn off the error checks and allow any tool +to be used (with logging). Beware that GCC didn't work well with the interposer +used for logging, so this may not help in all cases. + ## Deprecating / obsoleting envsetup.sh variables in Makefiles It is not required to source envsetup.sh before running a build. Many scripts, |