Commit graph

1235 commits

Author SHA1 Message Date
Elliott Hughes
2ad30002d5 Merge "Reland "Remove product_is_iot."" am: 80e071d1da
am: 4177df9567

Change-Id: Ifd2537508ccd9f9331ef94bfdd1ea824f817ca3e
2019-08-01 12:08:42 -07:00
Elliott Hughes
4177df9567 Merge "Reland "Remove product_is_iot.""
am: 80e071d1da

Change-Id: I875289d3b5f88034b4e1256054b41fb9e05dfdd1
2019-08-01 11:59:54 -07:00
Elliott Hughes
80e071d1da Merge "Reland "Remove product_is_iot."" 2019-08-01 18:24:26 +00:00
Elliott Hughes
1f3a239953 Reland "Remove product_is_iot."
This reverts commit 5089c11b1e.

Change-Id: Iaedc22e63560a01ab01859982dc627569a421025
Test: treehugger
2019-08-01 14:42:12 +00:00
Nelson Li
171f6bfa7b Merge "Revert "Remove product_is_iot."" am: 604374742d
am: 742677d7b6

Change-Id: If961e139b66b79dcea3dbd555c6a517f9307447d
2019-08-01 03:48:15 -07:00
Nelson Li
742677d7b6 Merge "Revert "Remove product_is_iot.""
am: 604374742d

Change-Id: I85167277df48f3887d17a2670167b6aba6c5519d
2019-08-01 03:37:17 -07:00
Treehugger Robot
604374742d Merge "Revert "Remove product_is_iot."" 2019-08-01 10:16:24 +00:00
Nelson Li
5089c11b1e Revert "Remove product_is_iot."
This reverts commit 14fa562fbb.

Reason for revert: Broken build on 5772180

error: frameworks/av/media/utils/Android.bp:49:23: unrecognized property "product_variables.product_is_iot"

Bug: 138764596
Change-Id: I37944dfb974e4180a683361f514b404f92b943e5
2019-08-01 06:28:05 +00:00
Elliott Hughes
bde44fc84d Merge "Remove product_is_iot." am: 75b3788d6c
am: 7bb10aa40d

Change-Id: I6effeaa5ee93faf83a237b80505a4d1243182598
2019-07-31 22:29:03 -07:00
Elliott Hughes
7bb10aa40d Merge "Remove product_is_iot."
am: 75b3788d6c

Change-Id: Ic639b5f1ac256be3369c6fe789bbef428aeac353
2019-07-31 22:07:05 -07:00
Treehugger Robot
75b3788d6c Merge "Remove product_is_iot." 2019-08-01 04:42:40 +00:00
Steven Moreland
03b76a9965 Merge "Automatically inherit common properties." am: d28f688e69
am: e3ff85b968

Change-Id: Id2e996d5d30120fabca41b96666452ba9784045f
2019-07-31 09:21:44 -07:00
Steven Moreland
e3ff85b968 Merge "Automatically inherit common properties."
am: d28f688e69

Change-Id: I2608257a595ade933d291ef5c4fb1f2c633c292b
2019-07-31 09:10:41 -07:00
Steven Moreland
d28f688e69 Merge "Automatically inherit common properties." 2019-07-31 15:47:51 +00:00
Jiyong Park
42aaba73ac Merge "Delete prebuilt APEXes when installing source-built APEXes" am: a822256e15
am: fb45ee3d1e

Change-Id: I8d8eddee843c34fbce4c19a6cbb5a1d2ce3f218e
2019-07-31 00:50:07 -07:00
Jiyong Park
fb45ee3d1e Merge "Delete prebuilt APEXes when installing source-built APEXes"
am: a822256e15

Change-Id: I576969455e028010da6631f06010fd6369c4b589
2019-07-31 00:40:06 -07:00
Treehugger Robot
a822256e15 Merge "Delete prebuilt APEXes when installing source-built APEXes" 2019-07-31 07:03:49 +00:00
Steven Moreland
12f23e0883 Automatically inherit common properties.
Before, the values were often simply ignored. If bad values are provided
now, we should be able to catch them.

Bug: 119771576
Test: relying on this for AIDL/HIDL
Change-Id: I8d2ff26da0b2d01ebe7f78c26d69c7b618a65367
2019-07-30 22:42:19 +00:00
Elliott Hughes
14fa562fbb Remove product_is_iot.
Test: treehugger
Change-Id: I0935f463138e1d2a364cd2a5bc8b6e977da1ec47
2019-07-30 08:43:50 -07:00
Jiyong Park
03b68ddd10 Delete prebuilt APEXes when installing source-built APEXes
To build the platform for ASAN, we do

