Commit graph

39699 commits

Author SHA1 Message Date
Dan Willemsen
79fd696939 Switch unused deprecated variables to obsolete
These have no references in our master trees, so can now be marked as
obsolete.

Test: grep -R "<VAR> has been" <all build_test logs>
Change-Id: I72d2371176e78f38ed56741dd8527193eec7eae3
2017-11-29 13:44:32 -08:00
Jeff Gaston
1fe28d332e Export PRODUCT_SOONG_NAMESPACES to Soong
Bug: 65683273
Test: put 'PRODUCT_SOONG_NAMESPACES := jeff-test/dir1' \
      in a .mk file and observe its value copied into \
      out/soong/soong.variables

Change-Id: I2b61caa46f40f35ccecf64da88918b73180e02e8
2017-11-29 13:17:13 -08:00
Treehugger Robot
ada8948b9a Merge "Add local compatibilty suite info to module-info.json." 2017-11-29 20:20:25 +00:00
Treehugger Robot
8552bebed4 Merge "Reorder assert-max-image-size and AVB signing" 2017-11-29 09:10:27 +00:00
Treehugger Robot
047aab7c3b Merge "Include vbmeta.img into <product>-img.zip" 2017-11-29 08:26:24 +00:00
Bowgo Tsai
6a74979a3b Include vbmeta.img into <product>-img.zip
Bug: 65227202
Test: make dist, checks vbmeta.img is included in <product>-img.zip
Merged-In: I3e09f036441bcf7e98d8f76360df1e17466ae38e
Change-Id: I3e09f036441bcf7e98d8f76360df1e17466ae38e
(cherry picked from commit 6bbb11a620)
2017-11-29 16:14:19 +09:00
Treehugger Robot
52a4f7d2b7 Merge "Support prebuilt bootimage" 2017-11-29 04:44:20 +00:00
Treehugger Robot
d7fcf6f459 Merge "Mark envsetup.sh vars as deprecated in makefiles" 2017-11-29 03:06:32 +00:00
Kevin Cheng
2260918434 Add local compatibilty suite info to module-info.json.
Test: m out/target/product/<lunch target>/module-info.json
And I see the following line in module-info.json:

"CtsSampleHostTestCases": { "class": ["JAVA_LIBRARIES"],  "path":
["cts/hostsidetests/sample"],  "tags": ["tests"],  "installed":
["out/host/linux-x86/framework/CtsSampleHostTestCases.jar"],
"compatibility_suites": ["cts",  "general-tests",  "vts"] },

Change-Id: I67a78de4153c762977b145ed62ca8b6ecd0b7947
2017-11-28 15:27:04 -08:00
Jayant Chowdhary
824958e880 Merge "Export DIST_DIR to soong on dist builds." 2017-11-28 22:38:32 +00:00
Dan Willemsen
773386251d Mark envsetup.sh vars as deprecated in makefiles
For the envsetup.sh variables that should not be used in makefiles
(since they're not explicitly set up, and won't be available on the
build servers), mark them as deprecated.

Rework our documentation to have a landing page, and create a "Changes"
section where we can record changes like these. At some point I may go
and backfill some recent work.

Test: build/soong/build_test.bash
Change-Id: I54b9294ddf270245afdb58d17150db8098584e8a
2017-11-28 14:19:50 -08:00
Colin Cross
9798690282 Merge "Add support for jacoco in soong" 2017-11-28 21:10:57 +00:00
Treehugger Robot
edd5f3810f Merge "Add LOCAL_SRCJARS to clear_vars.mk" 2017-11-28 19:37:29 +00:00
Jayant Chowdhary
85fbcf4a68 Export DIST_DIR to soong on dist builds.
Bug: 64267858

Test: Adding DistDir to build/soong/android/variable.go enables access
      to DIST_DIR_SOONG.

