Commit graph

769 commits

Author SHA1 Message Date
Nan Zhang
33dcd0c5eb Revert "Add Turbine as part of java build toolchain in Make."
This reverts commit 0739155c86.

Reason for revert: <sdk_google_aw_x86-sdk (linux) build 4310016 in git_master is broken>

Change-Id: I525d48557bd0425917e61a85f596663ccc63c887
2017-08-31 19:56:59 +00:00
Nan Zhang
0739155c86 Add Turbine as part of java build toolchain in Make.
1. Bundle static_java_header_libs during turbine-classes.jar if
necessary. This can be improved if we have the ability to merge jars on
the fly.

2. Copy sdk/stubs-classes.jar to sdk/stubs-classes-header.jar, and Use
.KATI_RESTAT to cut un-necessary targets rebuilt.

3. Copy prebuilt-classes.jar to prebuilt-classes-header.jar since
Turbine doesn't apply to prebuilt.

4. Run jarjar after Turbine compilation, otherwise downstream targets
won't find corresponding symbols.

5. Change classes.jar in -classpath used in Desugar to
classes-header.jar.

6. Change legacy-libs in Proguard from classes.jar to
classes-header.jar.

7. Add .KATI_RESTAT for turbine-classes.jar, and remove IJAR.

8.boot.art is re-generated during the incremental rebuild since
javalib.jar got re-generated. Then boot.art re-triggered lots of
downstream targets to be rebuilt. So we add .KATI_RESTAT for javalib.jar
to prevent downstream to be rebuilt. The ziptime & commit-change-to-toc
operation for javalib.jar(small) didn't bring too much overhead when we build
from clean state.

Next step: specify static_java_header_libs in -classpath, and merge jars
at the end.

touch frameworks/base/core/java/com/google/android/util/Procedure.java &&
time m
time: 1m58s (794 -> 49 targets)

m clean && time m java
time: 9m34s

Bug: b/64308460

Test: m clean && m checkbuild

Change-Id: Iefcc234405b9f461b6882c06bba15e21fa783d28
2017-08-30 16:01:39 -07:00
Dan Willemsen
10e9d25035 Merge changes I863200b2,Ifdd9663b
am: 770a498e99

Change-Id: Id9e3dd9d5e8ac3d85d5203dd6430243d9daf01bf
2017-07-26 21:45:04 +00:00
Dan Willemsen
ce7f8dd15a Run uname -sm once, don't use python for HOST_OS_EXTRA
This saves 20-50ms for `lunch` (~7-10%), and double that for every build
execution.

Test: Check HOST_OS_EXTRA on Linux & Mac
Change-Id: I863200b2287c8867f40606237895b1d3ad91e1b3
2017-07-26 10:49:22 -07:00
Dan Willemsen
dc068b0762 Stop calling java -version, remove HOST_JDK_IS_64BIT_VERSION
All users of this variable have been removed. This command was adding
50-175ms to `lunch` (~15-30%), and was running at least twice (serially)
in every build too.

Test: cs/HOST_JDK_IS_64BIT_VERSION
Test: prebuilts/jdk/jdk8/linux-x86/bin/java -version, is 64-bit.
Change-Id: Ifdd9663b010ec45918b29ac037849f49c8cd8f69
2017-07-26 10:49:04 -07:00
Colin Cross
d35fe2c55e Merge "Use java prebuilts"
am: 45d2ef40f2

Change-Id: Icb9e7cd6ad37a5ff37fb72d12a058be79dbabf68
2017-07-25 00:47:17 +00:00
Colin Cross
e97e69359a Use java prebuilts
Point the make java variables at JDK prebuilts in
prebuilts/jdk/jdk8, add them to the path, and clean up
some old overrides.

Reapplies Ibbeb30fab96e45aedd5bb6d710d1170f85789982 after updating
some more manifests to include the prebuilts.

Bug: 62956999
Test: m -j checkbuild
Change-Id: I9e27aa5cb04d1ed09e43b798e5d654843afc000f
(cherry picked from commit 1931750940)
2017-07-20 15:14:26 +00:00
Colin Cross
f4e78ccf25 Merge "Revert "Use java prebuilts""
am: 4d69df5191

Change-Id: I978bf3d25e0be2a2a6b40c5b396821cc2a8d9365
2017-07-19 22:52:21 +00:00
Colin Cross
4d69df5191 Merge "Revert "Use java prebuilts"" 2017-07-19 22:44:12 +00:00
Colin Cross
02112900cc Revert "Use java prebuilts"
This reverts commit 1931750940.