`m && SANITIZE_TARGET='addresss' m`

However, at the end of the second build, the system partition could have
conflicting APEXes; prebuilt APEXes from the first build and
source-built APEXes from the second build. Since the file names for the
prebuilt and the source-built are different (e.g.
com.google.android.media.apex v.s. com.android.media.apex), we end up
having two files for the same APEX. This is confusing apexd at runtime
and the device fails to boot.

To fix this, when building a non-prebuilt APEX, the prebuilt APEX might
have been installed by the previous build is deleted.

Bug: 138146044
Test: lunch aosp_cf_x86_pasan; m && SANITIZE_TARGET='address' m
check that out/target/product/vsoc_x86/system/apex has
com.android.*.apex only.

Change-Id: Ib5a021a297cf0173ea5a3b50e9398b1cf295c558
2019-07-30 13:52:15 +09:00
Sasha Smundak
94704e9594 Merge "Support source code cross-referencing for C++ and Java" am: 247de68b89
am: 61272795a7

Change-Id: Ib39b5d0fb8ae386ec0616c9fe26496644d9e7460
2019-07-29 18:22:09 -07:00
Sasha Smundak
61272795a7 Merge "Support source code cross-referencing for C++ and Java"
am: 247de68b89

Change-Id: I5284d9be9865e95671ce8ec1927f74059f7fdf44
2019-07-29 18:13:05 -07:00
Treehugger Robot
247de68b89 Merge "Support source code cross-referencing for C++ and Java" 2019-07-30 00:13:12 +00:00
Sasha Smundak
2a4549ec98 Support source code cross-referencing for C++ and Java
Use Kythe (https://kythe.io) to build cross reference for the Android
source code. ~generate the input for it during the build. This is done
on demand: if XREF_CORPUS environment variable is set, build emits a
Ninja rule to generate Kythe input for each compilation rule. It
also emits two consolidation rules (`xref_cxx` and `xref_java`),
that depend on all Kythe input generation rules for C++ and Java.

The value of the XREF_CORPUS environment variable is recorded in the
generated files and thus passed to Kythe. For the AOSP master branch it is
`android.googlesource.com/platform/superproject`, so the command to build
all input for Kythe on that branch is:
```
XREF_CORPUS=android.googlesource.com/platform/superproject m xref_cxx xref_java
```

Each Kythe input generation rule generates a single file with .kzip
extension. Individual .kzip files have a lot of common information, so
there will be a post-build consolidation step run to combine them.
The consolidated .kzip file is then passed to Kythe backend.

The tools to generate .kzip files are provided by Kythe (it calls them
'extractors'). We are going to build them in toolbuilding branches
(clang-tools and build-tools) and check them in as binaries into master
and other PDK branches:
For C++,  `prebuilts/clang-tools/linux-x86/bin/cxx_extractor`
for Java, `prebuilts/build-tools/common/framework/javac_extractor.jar`

Bug: 121267023
Test: 1) When XREF_CORPUS is set, build generates Ninja rules to create
.kzip files; 2) When XREF_CORPUS is set, building
`xref_cxx`/`xref_java` creates .kzip files; 3) Unless XREF_CORPUS is
set, build generates the same Ninja rules as before

Change-Id: If957b35d7abc82dbfbb3665980e7c34afe7c789e
2019-07-26 09:16:47 -07:00
Paul Duffin
9561fd3f78 Merge changes I7b9462d3,Icadd470a,I1d459da1,I01d8f518 am: 4b03cb46a5
am: cdfa3fb705

Change-Id: I130af385902c928e10e183a2ae47965f49d66c29
2019-07-26 02:09:13 -07:00
Paul Duffin
cdfa3fb705 Merge changes I7b9462d3,Icadd470a,I1d459da1,I01d8f518
am: 4b03cb46a5

Change-Id: I6a5fc7321e80333390189a1adb7a1ffb3553bd7c
2019-07-26 01:59:32 -07:00
Paul Duffin
4b03cb46a5 Merge changes I7b9462d3,Icadd470a,I1d459da1,I01d8f518
* changes:
  Add defaults_visibility support
  Refactor visibility to support visibility on defaults modules
  Add DefaultsModule interface
  Improve documentation of defaults mechanism
