245 Commits

Author SHA1 Message Date
Treehugger Robot
c12090200d Merge "Add libcore/ojluni/annotations as a source for metalava." 2018-08-13 12:22:29 +00:00
Alex Light
159799d7c9 Work around b/70221552
If one sets a sufficiently long OUT_DIR to build into the
//frameworks/base:framework-javastream-protos generate target will
fail due to trying to run a too-long command. This works around that
problem by making the command being run much smaller.

Test: Build
Bug: 70221552
Change-Id: I0134ccfc83469826d3ea8679e1c52b9b52c6d2e0
2018-08-08 09:52:51 -07:00
Pete Gillin
c8cbb36673 Add libcore/ojluni/annotations as a source for metalava.
This adds the new annotations (in Java stub format) to the list that
metalava will merge when building stubs.

Bug: 111639530
Test: `make metalava-api-stubs-docs`
Change-Id: I5e73d1276f0602bd14a41f7a64659b1a7b1347cf
2018-08-07 16:49:08 +01:00
Nan Zhang
7e1e76a6dc Merge changes from topic "offlinesdk-docs"
am: 003f49cf0c

Change-Id: Ie2869c671faab24bfc4f426261e4d079d0f3b5de
2018-08-06 18:54:35 -07:00
Nan Zhang
d9cb1b429a Merge "Depend on a module instead of real dir for metalava_merge_annotations_dirs"
am: f8e12c51d4

Change-Id: Ice53109de35716bbdee921d595f015f16f559b3f
2018-08-06 18:30:35 -07:00
Nan Zhang
003f49cf0c Merge changes from topic "offlinesdk-docs"
* changes:
  Add more libs for framework docs generation
  Add offline/online-sdk-docs in Soong.
2018-08-07 00:05:27 +00:00
Nan Zhang
dbc253143b Add more libs for framework docs generation
These two libs are not in the default libs which caused droiddoc report
lots of "package not found warning" when generating offline/online docs.

Test: m -j ds-static-docs
Bug: b/70351683
Change-Id: Ibb1f5e1817895abb1b711dc537493bd93c77077b
2018-08-02 16:29:43 -07:00
Nan Zhang
c3ce78d660 Add offline/online-sdk-docs in Soong.
Since support libraries have been migrated to Soong, these docs modules
currently are ready to be supported in Soong.

Bug: b/70351683
Test: m -j offline-sdk-docs
Change-Id: I8739d94909c7cc830c30fa3d1047d26761cc5076
Merged-In: I8739d94909c7cc830c30fa3d1047d26761cc5076
2018-08-02 12:16:45 -07:00
Nan Zhang
e379f40893 Depend on a module instead of real dir for metalava_merge_annotations_dirs
Bug: b/111916275
Test: touch manual/android/support/design/widget/annotations.xml, and m
-j metalava-api-stubs-docs, and check the built output srcjar.

Change-Id: I82e8b51d66f97ebc3f9f4f5aa75ce33066c95089
2018-08-01 22:19:48 +00:00
Nan Zhang
2a924543f6 Merge "Add offline/online-sdk-docs in Soong." into stage-aosp-master 2018-07-31 22:14:41 +00:00
TreeHugger Robot
6928e50c26 Merge "Frameworks: convert platformprotos to soong" into stage-aosp-master 2018-07-30 20:30:35 +00:00
Olivier Gaillard
d9a8e834dd Merge "Enable generating Binder#getTransactionName method."
am: 3134def524

Change-Id: I5dcdceb1d1e4525576ac21a2bba964dfb6bb0006
2018-07-26 07:20:50 -07:00
Olivier Gaillard
b0ea421351 Enable generating Binder#getTransactionName method.
Test: manual
Bug: 111791983
Change-Id: I68090e6fa5a7876b1e878d0b97807856e3053b36
2018-07-26 11:58:42 +01:00
Nan Zhang
e9a76f7317 Add offline/online-sdk-docs in Soong.
Since support libraries have been migrated to Soong, these docs modules
currently are ready to be supported in Soong.