Change-Id: I7a99fd6c53d35a2a674f2d60b113a727f3c453ce
2017-07-19 22:42:46 +00:00
Colin Cross
fcbaa25380 Merge "Use java prebuilts"
am: 26e1b6d6c2

Change-Id: If761856f9fd509d2c5694844b6bb10966717e0b1
2017-07-19 22:13:09 +00:00
Colin Cross
26e1b6d6c2 Merge "Use java prebuilts" 2017-07-19 22:08:48 +00:00
Colin Cross
4cea760106 Merge "Revert "Use dx.jar directly""
am: c7e3e962f8

Change-Id: Icd5402f7cc789224753537c070a91cbf6267ee66
2017-07-18 07:14:26 +00:00
Treehugger Robot
c7e3e962f8 Merge "Revert "Use dx.jar directly"" 2017-07-18 07:08:19 +00:00
Colin Cross
e44e75aa89 Revert "Use dx.jar directly"
This reverts commit e37a3c959a.

Reason for revert: breaks art test runner

Change-Id: Ice0cd3020ddec7f31eb789867a45f047a75a05d0
2017-07-18 05:22:59 +00:00
Colin Cross
4828fcad41 Merge "Use dx.jar directly"
am: c68434c971

Change-Id: Ief2c88d3ba0e93c7eb7bb9db0ac2b0a0b886bcea
2017-07-17 20:45:31 +00:00
Jeff Gaston
6264b662f3 Merge "Update to latest jacoco usage"
am: 483fae7430

Change-Id: Ibc94d5ba6db7690441825dd655b6cb26d989b78d
2017-07-17 20:44:10 +00:00
Colin Cross
c68434c971 Merge "Use dx.jar directly" 2017-07-17 20:40:13 +00:00
Jeff Gaston
483fae7430 Merge "Update to latest jacoco usage" 2017-07-17 20:36:39 +00:00
Tianjie Xu
a07a04c737 Merge "Generate brotli compressed {}.new.dat for full OTA"
am: 1b28eca1a1

Change-Id: I3474e8efb634513fbc4876e5c272cf56b3443e12
2017-07-14 23:27:21 +00:00
Colin Cross
1931750940 Use java prebuilts
Point the make java variables at JDK prebuilts in
prebuilts/jdk/jdk8, add them to the path, and clean up
some old overrides.

Bug: 62956999
Test: m -j checkbuild
Change-Id: Ibbeb30fab96e45aedd5bb6d710d1170f85789982
2017-07-14 14:18:53 -07:00
Jeff Gaston
aaae43cd24 Update to latest jacoco usage
Bug: 36792868
Test: EMMA_INSTRUMENT_STATIC=true m -j

Change-Id: I419b543283b52be9a72f5c6b10e4cbea68782174
2017-07-14 13:04:05 -07:00
Tianjie Xu
b0a29ad8c2 Generate brotli compressed {}.new.dat for full OTA
Brotli has a better compression ratio than deflation. So for non-AB
full OTA, we can compress the new.dat with brotli first and store it
in the zip package.
This increase the OTA generation time by ~5 minutes for a full OTA
(measured based on 2.0G system.new.dat)

Bug: 34220646
Test: Generate a full OTA for bullhead
Change-Id: I9c0550af8eafcfa68711f74290c8e2d05a96648f
2017-07-14 10:53:21 -07:00
Colin Cross
e37a3c959a Use dx.jar directly
Use $(JAVA) to invoke dx.jar instead of the dx wrapper script.
Also allow the dx command line or the dx jar to be specified on
the command line.  Allows better dependencies on dx.jar, and
doesn't rely on having java on the path.

Bug: 62956999
Test: m -j checkbuild
Change-Id: I5f265132690ad28b3139954fea44eb0c4a43393a
2017-07-07 13:34:33 -07:00
Colin Cross
68016fc55f Merge "Refactor prebuilt tools"
am: bc45a33c93

Change-Id: I689375970e4e4045d986b62a21f8ed7aa4e34a38
2017-07-07 20:24:15 +00:00
Colin Cross
cd20d5980c Refactor prebuilt tools
Put the prebuilt and non-prebuilt tools selections into the two
clauses of an if block to simplify the next patch.

