Commit Graph

41548 Commits

Author SHA1 Message Date
David Brazdil bc05d3f846 Merge "Revert "Revert "Apply hiddenapi build tool on boot jars"""
am: edd4716ff9

Change-Id: Ib56d4cddae86552b1c58f0bc3ea8f7e0f51216e0
2018-02-01 13:53:38 +00:00
David Brazdil edd4716ff9 Merge "Revert "Revert "Apply hiddenapi build tool on boot jars""" 2018-02-01 09:25:51 +00:00
Jiyong Park 5ebca30d21 Support LOCAL_SDK_VERSION := core_current
core_current is a pseudo SDK version which is a core Java API subset of
the Android API. It is expected to be mainly used for external Java
projects which are agnostic to Android; such as junit, guava, etc.

A module built with this SDK version can only link to java modules of
the same kind. It can't depend on modules built with LOCAL_SDK_VERSION
:= current or without LOCAL_SDK_VERSION.

Bug: 72206056
Test: m -j
Change-Id: I34a9696393aa6704fd6684a40ea5b05d3fb46b23
2018-02-01 17:14:55 +09:00
Tao Bao 19bd39fe3f Merge "releasetools: Move the AVB salt setup into common.LoadInfoDict()."
am: 4b4c3d91b0

Change-Id: If2a9e3100bb9350fc2cdd0c8265b7f7492736889
2018-02-01 00:17:20 +00:00
Treehugger Robot 4b4c3d91b0 Merge "releasetools: Move the AVB salt setup into common.LoadInfoDict()." 2018-02-01 00:06:46 +00:00
Tao Bao 12d87fc174 releasetools: Move the AVB salt setup into common.LoadInfoDict().
We used to do this in add_img_to_target_files.AddImagesToTargetFiles(),
which didn't cover the path when calling from make_recovery_patch. As a
result, /system/bin/install-recovery.sh contains different SHA values
from the actual images.

Test: Set up aosp_bullhead to use AVB. `m dist`, then run the following
      command to verify the generated install-recovery.sh.

  $ ./build/make/tools/releasetools/validate_target_files.py \
      out/dist/aosp_bullhead-target_files-eng.zip

Change-Id: Id7be8fb17072252fcd4d08db2057b8c4af053376
2018-01-31 12:25:10 -08:00
Bowgo Tsai 897c432036 Merge "Renames sepolicy files from nonplat_* to vendor_*"
am: 5e7d417271

Change-Id: If380c487fbdf89a14bddb1d46ee937ee9277395e
2018-01-31 14:46:35 +00:00
Treehugger Robot 5e7d417271 Merge "Renames sepolicy files from nonplat_* to vendor_*" 2018-01-31 14:37:44 +00:00
Isaac Chen 8d11febd59 Add ro.vendor.product.cpu.* to vendor/build.prop
CPU/ABIs related information is already in system/build.prop. It
should also be included in the vendor image so it can still be
examined outside of a device, build environment, or $OUT directory,
by a standalone utility to check its basic characteristics and if
it's compatible with some specific system image (usually GSI).

Bug: 72079894
Test: Built and verified aosp_x86(_64):
      # On host
      $ grep ro.vendor.product.cpu $OUT/vendor/build.prop
      # On device
      $ getprop | grep ro.vendor.product
      $ su
      # grep ro.vendor.product /vendor/build.prop

Change-Id: Ic9ac8065d5983710840e33a805f982de75d86ce3
2018-01-31 14:27:37 +08:00
Tianjie Xu e517144ac9 Merge "Protect SparseImage._GetRangeData() with lock"
am: 5edd2821de

Change-Id: I977e98df87e6a8854cb3f93fc20ffb2f62cd532a
2018-01-30 23:47:00 +00:00
Tianjie Xu 5edd2821de Merge "Protect SparseImage._GetRangeData() with lock" 2018-01-30 23:34:50 +00:00
David Brazdil b8fa6dd104 Revert "Revert "Apply hiddenapi build tool on boot jars""
This reverts commit 4a2926a44e.

