android/platform-build.git
2 years agoMerge "Split *_product makefiles" master
Treehugger Robot [Wed, 16 Jan 2019 15:18:37 +0000 (15:18 +0000)]
Merge "Split *_product makefiles"

2 years agoSplit *_product makefiles
SzuWei Lin [Wed, 9 Jan 2019 09:08:25 +0000 (17:08 +0800)]
Split *_product makefiles

So far, we have *_system.mk and *_vendor.mk.
This patch split all product settings from *_vendor.mk to new
*_product.mk

This patch also create a new telephony.mk to include all
telephony_*.mk

Bug: 119747870
Test: lunch mainline_arm64-user; make -j
Test: compare the content with and without the patch
Test: the output files in out folder are the same
Change-Id: I79aefdd1971b3b5724a3ec858de4109b645c765a
Merged-In: I79aefdd1971b3b5724a3ec858de4109b645c765a

2 years agoMerge "Remove webview from media_system.mk"
Anton Hansson [Wed, 16 Jan 2019 09:44:39 +0000 (09:44 +0000)]
Merge "Remove webview from media_system.mk"

2 years agoMerge "Execute appcompat for apps built from soong"
Treehugger Robot [Wed, 16 Jan 2019 08:53:48 +0000 (08:53 +0000)]
Merge "Execute appcompat for apps built from soong"

2 years agoExecute appcompat for apps built from soong
Jeongik Cha [Tue, 8 Jan 2019 03:41:48 +0000 (12:41 +0900)]
Execute appcompat for apps built from soong

Appcompat runs for app defined in Android.mk, but not in Android.bp
So make appcompat run for app from soong(Android.bp)

Bug: 110073830
Bug: 122026042

Test: m out/target/product/$(get_build_var TARGET_DEVICE)/appcompat.zip

Change-Id: I73832410ec5850222b04086c2a377146886ba035

2 years agoMerge "Revert "Simplify soong_java_prebuilt.mk and soong_app_prebuilt.mk""
Colin Cross [Wed, 16 Jan 2019 01:41:01 +0000 (01:41 +0000)]
Merge "Revert "Simplify soong_java_prebuilt.mk and soong_app_prebuilt.mk""

2 years agoRevert "Simplify soong_java_prebuilt.mk and soong_app_prebuilt.mk"
Colin Cross [Wed, 16 Jan 2019 01:38:41 +0000 (01:38 +0000)]
Revert "Simplify soong_java_prebuilt.mk and soong_app_prebuilt.mk"

This reverts commit a76cc6d732431ebb2ceddaf87445aedd548d1623.

Reason for revert: broke emma turbine build

Change-Id: Ie894565501d0de44f96dc736408a8c4e2ba2ed90

2 years agoMerge "Simplify soong_java_prebuilt.mk and soong_app_prebuilt.mk"
Colin Cross [Tue, 15 Jan 2019 23:39:25 +0000 (23:39 +0000)]
Merge "Simplify soong_java_prebuilt.mk and soong_app_prebuilt.mk"

2 years agoMerge "Enable execute-only memory layouts by default."
Ivan Lozano [Tue, 15 Jan 2019 23:29:51 +0000 (23:29 +0000)]
Merge "Enable execute-only memory layouts by default."

2 years agoMerge "Add gsid"
Treehugger Robot [Tue, 15 Jan 2019 23:26:58 +0000 (23:26 +0000)]
Merge "Add gsid"

2 years agoEnable execute-only memory layouts by default.
Ivan Lozano [Thu, 10 Jan 2019 17:46:52 +0000 (09:46 -0800)]
Enable execute-only memory layouts by default.

This enables execute-only memory (XOM) layouts to be used by default in
the build system. As of now, there's only support for ARM64 devices, so
this only affects those. Since userland XOM requires kernel support,
devices without the necessary support will continue to allow pages
marked execute-only to be read and they should be unaffected by this.

Bug: 77958880
Test: Device with and without kernel support boot.
Test: Binary throws segfault when reading from XOM on supported device.
Test: Debugger works and stack traces are still generated correctly.
Test: Teamfooding, stable during regular usage.

Change-Id: I8db4235c8e60eea6d701bdf3c43b79a06d6b01cd

2 years agoMerge changes I6457933a,I955aa0fa
Mark Salyzyn [Tue, 15 Jan 2019 20:33:50 +0000 (20:33 +0000)]
Merge changes I6457933a,I955aa0fa

* changes:
  Revert "Relax inode usage estimation slack for DAP right sizing"
  Revert "Increase slack for inode estimation algorithm"

2 years agoMerge "Fix typo in some comments"
Treehugger Robot [Tue, 15 Jan 2019 19:55:08 +0000 (19:55 +0000)]
Merge "Fix typo in some comments"