Test: m -j checkbuild
Change-Id: Idd01bc81a2b619f7fc23df7566a01b46598433a3
2017-07-07 18:16:28 +00:00
Bryan Eyler
1558db6a87 Merge "Re-compute DX command if it changes for PDK."
am: 7edc11830a

Change-Id: Ied18008a334db388efe5d396bc3a7186f6c7e327
2017-07-07 01:32:49 +00:00
Bryan Eyler
d4794315ff Re-compute DX command if it changes for PDK.
Bug 62360631
Tested build of PDK.

Test: builds
Change-Id: I7cbd649a8a3ce4326e513d5a808b76fbb011d99e
Merged-In: I7cbd649a8a3ce4326e513d5a808b76fbb011d99e
(cherry picked from commit af4bde4239)
2017-07-06 16:22:01 -07:00
Colin Cross
e885ccf0df Merge "Provide make variables for java binaries"
am: 5e19557eb9

Change-Id: Ib1be7da98214e3b6c27867b80005e18cc68a0d33
2017-07-01 01:36:14 +00:00
Colin Cross
0851df8c82 Provide make variables for java binaries
Replace java -> $(JAVA), etc. to prepare for moving java binaries
out of the path and using full paths to them.

Test: builds
Bug: 62956999
Change-Id: I5dfcd0d4e855ecde69cd127169e9545e59723d12
2017-07-01 01:03:14 +00:00
Colin Cross
df973cb239 Merge "Get java config from soong" am: bf215d166b
am: 253ffe20e1

Change-Id: I4250672ec7cd18a4f82c3e4019a9ec418a17df11
2017-06-23 21:57:03 +00:00
Colin Cross
b12d4b7ac2 Get java config from soong
Soong will export java config variables.

Test: builds
Change-Id: If185543f8f36a30e7632946c16351d44f012bd6a
2017-06-22 17:21:05 -07:00
Mariano Giardina
78d9b75329 Merge "Revert "core: Move core.oat bootjar definitions into core/config"" am: 1e14bc3b7b
am: cc33b6005f

Change-Id: I2f7465d6bd723c85aa0c028e8e8268d631c13d02
2017-06-15 11:12:23 +00:00
Mariano Giardina
1e14bc3b7b Merge "Revert "core: Move core.oat bootjar definitions into core/config"" 2017-06-15 11:01:29 +00:00
Mariano Giardina
2f137ee118 Revert "core: Move core.oat bootjar definitions into core/config"
This reverts commit 8c50798243.

Possible culprit of breakage in git_master sdk_google_aw_x86:
FAILED: out/target/product/generic_x86/dex_bootjars/system/framework/x86/boot.art 
ex2oatd E 06-15 03:56:00 47990 47990 runtime.cc:1761] Failed to return pre-allocated NoClassDefFoundError
dex2oatd F 06-15 03:56:00 47990 47990 thread.cc:3591] Check failed: new_exception != nullptr 

Testing if Treehugger passes with the rollback before submitting

https://android-build.googleplex.com/builds/submitted/4101897/sdk_google_aw_x86-sdk/latest/view/logs/build_error.log

Change-Id: Iceac31e775eaf3cd5fd9b3d2a17d3af200e35b27
2017-06-15 10:14:51 +00:00
Yoshisato Yanagisawa
7b691489a8 Merge "Set JAVAC_WRAPPER if USE_GOMA is set." am: aa09aa819f
am: cc2ca23b1e

Change-Id: Ie7288bc85507008efeed8bf5a3b42ceb2392062b
2017-06-15 07:38:39 +00:00
Treehugger Robot
aa09aa819f Merge "Set JAVAC_WRAPPER if USE_GOMA is set." 2017-06-15 07:28:26 +00:00
Igor Murashkin
9c57325093 Merge "core: Move core.oat bootjar definitions into core/config" am: 5e1aa20225
am: db52463bb3

Change-Id: I7fe90df0a8dae2fb5aa9f0dbcfc21a77b2700a87
2017-06-15 03:16:07 +00:00
Igor Murashkin
8c50798243 core: Move core.oat bootjar definitions into core/config
TARGET_CORE_JARS and HOST_CORE_JARS define the minimal
bootclasspath jars necessary to run with dalvikvm/art.

Also refactor PRODUCT_BOOT_JARS to reuse TARGET_CORE_JARS.

(These changes are required to figure out what --bootclasspath_entry
to pass to desugar).