Reason for revert: The original CL caused two issues:
1) Increased app startup because `profman` failed to verify boot
jars and created an empty profile for the boot image. All methods
in the framework therefore ran interpreted/JITed. New flag
"--skip-apk-verification" has been added to `profman` to fix
the issue in CL Iad614e47feada293218c11cff985a8012ca49a0f.
2) Caused a crash in Mockito CTS tests because jvmti did not
remove hiddenapi access flags from boot jars before using them.
This has been fixed with CL Ibc9a96a6b541c06844f276db009ac29514f7a3bb.

Bug: 64382372
Bug: 72550707
Test: make test-art-host
Change-Id: Ie8c58714455662f042f56b2977b01b75c5ec7d2f
2018-01-30 18:25:46 +00:00
SzuWei Lin 6e96487968 Correct some GSI settings to board makefile
TARGET_SUPPORTS_32_BIT_APPS and TARGET_SUPPORTS_64_BIT_APPS should
be board config variables. Move them to
target/board/treble_common_64.mk

Bug: 70951849
Test: lunch aosp_arm64_ab-userdebug; make -j
Change-Id: Ia3f6d5db1a7edc956597ab34c2feed088ecc6062
2018-01-30 17:23:47 +08:00
Bowgo Tsai 8b5f514038 Renames sepolicy files from nonplat_* to vendor_*
Bug: 64240127
Test: boot an existing device
Change-Id: I6d6ac7d9dee450b2a20649e5f4dbb8976f48061e
2018-01-30 16:15:12 +08:00
Dan Willemsen 6432cf64b6 Merge "Clean up some kati warnings"
am: 157fbf771b

Change-Id: Ib3a38e2b544900f6961c9af9d71ff1762c4fb02a
2018-01-30 07:48:08 +00:00
Dan Willemsen 157fbf771b Merge "Clean up some kati warnings" 2018-01-30 07:43:27 +00:00
Pirama Arumuga Nainar 7760fdff02 Merge "Write SOONG_MODULES_MISSING_PGO_PROFILE_FILE to $DIST_DIR"
am: d33cac8af1

Change-Id: I059548084c60592998518986c9c09e3eab145965
2018-01-30 06:40:56 +00:00
Treehugger Robot d33cac8af1 Merge "Write SOONG_MODULES_MISSING_PGO_PROFILE_FILE to $DIST_DIR" 2018-01-30 06:34:15 +00:00
Andreas Gampe 2192dda42a Merge "Warn.py: Update errorprone categories"
am: 709ee786cd

Change-Id: I6fb3ff3712f841d67b58af90931c3d735ed5746a
2018-01-30 02:11:51 +00:00
Treehugger Robot 709ee786cd Merge "Warn.py: Update errorprone categories" 2018-01-30 02:05:19 +00:00
Dan Willemsen 893bebc44b Clean up some kati warnings
Kati has a `--warn` option that adds some extra Kati-specific warnings
-- like using undefined make functions, undefined user functions, likely
bad variable lookups, etc. Some of these are bugs, others are fine doing
nothing. This fixes up all of them in the core build system.

It also complains about $(eval) usage in a recipe not being recommended.
Those aren't handled as part of this change.

Bug: 72661763
Test: build-aosp_arm.ninja is identical before and after
Change-Id: I8e00af142a7745236d3ad4efc9e91ec3ce71a511
2018-01-29 16:23:37 -08:00
Pirama Arumuga Nainar ae9595674b Write SOONG_MODULES_MISSING_PGO_PROFILE_FILE to $DIST_DIR
Bug: http://b/72642679

Store missing profile files and the modules that refer to them, passed
via SOONG_MODULES_MISSING_PGO_PROFILE_FILE variable, to
$DIST_DIR/pgo_profile_file_missing.txt as part of the 'dist' target.

Test: 'm dist' and verify creation of pgo_profile_file_missing.txt.
Change-Id: I4ac0a1f413cbb99b33ad1903aeebd3ebcf3b9f59
2018-01-29 14:48:08 -08:00
Tri Vo 55bb62895e Merge "Fix /sys denials."
am: d8e3c4eb07