Change-Id: I74faea11255edf37db6a4eaf193df300c363bfb7
2017-11-28 11:26:24 -08:00
Michael Schwartz
0dc6f21779 Support prebuilt bootimage
Bug: 63676296
Test: `m -j` and inspect artifacts
Merged-In: Id32d8a7151a8e99b45aa58ee9971def9734eaf78
Change-Id: Id32d8a7151a8e99b45aa58ee9971def9734eaf78
(cherry picked from commit b0b1a24b1e)
2017-11-28 20:18:34 +09:00
Treehugger Robot
a4fae6e3e4 Merge "add llndk|vndksp.libraries.txt to vndk_package" 2017-11-28 01:48:42 +00:00
Colin Cross
3fec81d978 Add support for jacoco in soong
Use jacoco values exported from soong and copy
jacoco-report-classes.jar to where the jacoco-report-classes-all.jar
rule can find it.

Bug: 69629238
Test: m EMMA_INSTRUMENT=true EMMA_INSTRUMENT_FRAMEWORK=true SKIP_BOOT_JARS_CHECK=true WITH_DEXPREOPT=false
Change-Id: If05381f415fb52a575746b8be0bfcd03d55b2153
2017-11-24 20:23:36 -08:00
Colin Cross
98341ab6d6 Add LOCAL_SRCJARS to clear_vars.mk
I064889c9063b642835d9f668e2568b61d0fabe35 added LOCAL_SRCJARS but
forgot to clear it in clear_vars.mk.

Test: m checkbuild
Change-Id: I7d4e6a3821db0eccb25042091aa599cab381a1b0
2017-11-24 11:26:43 -08:00
Jiyong Park
0845cb5c98 add llndk|vndksp.libraries.txt to vndk_package
Bug: 64882323
Test: build 2017 pixel devices. check the files are under /system/etc.

Merged-In: I488427f796b770bb2d151cfa49f73d323cafbc9f
Change-Id: I488427f796b770bb2d151cfa49f73d323cafbc9f
(cherry picked from commit 686aff5b91)
2017-11-23 14:35:04 +09:00
Treehugger Robot
87dded4494 Merge "Build: Make dex2oat boot image error abort explicit" 2017-11-23 01:56:06 +00:00
Colin Cross
711bfabd50 Merge "Tighten restrictions on LOCAL_JACK_COVERAGE_(INCLUDE|EXCLUDE)_FILTER" 2017-11-22 22:30:18 +00:00
Andreas Gampe
5ccf0900d0 Build: Make dex2oat boot image error abort explicit
Add explicit arguments that will abort boot image compilation when
a class is found that fails compile-time verification.

This allows certain configurations to disable these checks.

WARNING: Disabling the checks is highly discouraged.

Bug: 69106371
Test: m
Change-Id: I63e915005fcda588b223ec60ef8c9db28d42e577
2017-11-22 14:16:24 -08:00
Tianjie Xu
41390d4e1e Improve the comment in AddSplitTransfers
Bug: 69624507
Test: build an incremental package
Change-Id: I54dac0a2ddcc19b722e352fb19d53ff20444fa42
2017-11-22 11:35:18 -08:00
Tianjie Xu
520c9f0f5f Merge "Fall back to normal split if imgdiff fails when splitting large apks" 2017-11-22 18:28:31 +00:00
Bowgo Tsai
03b9c8e637 Reorder assert-max-image-size and AVB signing
This change fixes the following warning message:
  WARNING: out/target/product/$(TARGET_DEVICE)/boot.img approaching \
  size limit (33554432 now; limit 33554432)

This is because AVB signing will increase boot.img to
BOARD_BOOTIMAGE_PARTITION_SIZE, in order to place the AVB metadata at
the end of the partition. We should check max image size first then use
avbtool to sign it.

The max allowed size will be (partition size - AVB_HASH_META_SIZE) when
AVB is enabled.

Note that some projects don't have BOARD_{BOOT,RECOVERY}IMAGE_PARTITION_SIZE,
we should skip assert-max-image-size for it.

Finally, this CL also fixes the build error for `make bootimage-nodeps`
when AVB is used.