2 years agoMerge "Stop using the `files` target for droidcore"
Dan Willemsen [Tue, 15 Jan 2019 19:11:01 +0000 (19:11 +0000)]
Merge "Stop using the `files` target for droidcore"

2 years agoMerge "Revert "Add core-simple to the standard boot classpath""
Neil Fuller [Tue, 15 Jan 2019 19:04:26 +0000 (19:04 +0000)]
Merge "Revert "Add core-simple to the standard boot classpath""

2 years agoSimplify soong_java_prebuilt.mk and soong_app_prebuilt.mk
Colin Cross [Mon, 14 Jan 2019 22:10:20 +0000 (14:10 -0800)]
Simplify soong_java_prebuilt.mk and soong_app_prebuilt.mk

Simplify importing Soong modules into Make by always copying
LOCAL_PREBUILT_MODULE_FILE to LOCAL_BUILT_MODULE, which lets
Soong pick the final output file instead of trying to figure
out which of the various intermediate files should be the
output file.

Also fixes an issue where hostdex modules could attempt to
copy to both $(common_javalib.jar) and $(LOCAL_BUILT_MODULE),
which are the same file for host java modules.

Test: set compile_dex:true on core.platform.api.stubs. no warnings
      of target overriding
Test: m checkbuild

Change-Id: Id84d499a0869961be5a906d8472b75b9c843b4b4

2 years agoMerge "Error if a Soong module attempts to install a classes jar"
Treehugger Robot [Tue, 15 Jan 2019 17:40:28 +0000 (17:40 +0000)]
Merge "Error if a Soong module attempts to install a classes jar"

2 years agoFix typo in some comments
Jiyong Park [Tue, 15 Jan 2019 16:07:35 +0000 (01:07 +0900)]
Fix typo in some comments

Test: no need
Change-Id: I68620689f1a2eb2eca67e11b55dc781e7744859e

2 years agoRemove webview from media_system.mk
Anton Hansson [Tue, 15 Jan 2019 14:36:14 +0000 (14:36 +0000)]
Remove webview from media_system.mk

It is present in media_vendor.mk (and soon media_product.mk),
which is the correct place.

Test: make
Change-Id: I7ffda211cf4b01a22ec01c661959defcf59bbc4b

2 years agoMerge "ATest: Add test config template for python."
Treehugger Robot [Tue, 15 Jan 2019 10:04:58 +0000 (10:04 +0000)]
Merge "ATest: Add test config template for python."

2 years agoAdd gsid
Howard Chen [Tue, 15 Jan 2019 07:54:48 +0000 (15:54 +0800)]
Add gsid

The gsid is a daemon for managing GSI.

Bug: 122556707
Test: make && ls ${OUT}/bin/gsid
Change-Id: Ib4a3e95a7e232236ee1255a156043e45a77a3c8e

2 years agoStop using the `files` target for droidcore
Dan Willemsen [Tue, 15 Jan 2019 05:46:31 +0000 (21:46 -0800)]
Stop using the `files` target for droidcore