Bug: 36902714
Test: make -j32 && make -j32 build-art-host build-art-target
Change-Id: I620e28be41047a1d501d7f144fe415ee4a0af36f
2017-06-14 10:02:09 -07:00
Yoshisato Yanagisawa
4f3e5685fc Set JAVAC_WRAPPER if USE_GOMA is set.
Now, people can also use goma for building javac.  Let me make it by
default.

Test: USE_GOMA=true m -j4
Bug: 62334576
Change-Id: I941ce42dc0f9cbd0dcc00e6fd19368c3af11695f
2017-06-14 07:57:54 +00:00
Dan Willemsen
bd98d429ce Merge "Fix ALLOW_MISSING_DEPENDENCIES in PDK builds" am: 8340ae35a7 am: c1fa14696a
am: f6eef888f4

Change-Id: If5cf8057c9536f05cf224a71edcd290b7347be58
2017-06-07 01:46:46 +00:00
Dan Willemsen
ccc48163ea Fix ALLOW_MISSING_DEPENDENCIES in PDK builds
ALLOW_MISSING_DEPENDENCIES was being set up before TARGET_BUILD_PDK, so
PDK builds were not triggering ALLOW_MISSING_DEPENDENCIES.

Bug: 62086238
Test: m -j nothing (check out/soong/soong.variables for AllowMissingDependencies)
Test: PDK_FUSION_PLATFORM_ZIP=test.zip m -j nothing (check AllowMissingDependencies)
Change-Id: I70919fbc7e397e55356cb467c6218cf6e7279c6c
2017-06-02 15:25:20 -07:00
Steven Moreland
8fb19697da Merge "Move math function definitions." am: b5e90583ef am: d1eab0ea46
am: a2f3561259

Change-Id: I86436840a6c5877901a13384faea6e699f0edfa9
2017-06-02 00:25:16 +00:00
Treehugger Robot
b5e90583ef Merge "Move math function definitions." 2017-06-02 00:11:04 +00:00
Steven Moreland
a64f33668e Move math function definitions.
Created math.mk and moved all math function definitions there.
Then, included this file in config.mk. This allows the functions to be
used by whatever includes config.mk (envsetup and build).

Test: manually setting combinations of PRODUCT_SHIPPING_API_LEVEL
  and PRODUCT_FULL_TREBLE_OVERRIDE and looking at values of
  PRODUCT_FULL_TREBLE.
Bug: 62229856
Change-Id: Icdab4214a1e65ae202411613dbcb9c9ea5f43b09
2017-05-31 20:41:49 +00:00
Miao Wang
b19c923c77 Merge "Update RenderScript build config and definitions." am: dddd7738d0 am: 4751b9e700
am: 527eee8b8f

Change-Id: Ife66e15b0c458a9fb622e56b7ab348e345d780b0
2017-05-26 22:51:36 +00:00
Treehugger Robot
dddd7738d0 Merge "Update RenderScript build config and definitions." 2017-05-26 22:29:36 +00:00
Dan Willemsen
118ceaea9a Merge changes I73787aff,I0d149812 am: 64caaf4679 am: 060e215f84
am: 6106d440c1

Change-Id: I509ee75ca9ee6c8dcacb839103d499bfe790dd23
2017-05-26 22:16:34 +00:00
Miao Wang
a9fed83fae Update RenderScript build config and definitions.
Bug: 38342163

  - obj/lib is deprecated and TARGET_OUT_INTERMEDIATE_LIBRARIES will be
  removed. We need to use per-module intermediates directory instead.
  - prebuilts/ndk/current folder is gone. For libm and libc, we just
  need ndk/r10 as stub libs for linking.

Test: mm and made sure this does not affect on device target.
Test: make -j50 FORCE_BUILD_RS_COMPAT=true RSTest_Compat works as
expected.

Change-Id: I8fbf5c10322707849a23c6b0dacc28b028db451e
2017-05-26 13:48:08 -07:00
Dan Willemsen
562baccae8 Remove the rest of showcommands, dist goal
showcommands is all handled in soong_ui, make/kati/ninja never see the
argument.

Remove the dist goal, since we'll never pass it to ninja, only to Kati
as a modifier.

Remove DUMP_%, since that's not used anywhere (it appears to be in our
code search via the NDK build system)

Test: m -j showcommands dist
Change-Id: I0d1498128caece685e98c2c2b5b0c3f545da0e11
2017-05-26 12:57:04 -07:00