Bug: b/70351683
Test: m -j offline-sdk-docs
Change-Id: I8739d94909c7cc830c30fa3d1047d26761cc5076
Merged-In: I8739d94909c7cc830c30fa3d1047d26761cc5076
2018-07-25 17:42:36 -07:00
Andreas Gampe
37b0763a70 Frameworks: convert platformprotos to soong
(cherry picked from commit af27bf6662efb8bb9fb7943b0fdbac530b0cbc99)

Bug: 64328974
Test: m
Merged-In: I3729a3132c1ef07dded69801373edf51006fa623
Change-Id: I3729a3132c1ef07dded69801373edf51006fa623
2018-07-25 17:35:35 -07:00
Olivier Gaillard
6722abdede Merge "Disable generating Binder#getTransactionName."
am: 9119e2e49d

Change-Id: Ic2a31bee9e6768c227dd6de8e2500e9e13f77ecf
2018-07-25 13:36:45 -07:00
Pete Gillin
c2b639218e Merge "Turn droiddoc's metalava_merge_annotations_dir into a list."
am: 8c8fb65ad3

Change-Id: I33e614584ec7b445b35872d0b84d5224c6f7c4af
2018-07-25 10:15:02 -07:00
Olivier Gaillard
a657aeb185 Disable generating Binder#getTransactionName.
It might have introduce a performance regression.

Bug: 111791983
Test: manual
Change-Id: I459d9e4e4d2d5d0be0531742a7910848702a1384
2018-07-25 17:18:07 +01:00
Pete Gillin
d6eece37ab Turn droiddoc's metalava_merge_annotations_dir into a list.
This change replaces droiddoc's metalava_merge_annotations_dir
parameter (which takes a single value) with
metalava_merge_annotations_dirs (which takes a list). This will makes
it possible to merge libcore annotations in from a separate directory
under ojluni, instead of adding them in a preprocessing step.

Test: `make metalava-api-stubs-docs` with a local change to add a second directory
Bug: 111639530
Change-Id: I8eb778038c1cb52ddb6fc86d972f555f49e836b2
2018-07-25 11:43:42 +01:00
Olivier Gaillard
c142f686c5 Merge "Enable the generate transaction name for system server."
am: 3e3a6e4760

Change-Id: I0d54112c689aeaf83c4bc108af0a303e2850e85a
2018-07-23 05:07:33 -07:00
Olivier Gaillard
b19219207c Enable the generate transaction name for system server.
Size of vdex,art,oat files (flag off -> on)
- framework/boot*.vdex: +10K  (3.589M -> 3.599M)
- framework/arm64/boot*.{art,oat}: +20K  (4.378M -> 4.398M)

Test: manual
Change-Id: I4938ca5459004494a50ec81db9ef9e0f0e6e7a60
2018-07-23 10:15:54 +00:00
Yifan Hong
58faaa09da IBatteryPropertiesRegistrar: remove unused functions
* Remove BatteryProperties
* Remove IBatteryPropertiesListener
* Remove IBatteryPropertiesRegistrar.(un)registerListener
  functions

Test: builds
Test: boots
Bug: 68724651
Change-Id: Ic9a9d337e5cb39784db1a2745297ef985dd31653
Merged-In: Ic9a9d337e5cb39784db1a2745297ef985dd31653
(cherry picked from commit dd0e942597b51e517eb65d9ea80595d46a3e89df)
2018-07-17 15:35:49 -07:00
David Brazdil
c9b5e65747 Merge changes If285d71a,Iffe5be7c
am: f37950d8c3

Change-Id: I667c07fa75e0cc5badad3f297fc14316a2acfc42
2018-07-17 03:43:13 -07:00
Colin Cross
d7647c1b66 Mark installable jars with installable: true
Most jars don't need to be installed on the device.  Instead of
using java_library and java_library_static to distinguish between
them make java_library and java_library_static identical and use
installable: true to identify the few jars that need to be dexed
and installed on the device.