Bug: 69115400
Test: build and checks there is no size limit warning message
Change-Id: I54f28c6f1c9fe9ed88c1d73e5cb72b3693593f9b
2017-11-22 17:46:33 +08:00
Tianjie Xu
f68b50f963 Fall back to normal split if imgdiff fails when splitting large apks
Imgdiff expects the input files to be valid zip archives. During the
split of large apks, imgdiff may fail when there's a hole in the input
file; potentially due to the blocks allocation of mke2fs. This CL solves
the issue by falling back to normal split in case of the imgdiff split
failure. The split transfers will then use bsdiff instead.

Bug: 69624507
Test: generate the incremental package for the failed targets and check the
transfers.
Change-Id: I4882452378123e60ad3434053b57f33e53ac4b82
2017-11-21 23:37:36 -08:00
Colin Cross
3c8d30ce60 Tighten restrictions on LOCAL_JACK_COVERAGE_(INCLUDE|EXCLUDE)_FILTER
Jack supported '?' and '*' wildcards anywhere in a filter. Tighten
the restrictions to only support '*' at the end of a filter, and
to disallow '?'.  This will allow jacoco support to be built on
top of the existing zip2zip tools.

Add checks that all filters meet the new requirements, and run
the checks outside the LOCAL_EMMA_INSTRUMENT==true check so that
mistakes can be caught without having to run a build with
coverage enabled.

Bug: 69629238
Test: m EMMA_INSTRUMENT=true EMMA_INSTRUMENT_STATIC=true
Test: m in internal master
Test: https://android-build.googleplex.com/builds/view-workplan?viewType=Table&workplanId=L67200000122054710&nodeType=Trybot
Change-Id: Ib78bd3c8685fbc6bdcdb517df874186efd1cff33
2017-11-22 01:49:47 +00:00
Tomasz Wasilczyk
01e1fe60b8 Merge "Silence yet more superfluous build messages." 2017-11-22 01:20:32 +00:00
Treehugger Robot
061fcfc254 Merge "Use the .cfi variant of a static library where needed." 2017-11-22 00:05:30 +00:00
Vishwath Mohan
96a130bdaf Use the .cfi variant of a static library where needed.
This CL repoints static dependencies to their .cfi variants for CFI
enabled targets. It also disables CFI for host targets because the
version of ar intended for hosts does not have plugin support (which
CFI requires).

Bug: 67507323
Test: m -j40
Change-Id: Id11afd0c8765469858f406aace2a192afff6d042
2017-11-21 14:08:20 -08:00
Treehugger Robot
9f686938da Merge "check_ota_package_signature.py: Set up PYTHONPATH." 2017-11-21 21:31:44 +00:00
Chih-hung Hsieh
6ddc7843cb Merge "Add default -Wall -Werror or -Wall." 2017-11-21 21:19:01 +00:00
Treehugger Robot
adbaeb0c1d Merge "Set the default ring buffer size for stats log, and set it loggable." 2017-11-21 19:44:56 +00:00
Tao Bao
d2ae0b0613 check_ota_package_signature.py: Set up PYTHONPATH.
... to include system/update_engine/scripts if ANDROID_BUILD_TOP is set
(e.g. after lunching a target).

Test: ./build/make/tools/releasetools/check_ota_package_signature.py
      works without manually setting PYTHONPATH.
Change-Id: I0c5101fab2dd69cb6a598b909aa04bc4d5f45284
2017-11-21 11:30:27 -08:00
Tao Bao
37066490a5 Merge "releasetools: Allow building AVB-enabled recovery.img." 2017-11-21 17:02:35 +00:00
Yao Chen
8ce8dc2efa Set the default ring buffer size for stats log, and set it loggable.
Bug: 69323063
Test: manual
Change-Id: I19de884927bc4999d503b919d851048609be1470
2017-11-21 09:02:12 -08:00
Treehugger Robot
dcbc2e9a26 Merge "Ensure partition_tag is always set correctly" 2017-11-21 04:09:21 +00:00
Colin Cross
80ec993a58 Merge "Convert signtos to Android.bp" 2017-11-21 03:26:42 +00:00
Colin Cross
3c363ad729 Convert signtos to Android.bp
See build/soong/README.md for more information.