2019-07-26 08:35:15 +00:00
Jooyung Han
646c483619 Merge "fix: prebuilt_etc_xml" am: 04b2a82b77
am: 4739405a0e

Change-Id: I0e531e46fa7cd2707847958fb5a0e6bbf5f7ab64
2019-07-25 22:35:27 -07:00
Jooyung Han
4739405a0e Merge "fix: prebuilt_etc_xml"
am: 04b2a82b77

Change-Id: I581999dc553a745d49f05a0954d965ca0fa28213
2019-07-25 22:24:39 -07:00
Treehugger Robot
04b2a82b77 Merge "fix: prebuilt_etc_xml" 2019-07-26 04:57:29 +00:00
Paul Duffin
abc1838a78 Merge "Fixed minor typo" am: e515886a8b
am: f5df899687

Change-Id: I2cbd019e80992bcc10295f99e3a01bc2c7791a21
2019-07-25 11:01:14 -07:00
Paul Duffin
f5df899687 Merge "Fixed minor typo"
am: e515886a8b

Change-Id: I5d99efb2e18c02eacb5946320fd7d3504e1e32b5
2019-07-25 10:51:11 -07:00
Paul Duffin
036cacee51 Fixed minor typo
Bug: 138207002
Test: m nothing
Change-Id: Idc6bc6ae9d7e4052da0c0bde6247bff47eab60be
2019-07-25 14:44:56 +01:00
Paul Duffin
95d53b584f Add defaults_visibility support
Bug: 130796911
Test: m nothing
Change-Id: I7b9462d3360be2bbeaf6ff38c5328f45ff5b5ebb
2019-07-25 11:48:21 +01:00
Paul Duffin
63c6e183d5 Refactor visibility to support visibility on defaults modules
Existing modules, either general one or package ones have a single
visibility property, called visibility in general, and
default_visibility on package, that controls access to that module, or
in the case of package sets the default visibility of all modules in
that package. The property is checked and gathered during the similarly
named phases of visibility processing.

The defaults module will be different as it will have two properties.
The first, visibility, will not affect the visibility of the module, it
only affects the visibility of modules that 'extend' the defaults. So,
it will need checking but not parsing. The second property,
defaults_visibility, will affect the visibility of the module and so
will need both checking and parsing.

The current implementation does not handle those cases because:
1) It does not differentiate between the property that affects the
   module and those that do not. It checks and gathers all of them with
   the last property gathered overriding the rules for the previous
   properties.

2) It relies on overriding methods in MethodBase in order to change the
   default behavior for the package module. That works because
   packageModule embeds ModuleBase but will not work for
   DefaultsModuleBase as it does not embed ModuleBase and instead is
   embedded alongside it so attempting to override a method in
   MethodBase leads to ambiguity.

This change addresses the issues as follows:
1) It adds a new visibility() []string method to get access to the
   primary visibility rules, i.e. the ones that affect the module.

2) It adds two fields, 'visibilityPropertyInfo []visibilityProperty'
   to provide information about all the properties that need checking,
   and 'primaryVisibilityProperty visibilityProperty' to specify the
   property that affects the module.

The PackageFactory() and InitAndroidModule(Module) functions are
modified to initialize the fields. The override of the
visibilityProperties() method for packageModule is removed and the
default implementations of visibilityProperties() and visibility()
on ModuleBase return information from the two new fields.

The InitDefaultsModule is updated to also initialize the two new
fields. It uses nil for primaryVisibilityProperty for now but that
will be changed to return defaults_visibility. It also uses the
commonProperties structure created for the defaults directly instead
of having to search for it through properties().

Changed the visibilityProperty to take a pointer to the property that
can be used to retrieve the value rather than a lambda function.

Bug: 130796911
Test: m nothing
Change-Id: Icadd470a5f692a48ec61de02bf3dfde3e2eea2ef
2019-07-25 11:31:42 +01:00
Paul Duffin
e62432feee Add DefaultsModule interface
Changes the InitDefaultsModule method from taking a DefaultableModule
to taking a DefaultsModule in preparation for adding visibility support
to defaults modules.

Bug: 130796911
Test: m nothing
Change-Id: I1d459da1017ae7f2654e7eb275cb424e52d85730
2019-07-25 10:51:27 +01:00
Paul Duffin
7df7fb0dff Improve documentation of defaults mechanism
Also, removes unnecessary cast from DefaultableModule to Defaultable.