This way if a BoardConfig.mk configures a specific image to exist (so it
doesn't end up as a folder on /system), but does not configure for it to
be created (like the device targets on AOSP that use a prebuilt), we
won't unnecessarily trigger the build system to build the contents.

Test: `m` before and after, comparing file lists
Test: check treehugger builds before/after
Change-Id: If0e4b958b3dfaa02771a5da70f970379635f904e

2 years agoMerge "Add IBluetoothAudio HAL 2.0 to VNDK"
Treehugger Robot [Tue, 15 Jan 2019 00:35:25 +0000 (00:35 +0000)]
Merge "Add IBluetoothAudio HAL 2.0 to VNDK"

2 years agoMerge "Remove myself from OWNER file"
Nan Zhang [Mon, 14 Jan 2019 23:49:25 +0000 (23:49 +0000)]
Merge "Remove myself from OWNER file"

2 years agoMerge "Add viewcompiler to device"
Treehugger Robot [Mon, 14 Jan 2019 22:36:54 +0000 (22:36 +0000)]
Merge "Add viewcompiler to device"

2 years agoMerge "Use find(1)'s -exec directly."
Elliott Hughes [Mon, 14 Jan 2019 21:42:00 +0000 (21:42 +0000)]
Merge "Use find(1)'s -exec directly."

2 years agoUse find(1)'s -exec directly.
Elliott Hughes [Mon, 14 Jan 2019 20:56:07 +0000 (12:56 -0800)]
Use find(1)'s -exec directly.

toybox xargs doesnt have --no-run-if-empty:

  xargs: Unknown option no-run-if-empty (see "xargs --help")

But we shouldn't need it anyway.

Test: make -j32 showcommands dist TARGET_BUILD_APPS='Launcher3 Launcher3Tests' EMMA_INSTRUMENT_STATIC=true TARGET_BUILD_VARIANT=userdebug
Change-Id: I72f680c27b58a42b9fb9de1a0bc4187cabcfb516

2 years agoError if a Soong module attempts to install a classes jar
Colin Cross [Mon, 14 Jan 2019 20:49:24 +0000 (12:49 -0800)]
Error if a Soong module attempts to install a classes jar

Only dex jars should be installed, make it an error to not provide
a dex jar for an device installable java module.

Bug: 122831369
Test: m checkbuild
Change-Id: I99c5738e6053fbaa3dd22406f50b7a002555702c

2 years agoMerge "releasetools: OutputFile stages files under input dir."
Treehugger Robot [Mon, 14 Jan 2019 19:02:12 +0000 (19:02 +0000)]
Merge "releasetools: OutputFile stages files under input dir."

2 years agoAdd viewcompiler to device
Eric Holk [Fri, 11 Jan 2019 22:14:11 +0000 (14:14 -0800)]
Add viewcompiler to device

This is needed so that we can generate precompiled layouts at app
install time.

Bug: 111895153

Change-Id: Ia2905fdcecc1517e6ae2c8dd4317e3a41ebee107

2 years agoRemove myself from OWNER file
Nan Zhang [Mon, 14 Jan 2019 18:23:25 +0000 (10:23 -0800)]
Remove myself from OWNER file

Test: N/A
Change-Id: I6d8b253c1333c27c6a059581e280b8b3c222efc1

2 years agoRevert "Relax inode usage estimation slack for DAP right sizing"
Mark Salyzyn [Tue, 8 Jan 2019 16:17:46 +0000 (08:17 -0800)]
Revert "Relax inode usage estimation slack for DAP right sizing"

This reverts commit bd17fab26048d9469fd6d857517d77a81e9b1d74.

Test: build
Bug: 122328872
Change-Id: I6457933a0dc51827bd86d9c55b02a65999612bcc

2 years agoRevert "Increase slack for inode estimation algorithm"
Hridya Valsaraju [Fri, 4 Jan 2019 01:19:50 +0000 (17:19 -0800)]
Revert "Increase slack for inode estimation algorithm"

This reverts commit e8e7958c13a18c1a381fe7ac0f4df36a80ef05ad.

Test: build
Bug: 122328872
Change-Id: I955aa0fa489ab62ec1643127d106925dcb9675ca

2 years agoMerge "No longer honor `DONT_INCLUDE_RUNTIME_APEX`."
Roland Levillain [Mon, 14 Jan 2019 17:40:56 +0000 (17:40 +0000)]
Merge "No longer honor `DONT_INCLUDE_RUNTIME_APEX`."

2 years agoRevert "Add core-simple to the standard boot classpath"
Neil Fuller [Fri, 9 Nov 2018 15:57:35 +0000 (15:57 +0000)]
Revert "Add core-simple to the standard boot classpath"

This reverts commit e85777782a56ff8feb7f2c06a552a3e017511b55.

Bug: 119301609
Test: build
Change-Id: Ibf9f9f56a6027a4cc3f3ea5a34b3dee748ad83c2

2 years agoNo longer honor `DONT_INCLUDE_RUNTIME_APEX`.
Roland Levillain [Mon, 14 Jan 2019 15:23:48 +0000 (15:23 +0000)]
No longer honor `DONT_INCLUDE_RUNTIME_APEX`.

The Android Runtime APEX is always included on all products.

Test: make systemimage on marlin-userdebug
Test: make systemimage on sailfish-userdebug
Bug: 113373927
Change-Id: I47b02ee44562b8da17bd960825a3489572018d93

2 years agoMerge "Remove conscrypt from boot image."
Nicolas Geoffray [Mon, 14 Jan 2019 08:31:05 +0000 (08:31 +0000)]
Merge "Remove conscrypt from boot image."

2 years agoreleasetools: OutputFile stages files under input dir.
Tao Bao [Mon, 14 Jan 2019 07:23:01 +0000 (23:23 -0800)]
releasetools: OutputFile stages files under input dir.

We used to create the intermediate output file as a tempfile, when
adding images to a given zip file. This CL changes OutputFile to write
intermediate files under the given input dir (i.e. OPTIONS.input_tmp
that holds the unzipped files), if the final destination is a zip
archive. This allows image building codes finding the generated images
at consistent locations. The intermediate files will be cleaned up as
part of OPTIONS.input_tmp.

Bug: 122608028
Test: `m dist`
Test: Delete OTA/super*.img from a target_files.zip. Run
      `add_img_to_target_files.py -a` that re-generates split super
      images.
Change-Id: I97903a59fcc0ca5e43bb9b07c3a0b25e9baa92f9

2 years agoAdd IBluetoothAudio HAL 2.0 to VNDK
Cheney Ni [Sat, 27 Oct 2018 06:14:52 +0000 (14:14 +0800)]
Add IBluetoothAudio HAL 2.0 to VNDK

Bug: 111519504
Test: build & boot

Change-Id: I4247b67709a68f26c670371e6a3407171988dcf4
Merged-In: I4247b67709a68f26c670371e6a3407171988dcf4
(cherry picked from commit b7e100c6be19b111381c0fa45a201f5f7cf3128b)

2 years agoMerge "Make get-file-size compatible with toybox stat"
Treehugger Robot [Sat, 12 Jan 2019 22:28:18 +0000 (22:28 +0000)]
Merge "Make get-file-size compatible with toybox stat"

2 years agoMerge "Rename ANS to ONS"
Sooraj Sasindran [Sat, 12 Jan 2019 19:11:53 +0000 (19:11 +0000)]
Merge "Rename ANS to ONS"

2 years agoMake get-file-size compatible with toybox stat
Luca Stefani [Sat, 12 Jan 2019 18:13:06 +0000 (19:13 +0100)]
Make get-file-size compatible with toybox stat

* Use the same format as mk_qemu_image.sh

Change-Id: I5df23f488006440075a00798a171f7a8856e097a

2 years agoMerge "Fix possible incremental build issue"
Treehugger Robot [Sat, 12 Jan 2019 06:23:31 +0000 (06:23 +0000)]
Merge "Fix possible incremental build issue"

2 years agoMerge "Fix size check for devices with multiple groups"
Treehugger Robot [Sat, 12 Jan 2019 05:59:30 +0000 (05:59 +0000)]
Merge "Fix size check for devices with multiple groups"

2 years agoMerge "Update acloud alias to support mac via workaround in go/acloud-mac."
Treehugger Robot [Sat, 12 Jan 2019 05:16:35 +0000 (05:16 +0000)]
Merge "Update acloud alias to support mac via workaround in go/acloud-mac."

2 years agoFix possible incremental build issue
Dan Willemsen [Sat, 12 Jan 2019 03:40:01 +0000 (19:40 -0800)]
Fix possible incremental build issue

We tried to start using toybox's sed, but it produced invalid results
with one of init's genrules. Clear out that generated code to fix future
incremental builds, since we don't rebuild everything on a $PATH change.

Bug: 122744241
Test: generate bad file, remove toybox sed, apply this change
Change-Id: I197aa4b68b2fe309b3033e8736e1d80c8ded80ad

2 years agoMerge "releasetools: Skip copying split super images while signing."
Tao Bao [Fri, 11 Jan 2019 23:18:49 +0000 (23:18 +0000)]
Merge "releasetools: Skip copying split super images while signing."

2 years agoMerge "releasetools: Update OWNERS."
Tao Bao [Fri, 11 Jan 2019 23:09:28 +0000 (23:09 +0000)]
Merge "releasetools: Update OWNERS."

2 years agoMerge "Deprecate USER in favor of BUILD_USERNAME"
Treehugger Robot [Fri, 11 Jan 2019 22:32:57 +0000 (22:32 +0000)]
Merge "Deprecate USER in favor of BUILD_USERNAME"

2 years agoFix size check for devices with multiple groups
Yifan Hong [Fri, 11 Jan 2019 21:20:52 +0000 (13:20 -0800)]
Fix size check for devices with multiple groups

The old code calls check-sum-of-partition-sizes within a foreach
loop, causing syntax error:
... fi partition_size_list=...

Add a semicolon after fi to fix this.
Test: build with multiple groups, each group with a partition in it

Change-Id: Ic4387408f3efc1744871619c300546765c678a61

2 years agoreleasetools: Skip copying split super images while signing.
Tao Bao [Fri, 11 Jan 2019 20:37:35 +0000 (12:37 -0800)]
releasetools: Skip copying split super images while signing.

Bug: 122608028
Test: Run sign_target_files_apks.py on a target-files zip that has split
      super images (e.g. OTA/super_system.img).
Change-Id: Iaf7263790961a897ea3f339f5af6b18cf253b946

2 years agoMerge "Revert "Add $(PRODUCT_OUT)/apex to the artifact path whitelist""
Michael Butler [Fri, 11 Jan 2019 20:37:55 +0000 (20:37 +0000)]
Merge "Revert "Add $(PRODUCT_OUT)/apex to the artifact path whitelist""

2 years agoreleasetools: Update OWNERS.
Tao Bao [Fri, 11 Jan 2019 20:28:09 +0000 (12:28 -0800)]
releasetools: Update OWNERS.

Test: N/A
Change-Id: I0c6ac3cd04cc6034787d4b8b90fbd61349c54655

2 years agoRevert "Add $(PRODUCT_OUT)/apex to the artifact path whitelist"
Michael Butler [Fri, 11 Jan 2019 20:24:25 +0000 (20:24 +0000)]
Revert "Add $(PRODUCT_OUT)/apex to the artifact path whitelist"

This reverts commit 3387e656861ebfaea8a1216674965ba13dcbbad3.

Reason for revert: Topic likely causing build failure on aosp_x86_64-eng in aosp_master:

"build/make/core/base_rules.mk:271: error: art/build/apex: MODULE.TARGET.SHARED_LIBRARIES.com.android.runtime.host.libart-compiler already defined by art/build/apex."

Change-Id: I2033828e7a13062b72d1d66a7f289cf5bb12b776

2 years agoUpdate acloud alias to support mac via workaround in go/acloud-mac.
Kevin Cheng [Mon, 3 Dec 2018 09:01:27 +0000 (01:01 -0800)]
Update acloud alias to support mac via workaround in go/acloud-mac.

Bug: 113557161
Test: acloud on mac, (m acloud and running prebuilt)
Change-Id: Iee6abb6751e8b265dfffdf9c425f073443db2531

2 years agoMerge "Support kryo385 CPU."
Roland Levillain [Fri, 11 Jan 2019 18:41:11 +0000 (18:41 +0000)]
Merge "Support kryo385 CPU."

2 years agoRename ANS to ONS
Sooraj Sasindran [Thu, 10 Jan 2019 22:19:11 +0000 (14:19 -0800)]
Rename ANS to ONS

Rename ANS to ONS
Bug: 118347827
Test: compile

Merged-In: Id01f0fc595e736f081d97309f62426cc54ac9e94
Change-Id: Id01f0fc595e736f081d97309f62426cc54ac9e94

2 years agoMerge "Add $(PRODUCT_OUT)/apex to the artifact path whitelist"
Treehugger Robot [Fri, 11 Jan 2019 17:43:16 +0000 (17:43 +0000)]
Merge "Add $(PRODUCT_OUT)/apex to the artifact path whitelist"

2 years agoMerge "Remove Goma resource check code."
Treehugger Robot [Fri, 11 Jan 2019 17:31:06 +0000 (17:31 +0000)]
Merge "Remove Goma resource check code."

2 years agoMerge changes Ic8ef968e,I6665bd6f
Treehugger Robot [Fri, 11 Jan 2019 17:17:20 +0000 (17:17 +0000)]
Merge changes Ic8ef968e,I6665bd6f

* changes:
  build_image: support non-sparse right-sized images
  build_image: right-sizing add .2% margin for space and inodes

2 years agoMerge "Install bootstrap variant of bionic libs"
Treehugger Robot [Fri, 11 Jan 2019 16:59:15 +0000 (16:59 +0000)]
Merge "Install bootstrap variant of bionic libs"

2 years agoRemove conscrypt from boot image.
Vladimir Marko [Fri, 21 Dec 2018 15:53:17 +0000 (15:53 +0000)]
Remove conscrypt from boot image.

But keep it as part of the boot class path and deliver the
dex files uncompressed in /system/framework/conscrypt.jar.

Test: Pixel 2 XL boots.
Bug: 119868597
Change-Id: I41b96a586401d120998be5a111331935030922c6

2 years agoRemove Goma resource check code.
Yoshisato Yanagisawa [Fri, 11 Jan 2019 08:07:58 +0000 (17:07 +0900)]
Remove Goma resource check code.

Since resource check has been done in Soong, we do not need that
here.

Bug: 118390303
Test: treehugger
Change-Id: Ib9d0862c65c6dc6e7fd7563995a9a335b3185786
Signed-off-by: Yoshisato Yanagisawa <yyanagisawa@google.com>
2 years agoInstall bootstrap variant of bionic libs
Jiyong Park [Wed, 26 Dec 2018 08:32:56 +0000 (17:32 +0900)]
Install bootstrap variant of bionic libs

Bionic libs are moved to the runtime APEX and thus are available via the
path /apex/com.android.runtime/lib[64]. However, for processes that are
started before the APEX is ready, a copy of the bionic libs should be left
under /system/lib[64]. This change ensures that the bootstrap bionic
libs are always installed to the system partition.

Note that, at runtime, the bionic libs in the runtime APEX are
bind-mounted to /system/lib/<libname>.so which essentially hides the
bootstrap bionic libs to the processes after the activation of the
runtime APEX.

Bug: 120266448
Test: m and check that libc, libdl, libm are under
/system/lib[64]

Change-Id: I9d5e8e718aa020c012f312a70ed54652130048dd

2 years agoAdd $(PRODUCT_OUT)/apex to the artifact path whitelist
Jiyong Park [Sun, 16 Dec 2018 02:02:09 +0000 (11:02 +0900)]
Add $(PRODUCT_OUT)/apex to the artifact path whitelist

$(PRODUCT_OUT)/apex is where shared libraries in APEXes get installed
into. The path can be considered as a fake path as the shared libraries
are installed there just to have symbol files for them under
$(PRODUCT_OUT)/symbols/apex for debugging purpose. Shared libraries in
APEXes are made available to the path at runtime by mounting APEXes via
apexd. The files under $(PRODUCT_OUT)/apex are never compiled into a
file system image (e.g. system.img)

Bug: 120846816
Test: build/soong/build_test.bash -dist -products mainline_system_arm64
Change-Id: I3727091214f08f945559fa5f0f1450e74c1a5c9b

2 years agoMerge "Dump and enforce certificate for apks"
Jeongik Cha [Fri, 11 Jan 2019 04:31:02 +0000 (04:31 +0000)]
Merge "Dump and enforce certificate for apks"

2 years agoMerge changes I68c8a566,Ib8a588e5
Treehugger Robot [Fri, 11 Jan 2019 04:29:49 +0000 (04:29 +0000)]
Merge changes I68c8a566,Ib8a588e5

* changes:
  All all_objects to LOCAL_INTERMEDIATE_TARGETS
  Reorder binary.mk to move LOCAL_INTERMEDIATE_TARGETS later

2 years agoMerge "Remove ExactCalculator module"
Treehugger Robot [Fri, 11 Jan 2019 03:14:39 +0000 (03:14 +0000)]
Merge "Remove ExactCalculator module"

2 years agoMerge "build_image: hard code set inode size to 256"
Treehugger Robot [Fri, 11 Jan 2019 02:01:22 +0000 (02:01 +0000)]
Merge "build_image: hard code set inode size to 256"

2 years agobuild_image: support non-sparse right-sized images
Mark Salyzyn [Thu, 10 Jan 2019 22:30:51 +0000 (14:30 -0800)]
build_image: support non-sparse right-sized images

Allow right-size to support images that are not sparse.
This is in support of cuttlefish.

Test: build
Bug: 122328872
Change-Id: Ic8ef968e750203dffde7044bc6dfc71c1e283158

2 years agobuild_image: right-sizing add .2% margin for space and inodes
Mark Salyzyn [Thu, 10 Jan 2019 16:36:34 +0000 (08:36 -0800)]
build_image: right-sizing add .2% margin for space and inodes

To address flakiness in image creation, add a .2% margin of safety
for both inodes and space for ext filesystems.

Test: build
Bug: 122328872
Change-Id: I6665bd6fe642291b825dba58dfd09cc55628230f

2 years agobuild_image: hard code set inode size to 256
Mark Salyzyn [Tue, 8 Jan 2019 18:08:04 +0000 (10:08 -0800)]
build_image: hard code set inode size to 256

inode-size will jump around based on filesystem size, however
readonly Android system partitions have a specific pattern of
xattr associated with sepolicy and 256 is the most efficient at
absorbing the content.

Test: manual
Bug: 122328872
Change-Id: I06dd6a503067ab6477293b386d56a89dd86b0e83

2 years agoMerge "Add BUILD_USERNAME and BUILD_HOSTNAME"
Treehugger Robot [Thu, 10 Jan 2019 21:29:47 +0000 (21:29 +0000)]
Merge "Add BUILD_USERNAME and BUILD_HOSTNAME"

2 years agoMerge "Use NEON for CTS/SDK/VTS builds too (64-bit edition)."
Elliott Hughes [Thu, 10 Jan 2019 21:23:03 +0000 (21:23 +0000)]
Merge "Use NEON for CTS/SDK/VTS builds too (64-bit edition)."

2 years agoAll all_objects to LOCAL_INTERMEDIATE_TARGETS
Dan Willemsen [Thu, 10 Jan 2019 21:21:07 +0000 (13:21 -0800)]
All all_objects to LOCAL_INTERMEDIATE_TARGETS

This fixes the WITH_TIDY flakes that we've been seeing, as we've been
relying on a particular order of target-specific variable inheritance.

Change-Id: I68c8a56620c29a41e45f26e5ea81a5313490c1cf
Fixes: 122637600
Test: WITH_TIDY=true m libhellojni_jni

2 years agoReorder binary.mk to move LOCAL_INTERMEDIATE_TARGETS later
Dan Willemsen [Thu, 10 Jan 2019 21:10:17 +0000 (13:10 -0800)]
Reorder binary.mk to move LOCAL_INTERMEDIATE_TARGETS later

I'll be adding more intermediate targets in this file, so move all of
the uses closer to the end.

Bug: 122637600
Test: build-aosp_arm64.ninja is the same before and after
Change-Id: Ib8a588e570cb2a61bab75118db6e480d6afceaa8

2 years agoMerge "Remove code to start Goma compiler_proxy."
Treehugger Robot [Thu, 10 Jan 2019 19:24:03 +0000 (19:24 +0000)]
Merge "Remove code to start Goma compiler_proxy."

2 years agoMerge "Stop trying to read depfile from vtsc"
Treehugger Robot [Thu, 10 Jan 2019 17:46:34 +0000 (17:46 +0000)]
Merge "Stop trying to read depfile from vtsc"

2 years agoUse NEON for CTS/SDK/VTS builds too (64-bit edition).
Elliott Hughes [Thu, 10 Jan 2019 16:53:38 +0000 (08:53 -0800)]
Use NEON for CTS/SDK/VTS builds too (64-bit edition).

It's 2019 and the CDD has required NEON for many years now.

I've left unbundled apps alone for now.

I think the recent fix here for https://issuetracker.google.com/116070933
was incorrect. (I've commented on the bug.)

Test: treehugger
Change-Id: Ia02305cfdff9fd18a85359bc44d8eb9cab1413bd

2 years agoMerge "Use NEON for CTS and SDK builds too."
Elliott Hughes [Thu, 10 Jan 2019 16:39:41 +0000 (16:39 +0000)]
Merge "Use NEON for CTS and SDK builds too."

2 years agoMerge "Enable mini-debug-info for JITed methods by default."
David Srbecky [Thu, 10 Jan 2019 13:24:24 +0000 (13:24 +0000)]
Merge "Enable mini-debug-info for JITed methods by default."

2 years agoMerge "Support LOCAL_DEX_PREOPT := nostripping"
Treehugger Robot [Thu, 10 Jan 2019 08:58:01 +0000 (08:58 +0000)]
Merge "Support LOCAL_DEX_PREOPT := nostripping"

2 years agoMerge "Add 'dmctl' to default debug utilities."
Treehugger Robot [Thu, 10 Jan 2019 07:10:06 +0000 (07:10 +0000)]
Merge "Add 'dmctl' to default debug utilities."

2 years agoRemove ExactCalculator module
Justin Klaassen [Wed, 12 Dec 2018 17:23:09 +0000 (09:23 -0800)]
Remove ExactCalculator module

Individual products can add their own calculator package if desired.

Bug: 120905067
Test: lunch aosp_arm64 && make -j8
Merged-In: I60490b6e2a42c4304768075e8fef9f07cb72d268
Change-Id: I60490b6e2a42c4304768075e8fef9f07cb72d268

2 years agoRemove code to start Goma compiler_proxy.
Yoshisato Yanagisawa [Thu, 10 Jan 2019 04:58:33 +0000 (13:58 +0900)]
Remove code to start Goma compiler_proxy.

Since the code to start compiler proxy is implemented in soong now
(https://android-review.googlesource.com/c/platform/build/soong/+/839293).
We do not need to do that in goma.mk.

Bug: 118390303
Test: After staring goma client, executed followings:
Test: USE_GOMA=true make -j 4
Change-Id: If3da9908483e183f539c0d6ef9dc5826200b0d6b
Signed-off-by: Yoshisato Yanagisawa <yyanagisawa@google.com>
2 years agoSupport LOCAL_DEX_PREOPT := nostripping
Colin Cross [Thu, 10 Jan 2019 05:27:53 +0000 (21:27 -0800)]
Support LOCAL_DEX_PREOPT := nostripping

Support LOCAL_DEX_PREOPT := nostripping by passing it to
dexpreopt_gen.

Bug: 122610462
Test: m
Change-Id: I05f7009d38505f995cd16cc8dbb4ecd6ecc3d71c

2 years agoMerge "Fix Legacy GSI settings for BoardConfigGsiCommon.mk"
Treehugger Robot [Thu, 10 Jan 2019 03:13:57 +0000 (03:13 +0000)]
Merge "Fix Legacy GSI settings for BoardConfigGsiCommon.mk"

2 years agoDump and enforce certificate for apks
Jeongik Cha [Mon, 17 Dec 2018 05:45:15 +0000 (14:45 +0900)]
Dump and enforce certificate for apks

Dump the list of APKs that aren't located at system partition and signed
with system certificate.
And when enforcement option is enabled, it makes build error if there is
the apk that satisfies the condition above.

Bug: 74699609

Test: m -j
Test: m out/target/product/$(get_build_var TARGET_DEVICE)/certificate_violation_modules.txt

Change-Id: I23c41f2665dd97abac3e77d1c82d81ff91b894eb

2 years agoFix Legacy GSI settings for BoardConfigGsiCommon.mk
SzuWei Lin [Wed, 9 Jan 2019 07:42:36 +0000 (15:42 +0800)]
Fix Legacy GSI settings for BoardConfigGsiCommon.mk

Legacy GSI had been changed to include BoardConfigGsiCommon.mk
instead of treble_common*.mk. However, some default settings are
different than the original. This patch fixes
BOARD_BUILD_SYSTEM_ROOT_IMAGE in Legacy GSI makefiles.

The patch also removes redundant settings and fix some comments.

Bug: 122282239
Test: make
Change-Id: Ie4eb8cf410bfd2edc74648c0e5ee81028242a1b7

2 years agoStop trying to read depfile from vtsc
Dan Willemsen [Wed, 9 Jan 2019 20:48:17 +0000 (12:48 -0800)]
Stop trying to read depfile from vtsc

vtsc just ignores the -d argument and apparently can't write a depfile.
So for now, just stop assuming it produces one.

Bug: 121058584
Bug: 120496070
Test: NINJA_ARGS="-w missingdepfile=err" m libvts_interfacespecification
Change-Id: Ie1483fbeead9f710d8a6636df07ce44bbc4a6e2d

2 years agoMerge "Add PRODUCT_MANIFEST_PACKAGE_NAME_OVERRIDES"
Jiyong Park [Wed, 9 Jan 2019 23:33:51 +0000 (23:33 +0000)]
Merge "Add PRODUCT_MANIFEST_PACKAGE_NAME_OVERRIDES"

2 years agoUse NEON for CTS and SDK builds too.
Elliott Hughes [Wed, 9 Jan 2019 18:59:44 +0000 (10:59 -0800)]
Use NEON for CTS and SDK builds too.

It's 2019 and the CDD has required NEON for many years now.

I've left unbundled apps alone for now.

Test: treehugger
Change-Id: Iee22d4605a81e2840063a203b76db7df5b4f3c37

2 years agoEnable mini-debug-info for JITed methods by default.
David Srbecky [Tue, 8 Jan 2019 17:02:14 +0000 (17:02 +0000)]
Enable mini-debug-info for JITed methods by default.

Generate and store minimum amount of information necessary to
create backtraces in native tools (for crashes and profilers).

The data is compressed and takes <5% relative to JIT code size
(which is less than recent stack map savings; so win overall).

Averages for non-compiled run of maps which filled JIT code cache to ~4MB:
Q: code:1.55kb/method data:0.738kb/method debug:0.064kb/method(*this CL*)
P: code:1.62kb/method data:0.956kb/method debug:0.835kb/method(if enabled)

I also measured the P to Q on-disk stack maps savings in CL/762841 as ~28%
(not all of that is applicable to JITed code, so that is an overestimate).

Bug: 111350693
Test: Device boots, mini-debug-info is generated.
Change-Id: I95883bd4f2d5c2308149ab0ba641b0a703c7f81b

2 years agoMerge "Preopt: Pass -Xbootclasspath: arg to dex2oat."
Nicolas Geoffray [Wed, 9 Jan 2019 12:37:15 +0000 (12:37 +0000)]
Merge "Preopt: Pass -Xbootclasspath: arg to dex2oat."

2 years agoAdd PRODUCT_MANIFEST_PACKAGE_NAME_OVERRIDES
Jiyong Park [Sat, 5 Jan 2019 03:57:54 +0000 (12:57 +0900)]
Add PRODUCT_MANIFEST_PACKAGE_NAME_OVERRIDES

It is a list of <module_name>:<manifest_name> pairs. When the module
name of an APK or an APEX matches with <module_name>, then its app
manifest name is overridden to <manifest_name>.

<module_name> and <manifest_name> can be patterns as in
com.android.%:com.mycompany.android.%.release

Test: m with PRODUCT_MANIFEST_PACKAGE_NAME_OVERRIDES for
1) an APK in Android.mk
2) an APK in ANdroid.bp
3) an APEX
and check that manifest names are modified as specified