Bug: 110885583
Test: m checkbuild
Change-Id: I19c0e723285c7088700f50567b9c2140289f9edf
2018-07-10 14:30:07 -07:00
Mathew Inwood
4500790a81 Merge "Add build rule for API->source mapping."
am: b4919259ab

Change-Id: I616da3024e5d310ae6993b4437611cb188c8145a
2018-07-10 11:41:48 -07:00
Mathew Inwood
b4919259ab Merge "Add build rule for API->source mapping." 2018-07-10 17:12:37 +00:00
Colin Cross
19609a7993 Merge "Mark installable jars with installable: true"
am: 1035f48f61

Change-Id: Ia3176e68ddd7cfdb8351b2a0ea95efc9dd94d922
2018-07-10 09:12:46 -07:00
Mathew Inwood
0a6a273013 Add build rule for API->source mapping.
This is used to get source positions of all class members in the boot
class path, to automate the addition of annotations. See
go/hidden-api-annotations for more context.

Mappings printed in:
out/soong/.intermediates/frameworks/base/hiddenapi-mappings
    /android_common/dex-mapping.txt

Test: make hiddenapi-mappings
Bug: 110868826
Change-Id: Ie67a8be6a5a71447a25d081bd466b8b5e01b0725
2018-07-10 09:20:42 +01:00
Colin Cross
a12c0f506c Mark installable jars with installable: true
Most jars don't need to be installed on the device.  Instead of
using java_library and java_library_static to distinguish between
them make java_library and java_library_static identical and use
installable: true to identify the few jars that need to be dexed
and installed on the device.

Bug: 110885583
Test: m checkbuild
Change-Id: I579da7c1a712ec4fb49e288e7f3ab369cb75baf4
2018-06-27 11:49:44 -07:00
Neil Fuller
e01a7adf5a resolve merge conflicts of 55c0a6682574b881b0ccdf2b08fdc4b6c84d1b81 to stage-aosp-master
BUG: None
Test: I solemnly swear I tested this conflict resolution.
Change-Id: Ie524607cabc6688911eee7e4f61c50fd406c71f4
2018-06-26 11:55:46 +01:00
Neil Fuller
cccc48d0fe Minimum viable TimeZoneDetectorService
This is a do-nothing TimeZoneDetectorService that can be
populated in following commits. A temporary method has been
added so the service has one method.

Unit tests can be run with:

atest FrameworksServicesTests:TimeZoneDetectorServiceTest

Test: build / boot
Test: See above
Merged-In: I565fb5dd2f18b7aac2e5779d346bfe69e9da02af
Change-Id: I565fb5dd2f18b7aac2e5779d346bfe69e9da02af
2018-06-21 09:30:34 +00:00
Nan Zhang
0da95a5d64 Merge "Enabled annotations for Metalava based api-stubs."
am: 79d3bf6e54

Change-Id: I8b91e2259ce3b15313d5d4b822bf77696a6ebd5b
2018-06-18 12:13:35 -07:00
Nan Zhang
4b81658d40 Enabled annotations for Metalava based api-stubs.
Test: m -j metalava-api-stubs-docs
Bug: b/78245848
Change-Id: I4ba661900a52f246fc0191c31aabfc96b89fa2db
2018-06-13 17:42:09 -07:00
Neil Fuller
79d42a61e4 resolve merge conflicts of 5e1d95b0cc05eb1a6bf25a13223601f2e8f8fccb to stage-aosp-master
BUG: None
Test: I solemnly swear I tested this conflict resolution.
Change-Id: Ic5527b29cbe8c84d2053be849cf09df5341e4790
2018-06-12 14:23:51 +01:00
Neil Fuller
b557907f51 Minimum viable TimeDetectorService
This is a do-nothing TimeDetectorService that can be
populated in following commits. A temporary method has been
added so the service has one method.