Change-Id: Icef6458b50ef11744bdcfd19ed22b678d06f45b3
2018-01-29 22:12:17 +00:00
Treehugger Robot d8e3c4eb07 Merge "Fix /sys denials." 2018-01-29 22:04:32 +00:00
Tianjie Xu e62b278865 Merge "Double check the sha1 for ranges during package generation"
am: 92d73d3ab9

Change-Id: Ieb23111a1e42240c5a9754a3ee4dd50ec055f823
2018-01-29 19:57:29 +00:00
Tianjie Xu df1166e92f Protect SparseImage._GetRangeData() with lock
The generator function is not thread safe and is prone to race
conditions. This CL uses a lock to protect this generator and loose the
locks elsewhere, e.g. 'WriteRangeDataToFd()'.

Bug: 71908713
Test: Generate an incremental package several times for angler 4208095 to 4442250.
Change-Id: I9e6f0a182a1ba7904a597f403f2b12fe05016513
2018-01-29 11:52:10 -08:00
Tianjie Xu 92d73d3ab9 Merge "Double check the sha1 for ranges during package generation" 2018-01-29 19:50:08 +00:00
Tobias Thierer 6f1cb62ed4 Merge "javac 9 -target 1.9: Move bootclasspath jars onto classpath."
am: e1b94da7c8

Change-Id: Ib422d959a9276f165293987fb920600d66103c38
2018-01-29 10:56:02 +00:00
Tobias Thierer e1b94da7c8 Merge "javac 9 -target 1.9: Move bootclasspath jars onto classpath." 2018-01-29 10:51:24 +00:00
David Brazdil 744c286b07 Merge "Add flag to control hidden API warning toasts"
am: 4e6c5218db

Change-Id: I1b297c855efce571a8987d773d2d11f9bf67943a
2018-01-29 10:27:30 +00:00
David Brazdil 4e6c5218db Merge "Add flag to control hidden API warning toasts" 2018-01-29 10:22:10 +00:00
Tianjie Xu 8a7ed9f771 Double check the sha1 for ranges during package generation
Check that the Sha1 for src&tgt ranges are correct before computing
patches. This adds ~6 seconds overhead for ~2400 commands.

Bug: 71908713
Test: Generate an incremental package from angler 4208095 to 4442250.
Change-Id: I8cf8ce132fb09a22f7d6689274ddb4a27770be76
2018-01-28 01:54:52 +00:00
Dan Willemsen 71bea86caa Merge "Fix multilib test data being installed twice to the same place"
am: f9d8f6fa7d

Change-Id: I3c9ccd55a715a21bee97afc35f09329c2f6545b0
2018-01-27 03:49:49 +00:00
Treehugger Robot f9d8f6fa7d Merge "Fix multilib test data being installed twice to the same place" 2018-01-27 03:42:09 +00:00
Dan Willemsen 4133793ce3 Fix multilib test data being installed twice to the same place
Fixes lots of warnings of the form:

build/make/core/base_rules.mk:606: warning: overriding commands for target `out/target/product/generic_arm64/testcases/simpleperf_unit_test/testdata/perf.data'
build/make/core/base_rules.mk:606: warning: ignoring old commands for target `out/target/product/generic_arm64/testcases/simpleperf_unit_test/testdata/perf.data'

Test: lunch aosp_arm64-eng; m device-tests
Change-Id: I32575d25f3aef1d4000fcb63d6ffc025ad21f937
2018-01-26 16:57:57 -08:00
Alex Light 67bf2d712a Merge "Revert "Apply hiddenapi build tool on boot jars""
am: 9f1e629503

Change-Id: Ic5def7e5a00c04da6dab1779b0414c7347589188
2018-01-26 19:29:09 +00:00
David Brazdil c573a77645 Merge "Move locations of all hidden API lists into the build folder"
am: 661f97b62b

Change-Id: Ia5397c9feddac2633886fb57c2525069913a2f94
2018-01-26 19:16:35 +00:00
Alex Light 9f1e629503 Merge "Revert "Apply hiddenapi build tool on boot jars"" 2018-01-26 18:40:55 +00:00
Alex Light 4a2926a44e Revert "Apply hiddenapi build tool on boot jars"
This reverts commit b7f00ed2af.

Bug: 72550707
Bug: 64382372
Test: atest CtsInlineMockingTestCases