Test: m checkbuild
Change-Id: Ia468cde0492e64858b7a603deba9b22b95e56ff4
2017-11-21 03:26:31 +00:00
Bowgo Tsai
aac41d585c Merge "Revert "Reorder assert-max-image-size and AVB signing"" 2017-11-21 03:02:19 +00:00
Bowgo Tsai
47e0b62d6e Revert "Reorder assert-max-image-size and AVB signing"
This reverts commit b855c0c304.

Change-Id: Ia82071bf42fcc6d15dabdf15f4eb5d1749c8cdb8
2017-11-21 02:39:51 +00:00
Treehugger Robot
eea732dbcf Merge "Reorder assert-max-image-size and AVB signing" 2017-11-21 01:23:28 +00:00
Treehugger Robot
c1d7537d99 Merge "Switch gcnodir name from basename to just removing .so" 2017-11-20 23:04:38 +00:00
Treehugger Robot
db7dfacb96 Merge "releasetools: Always create IMAGES/ directory." 2017-11-20 22:39:37 +00:00
Dan Willemsen
ba9badf8ec Switch gcnodir name from basename to just removing .so
$(basename) was catching all of the hidl services that have versions
like "1.0" in their name, marking the .0-service portion as a suffix to
be removed.

Instead just remove ".so" and assume that everything else isn't actually
a suffix.

Bug: 69271974
Test: NATIVE_COVERAGE=true COVERAGE_PATHS=hardware/interfaces m; compare
      ninja files
Change-Id: I76e27d9ab1f9d4862cc2607c5f2ed9c121879421
2017-11-20 13:03:25 -08:00
Tao Bao
bf70c318b7 releasetools: Allow building AVB-enabled recovery.img.
Bug: 68224784
Test: Enable AVB on aosp_bullhead-userdebug. `m dist`. Note that the
      prebuilt vendor.img needs to be AVB-signed first.
Test: `m dist` with aosp_walleye-userdebug.
Change-Id: I18235e4d0dde6af71a96e46ec434480cc9a22bef
2017-11-20 12:44:18 -08:00
Tao Bao
ae396d9b0c releasetools: Always create IMAGES/ directory.
AddImagesToTargetFiles() takes either a zip file, or a zip root as
input. We used to create IMAGES/ directory only when working with zip
root input. Commit 262bf3f0b5 has changed
to also stage boot / recovery images there when working with a zip file.
This CL makes sure the directory is always available under both modes.

Bug: 63456822
Test: zip -d target_files.zip IMAGES/\*;
      add_img_to_target_files.py target_files.zip
Test: sign_target_files_apks.py target_files.zip signed-target_files.zip
Change-Id: Iea91d0403cdec1b16bb93bb71d3ed06856b8f7c3
2017-11-20 12:44:18 -08:00
Treehugger Robot
cbf6fd55bf Merge "Make more Treble make variables read only." 2017-11-20 19:09:21 +00:00
Jiyong Park
f19117c560 Don't embed vendor libs into vendor apks.
Vendor apk can now access /vendor/lib. So there is no need for us to
embed the vendor libs into vendor apks. Reverting the old commits.

Revert "Embedding the JNI lib is controlled by PRODUCT_FULL_TREBLE"
This reverts commit a6b038ff4c.

Revert "Embed jni libs in vendor apks for treble-ized devices"
This reverts commit 1cb8dea625.

Bug: 69272876
Test: m -j ModemDiagnosticSystem (a vendor apk having JNI libs in walleye)
unzip -l /vendor/app/ModemDiagnosticSystem/ModemDiagnosticSystem.apk does not
have libmdsdiag.so in it. The so file is found in /vendor/lib64.

Change-Id: I7b96aa56b39bc45aca4810e6fb3f41ce2a1fc095
2017-11-20 11:01:54 +09:00
Jiyong Park
003ea369dd Ensure partition_tag is always set correctly
partition_tag is now set to either VENDOR_, OEM_, or ODM_
even when LOCAL_[VENDOR|OEM|ODM]_MODULE isn't set but LOCAL_MODULE_PATH
is explicitly set to under $(TARGET_OUT_[VENDOR|OEM|ODM]).

Test: build walleye

Change-Id: I0f902061889fe0af1c39f6222e54faa80dd15794
2017-11-20 11:01:50 +09:00