Unit tests can be run with:

atest FrameworksServicesTests:TimeDetectorServiceTest

Test: build / boot
Test: See above
Merged-In: I9e4eac70b944441f34491315cd1ce7fa2b9ae150
Change-Id: I9e4eac70b944441f34491315cd1ce7fa2b9ae150
(cherry picked from commit feeee682a23f25760c4a1aa07c00945901911ba3)
2018-06-11 15:29:57 +01:00
David Brazdil
6f6a126b9c Build dark greylist from public + light grey API
The dark greylist is meant to contain non-SDK APIs which are "related"
to APIs accessible to apps without restrictions. The list used to be
built as all non-SDK APIs in the same package as those on the light
greylist. That is not sufficient and should include the public SDK API
packages too.

This patch modifies the makefile to generate a list of public API DEX
signatures with Doclava and then use that as a basis for the dark
greylist generation.

Bug: 80461842
Bug: 64382372
Test: make out/target/common/obj/PACKAGING/hiddenapi-blacklist.txt
Change-Id: I4b1588013f26661207126b4006cdef0a0fc8ae2c
2018-06-07 09:45:01 +00:00
Nan Zhang
18543da456 Merge "Add metalava based api-stubs modules in Android.bp" am: f907578564
am: 25d4494793

Change-Id: I61a4f39fdef76aa49dea1b007b805cac5e55526f
2018-06-06 01:20:55 -07:00
Nan Zhang
4212eb1bef Add metalava based api-stubs modules in Android.bp
Test: m clean && m metalava-api-stubs-docs
Bug: b/78245848
Change-Id: Ie0943d306af4176d965425ec85236cd173c1e870
2018-06-05 17:00:52 -07:00
Jiyong Park
fa15a99fe9 Remove FlpHardwareProvider
After Treble's FLP merge into GNSS HAL, the FlpHardwareProvider is just
an empty shell. Removing FusedLocation and/or Flp + Hardware classes
altogether.

Bug: 35726697
Test: m -j
Test: Open Google Map and then walk around. The dot moves as I walk.

Merged-In: I7f413e38b57424e8ebb9d7d14d94f145a48d10f8
Change-Id: I7f413e38b57424e8ebb9d7d14d94f145a48d10f8
(cherry picked from commit 4cc3a1c056f69ac4da1dc5055c36b7357e9f673c)
2018-05-25 16:38:52 +09:00
Nan Zhang
39d2d18b80 Update Android.bp for api-stubs in order to do api-check.
Bug: b/78034256
Test: m clean && m checkapi

Change-Id: Ifbda8825f95e26bb79aac9b1bb73c5e43f12d1fb
Merged-In: Ifbda8825f95e26bb79aac9b1bb73c5e43f12d1fb
2018-05-15 15:47:01 -07:00
Nan Zhang
05c47c8e5c Update Android.bp for api-stubs in order to do api-check.
Bug: b/78034256
Test: m clean && m checkapi

Change-Id: Ifbda8825f95e26bb79aac9b1bb73c5e43f12d1fb
2018-05-09 11:23:43 -07:00
David Brazdil
a5d0d86b63 resolve merge conflicts of 4d213e585646e35da888b9059f4d1f24c932a656 to pi-dev-plus-aosp
BUG: None
Test: I solemnly swear I tested this conflict resolution.
Merged-In: Ifa912f8751025b7de24a982a1a227a9c27d18267
Change-Id: I9dc9a1e81d9a4d82823e15d1af0cc814a1005174
2018-05-02 13:44:48 +00:00
David Brazdil
96c9cbc1a1 Build same hidden API lists as in pi-dev
P branch builds hidden API lists in a separate invocation of droiddoc
which includes @SystemApi and @TestApi annotated class members in the
public API. This patch creates the same build rule in the master branch,
only with Soong instead of Makefile.