Reason for revert: Causing invalid dex files to be passed to jvmti
                   agents. This causes CtsInlineMockingTestCases and
                   other tests to fail.

Change-Id: I50129e94791b9e2bef919fe398b4250ae461195b
2018-01-26 18:16:52 +00:00
David Brazdil 661f97b62b Merge "Move locations of all hidden API lists into the build folder" 2018-01-26 16:03:25 +00:00
David Brazdil 41847e1917 Add flag to control hidden API warning toasts
Just like visual warnings about improper use of native libraries,
warnings about the usage of hidden APIs will be displayed in non-
final, non-user builds only.

Bug: 64382372
Test: make
Change-Id: Id0a4200f912ac3303026cb26b6d8974c47332828
2018-01-26 12:19:32 +00:00
David Brazdil 2e36f52738 Move locations of all hidden API lists into the build folder
ART buildbots are broken because they build against a pinned commit of
the framework and thus lack the build rules to generate hidden API lists
We aim to fix this by generating dummy API lists in the build folder.
This patch changes the location of the blacklist and dark greylist from
frameworks/base/config/ to ${TARGET_COMMON_OUT_INTERMEDIATES}/... . On
normal builds, the framework will copy its text files into the build
folder.

Test: make
Bug: 64382372
Change-Id: I9b55d2865599e367d9c4be4f834182f5c084c3bf
2018-01-26 11:35:36 +00:00
Tobias Thierer 0276db1ec7 javac 9 -target 1.9: Move bootclasspath jars onto classpath.
When building with OpenJDK 9's javac with -source 1.9 -target 1.9,
a runtime image (with system modules) is used via the --system
command line flag, instead of --bootclasspath.
The runtime image only contains the default libraries (libcore)
but is missing other libraries that might be on the bootclasspath
for a particular build target.

This CL fixes compilation for this case by adding the missing
jars onto the classpath instead.

This already used to work but was broken by CL [1]. I attempted
to conditionally revert some of that CL's changes to java_common.mk
for the case of language level 1.9, but couldn't get it to work.
Therefore this CL follows a different approach.

[1] http://r.android.com/519552

Bug: 38177569
Test: Treehugger
Test: Ran "EXPERIMENTAL_USE_OPENJDK9=true make checkbuild docs"
      and spot-checked some javac invocations to confirm that the
      system modules libs were not included in the bootclasspath,
      but other libs were.

Change-Id: I48fd11aac9b310bfa58dee0f9cfb3ef33f10bca8
2018-01-26 02:48:48 +00:00
Bryan Eyler 7557f2bc67 Merge "Fix comment indicator on endif"
am: 9f1b1f90a1

Change-Id: I9cf4196a5c2b35aca565fee3f91c6ff11a517952
2018-01-26 02:12:56 +00:00
Treehugger Robot 9f1b1f90a1 Merge "Fix comment indicator on endif" 2018-01-26 01:21:26 +00:00
Bryan Eyler 57b5232def Fix comment indicator on endif
It's referring to the wrong if start.

Change-Id: I6f78aee54fb89fb5f69a4e86102d5a8e2cc2bbd1
2018-01-25 14:55:31 -08:00
Steven Moreland a7f62c3864 Merge "Fix INSTALLED_ -> BUILT_ missing refactor piece."
am: 98fce11494

Change-Id: I17c1cc8379022aa1068036318b8b9e790226be16
2018-01-25 22:16:31 +00:00
David Brazdil b1831cf27e Merge "Apply hiddenapi build tool on boot jars"
am: 221848b181

Change-Id: I79e824d64d23bdb39b129cf439f9e780839b5946
2018-01-25 22:15:49 +00:00
Treehugger Robot 98fce11494 Merge "Fix INSTALLED_ -> BUILT_ missing refactor piece." 2018-01-25 21:23:28 +00:00
Andreas Gampe cf528ca79d Warn.py: Update errorprone categories
From current tip-of-tree.

Bug: 72451126
Test: build/make/tools/warn.py errorprone.log
Change-Id: I1d632fb8801b74af695b4f7f464a99792e46637a
2018-01-25 12:25:20 -08:00