Bug: 130796911
Test: m nothing
Change-Id: I01d8f5186927215a1aa6b7431558041f427d7381
2019-07-25 10:50:57 +01:00
Roland Levillain
574743ccf3 Merge "Fix some typos in Soong." am: 5260acef69
am: e41bbbf94c

Change-Id: Ic5bf2a6c84e79b93757152643bb1fa1e5b7caced
2019-07-23 13:18:32 -07:00
Roland Levillain
e41bbbf94c Merge "Fix some typos in Soong."
am: 5260acef69

Change-Id: I61050b05bf4831ca753e4a70efb5e184c379232b
2019-07-23 12:58:15 -07:00
Roland Levillain
dfe75b389c Fix some typos in Soong.
Test: m
Change-Id: I5b332ce12d70f13eca93b23060620c0ea4f46db7
2019-07-23 17:29:57 +01:00
Ramy Medhat
87f0108f37 Merge "Add USE_RBE support to soong." am: 2b78fda705
am: 66b73ceddc

Change-Id: I2242a686fe3b307f49b975e9c07d70883be3a343
2019-07-23 05:29:20 -07:00
Ramy Medhat
66b73ceddc Merge "Add USE_RBE support to soong."
am: 2b78fda705

Change-Id: I69e20f5e54c1d156e26d4634dfec05d17cee126d
2019-07-23 05:19:25 -07:00
Ramy Medhat
2b78fda705 Merge "Add USE_RBE support to soong." 2019-07-23 11:49:10 +00:00
Colin Cross
d0cb1f57c7 Merge changes Ic2a585ea,I11ccabc4,Icc932c4a,I020556c7,I08713e91 am: ed9a92c311
am: a373a94fc0

Change-Id: Idace0a12e475ef12a5055974052b10197ca1c561
2019-07-22 14:13:42 -07:00
Colin Cross
a373a94fc0 Merge changes Ic2a585ea,I11ccabc4,Icc932c4a,I020556c7,I08713e91
am: ed9a92c311

Change-Id: I0367335939181566063b777184e864a7afb02308
2019-07-22 14:04:58 -07:00
Treehugger Robot
ed9a92c311 Merge changes Ic2a585ea,I11ccabc4,Icc932c4a,I020556c7,I08713e91
* changes:
  Fix date on mac builds
  Convert javadoc modules to android.RuleBuilder
  Convert droiddoc modules to android.RuleBuilder
  Add a systemModules utility type
  Convert droidstubs to android.RuleBuilder
2019-07-22 20:29:59 +00:00
Paul Duffin
c5d109063d Merge "Revert "Revert "Prevent runtime module paths being used in include_dirs""" into stage-aosp-master
am: cebbe099df

Change-Id: Ib9abc9a0942fd189104b644ec7b5b5eb4ac53998
2019-07-22 11:48:15 -07:00
Paul Duffin
c811170ab6 Revert "Revert "Prevent runtime module paths being used in include_dirs""
This reverts commit ff3d72f0bf.

Repplies original change now that issue causing build breakage has been
resolved.

Adds a new StartsWith(string) ValueMatcher along with
With[Out]Matcher(...) methods to support new restrictions that prevent
any paths into runtime module repositories from being added to the
include_dirs.

Test: m nothing
Bug: 35624006
Change-Id: I4c802ef25ef56f0f9b0b5e9d75531ea6f7475714
2019-07-22 12:24:49 +01:00
Jooyung Han
a0171822be fix: prebuilt_etc_xml
Since aosp/872653 and aosp/904233 landed, prebuilt_etc_xml has been broken.
aosp/872653: Enable arch variant properties in prebuilt_etc.
aosp/904233: Add a prebuilt module type for usr/share.

This change fixes
1) pass baseDir "etc" to initialize PrebuiltEtc struct
2) change "multlib" argument to MultilibFirst to reflect aosp/872653

Bug: 138082739
Test: m com.google.vr.platform.xml && see if it is installed in /system/etc
Change-Id: I4802107fd8ccf28a1170d7d165700c92df32e341
2019-07-22 16:15:25 +09:00
Ming-Shin Lu
d6e4a90b01 Revert "Prevent runtime module paths being used in include_dirs"
am: ff3d72f0bf

Change-Id: Iaa36cca8e24121e9dc673a757a3a22266f117768
2019-07-22 00:14:38 -07:00