Test: make out/soong/.intermediates/frameworks/base/hiddenapi-lists/android_common/private-dex.txt
Merged-In: Ifa912f8751025b7de24a982a1a227a9c27d18267
Change-Id: I80860c2b9f7213db65d0a9ca65bd645187aa0ce0
2018-05-02 08:54:02 +00:00
David Brazdil
9150bd4b48 Merge "Generate @removed DEX API signatures" am: eddd165c20
am: 86cd9642c3

Change-Id: I936c3b375a4c1a58c301965f6a2922e135699663
2018-04-26 07:41:56 -07:00
David Brazdil
df41728b85 Generate @removed DEX API signatures
CL I8fe27e8c03334f9c90204db1e69447de65a06a38 adds support to generate
a list of all @removed DEX API signatures. Amend the public API build
rule to produce this file.

Bug: 78182899
Test: make
Change-Id: Iba8869ce6e4f401a8e420ad83ab459d25bbbaae0
2018-04-24 16:27:53 +01:00
Anton Hansson
e5bf20608a Move frameworks/base off the SRC_API_DIR variable.
This directory is going away. Migrate to the new paths, and replace the
long list of "since" arguments with a loop in the makefile. Also fix the
soong buildfile to use the new path and the 28 prebuilts.

This removes the need to update it every time an API is finalized (in make,
I don't know how to make loops in soong).

Bug: 77525052
Test: Verified variable is the same before & after, except for path change
Change-Id: I1d4e87e7840e979b83779a2aefe176e7c1ed1527
Merged-In: I1d4e87e7840e979b83779a2aefe176e7c1ed1527
2018-04-23 15:46:19 +01:00
Anton Hansson
6a9e72651b Move frameworks/base off the SRC_API_DIR variable.
This directory is going away. Migrate to the new paths, and replace the
long list of "since" arguments with a loop in the makefile. Also fix the
soong buildfile to use the new path and the 28 prebuilts.

This removes the need to update it every time an API is finalized (in make,
I don't know how to make loops in soong).

Bug: 77525052
Test: Verified variable is the same before & after, except for path change
Change-Id: I1d4e87e7840e979b83779a2aefe176e7c1ed1527
2018-04-23 11:44:53 +01:00
Makoto Onuki
fa3a2acfbc Merge "Add stats logging to ServiceManager and NPMS" into pi-dev
am: a26e755900

Change-Id: Ib0bd9ecc183b1b2c9a6785554e6f717744820da3
2018-04-11 18:39:53 -07:00
Makoto Onuki
49392d335a Add stats logging to ServiceManager and NPMS
ServiceManager:
- Do an event log every N getService() calls with total time spent
in getService().
where N = 100 for core UIDs and 200 for other apps.

- Do an event log if getService() takes longer than N ms.
where N = 10 for core UIDs and 50 for other apps.

... with some extra throttling.

NPMS:
- Do the basic "stats logger" log for updateNetworkEnabledNL() and
isUidNetworkingBlocked()

This CL also enhances StatsLogegr so it now can show the slowest call
and the max # of calls per-second.

Bug: 77853238
Test: Manual test:
- Insert a SIM card
- Set data limit
- toggle airplane mode
- toggle wifi
- toggle mobile data

Then
- "dumpsys netpolicy" and "dumpsys activity processes" and check the stats
- also check "adb logcat -b all | grep ' service_manager'"

Change-Id: I5789541063f95d0eac501189816c8604a4571ba0
2018-04-11 16:37:57 -07:00
Nan Zhang
99ce5c7090 Add filegroup for supporting apache-http stubs generation.
Bug: b/70351683
Test: m clean && m check-apache-http-legacy-api,
and compare the old and new stubs.jar using md5sum.

Change-Id: I0035837aef48a76e40a2c723c2adce3ff129ad28
Merged-In: I0035837aef48a76e40a2c723c2adce3ff129ad28
2018-04-11 14:57:28 -07:00