Change-Id: Ic09e059ea7b7ea99a50a1cf423a25aa587ef4466

2 years agoMerge "Fix qemu image definition conditionals"
Anton Hansson [Wed, 9 Jan 2019 10:33:51 +0000 (10:33 +0000)]
Merge "Fix qemu image definition conditionals"

2 years agoMerge "Refactor GSI BoardConfig.mk"
Treehugger Robot [Wed, 9 Jan 2019 06:05:41 +0000 (06:05 +0000)]
Merge "Refactor GSI BoardConfig.mk"

2 years agoMerge "Add android.hardware.power.stats@1.0 to current.txt"
Benjamin Schwartz [Tue, 8 Jan 2019 17:58:59 +0000 (17:58 +0000)]
Merge "Add android.hardware.power.stats@1.0 to current.txt"

2 years agoMerge "Move overridden AOSP modules out of *_system mks"
Anton Hansson [Tue, 8 Jan 2019 16:20:47 +0000 (16:20 +0000)]
Merge "Move overridden AOSP modules out of *_system mks"

2 years agoMerge "Add adb_keys to mainline_system if they exist"
Anton Hansson [Tue, 8 Jan 2019 11:40:25 +0000 (11:40 +0000)]
Merge "Add adb_keys to mainline_system if they exist"