Commit graph

26405 commits

Author SHA1 Message Date
Alex Klyubin
2cf2509542 Merge "Revert "Sign APKs using SHA-256 instead of SHA-1 when possible.""
am: 7382bdf8c1

* commit '7382bdf8c1a755fe20c5979453bfeec0be73da27':
  Revert "Sign APKs using SHA-256 instead of SHA-1 when possible."
2016-01-25 17:24:27 +00:00
Alex Klyubin
7382bdf8c1 Merge "Revert "Sign APKs using SHA-256 instead of SHA-1 when possible."" 2016-01-25 17:19:02 +00:00
Alex Klyubin
1429d5e14c Revert "Sign APKs using SHA-256 instead of SHA-1 when possible."
This reverts commit de5bc04717 because it's breaking some builds. Turns out some APKs have multiple sdkVersion attributes returned by aapt.

Change-Id: I013d6ef5eac473dd3900e0b9edf4c32cdc838bab
2016-01-25 17:17:09 +00:00
Neil Fuller
a5e4ea2e44 Merge "Revert "Make OpenJDK 8 the default""
am: c0acea2571

* commit 'c0acea25717fb26a13572d459b02811d8c8f9db6':
  Revert "Make OpenJDK 8 the default"
2016-01-25 17:14:16 +00:00
Neil Fuller
c0acea2571 Merge "Revert "Make OpenJDK 8 the default"" 2016-01-25 17:11:12 +00:00
Neil Fuller
85bddfdedf Revert "Make OpenJDK 8 the default"
Temporary revert to help out Brillo folks.
It will be resubmitted tomorrow.

This reverts commit 4495f6afb8.

Change-Id: Id378c7d3a6e72e9be50f9404b19d5763568987a5
2016-01-25 17:04:14 +00:00
Alex Klyubin
2a37afd32c Merge "Sign APKs using SHA-256 instead of SHA-1 when possible."
am: b763b29267

* commit 'b763b292671b9b18dcc9a5961c173667c674a3d5':
  Sign APKs using SHA-256 instead of SHA-1 when possible.
2016-01-25 16:46:43 +00:00
Alex Klyubin
b763b29267 Merge "Sign APKs using SHA-256 instead of SHA-1 when possible." 2016-01-25 16:42:27 +00:00
Neil Fuller
eaf7dbc90a Merge "Make OpenJDK 8 the default"
am: 797d3deb52

* commit '797d3deb52980a2bd8759e68a78ea99a56bb51e2':
  Make OpenJDK 8 the default
2016-01-25 10:53:01 +00:00
Neil Fuller
797d3deb52 Merge "Make OpenJDK 8 the default" 2016-01-25 10:45:34 +00:00
Neil Fuller
4495f6afb8 Make OpenJDK 8 the default
To return to OpenJDK 7:
export LEGACY_USE_JAVA7=true

And run envsetup.sh/lunch again.

Bug: 25786468
Change-Id: I8e00591a24d13e3b8b6baaafe0fdff6536c58770
2016-01-25 10:19:25 +00:00
Stephen Hines
d809c6ed48 Merge "Add an RS_CLANG variable as well for RenderScript."
am: adad19674c

* commit 'adad19674cfd7c38b16f2c2bd0c5bdf956157c6c':
  Add an RS_CLANG variable as well for RenderScript.
2016-01-22 23:28:16 +00:00
Stephen Hines
adad19674c Merge "Add an RS_CLANG variable as well for RenderScript." 2016-01-22 23:22:44 +00:00
Stephen Hines
49b695375c Add an RS_CLANG variable as well for RenderScript.
Change-Id: I33a73c4c2b19aa17bc18a64c92a86565111de3d0
2016-01-22 15:11:58 -08:00
Stephen Hines
48f0b9fb5a Merge "Add clang rules for RS_LLVM_* tools."
am: 4ac28d5258

* commit '4ac28d5258651c214a8480ad082254fd9c94ed55':
  Add clang rules for RS_LLVM_* tools.
2016-01-22 21:24:40 +00:00
Stephen Hines
4ac28d5258 Merge "Add clang rules for RS_LLVM_* tools." 2016-01-22 21:20:19 +00:00
James Hawkins
bb3d77ba95 Merge "bootstat: Add bootstat to the embedded target to support logging boot time across devices."
am: cb9da42c87

* commit 'cb9da42c878f5afb32513b441eaf72868163b655':
  bootstat: Add bootstat to the embedded target to support logging boot time across devices.
2016-01-22 18:28:19 +00:00
James Hawkins
cb9da42c87 Merge "bootstat: Add bootstat to the embedded target to support logging boot time across devices." 2016-01-22 18:09:05 +00:00
Tao Bao
4f3015f4a2 Merge "Generate OTA packages for A/B update."
am: bc6a66826a

* commit 'bc6a66826a56607c2e6a02f70b21e9faa0793719':
  Generate OTA packages for A/B update.
2016-01-22 17:27:52 +00:00
Tao Bao
bc6a66826a Merge "Generate OTA packages for A/B update." 2016-01-22 17:23:28 +00:00
Stephen Hines
96d2a8c5e4 Add clang rules for RS_LLVM_* tools.
This change adds new variables for RS_LLVM_* tools, which correspond
to the version of LLVM checked in currently to external/, instead of
mapping to the latest host prebuilts. This will help prevent version
differences for newer IR generated by the updated host prebuilts, which
then might not be readable with the on-device LLVM bits we build from
external/.

Change-Id: I6c7b0fa9082e9c8244cc508cb23960569a057740
2016-01-21 23:50:53 -08:00
Alex Klyubin
eafce4eefd Merge "Make signapk sign using APK Signature Scheme v2."
am: b86b5344a6

* commit 'b86b5344a6b7703bfa36a203f34ca3a117051587':
  Make signapk sign using APK Signature Scheme v2.
2016-01-22 04:12:30 +00:00
Alex Klyubin
b86b5344a6 Merge "Make signapk sign using APK Signature Scheme v2." 2016-01-22 04:07:45 +00:00
Tao Bao
8994f9ca38 Merge "CleanSpec: Clean up /recovery/root/sdcard."
am: b69d3b28a5

* commit 'b69d3b28a5a00050d946921a7e14b5eae203ebac':
  CleanSpec: Clean up $(PRODUCT_OUT)/recovery/root/sdcard.
2016-01-22 01:33:03 +00:00
Tao Bao
b69d3b28a5 Merge "CleanSpec: Clean up $(PRODUCT_OUT)/recovery/root/sdcard." 2016-01-22 01:28:30 +00:00
Tao Bao
6b10089bd6 CleanSpec: Clean up $(PRODUCT_OUT)/recovery/root/sdcard.
Incremental build going across CL in [1] needs to remove the old
symlink to avoid hitting mkdir error.

[1]: commit 3f56a33041

Change-Id: Iff62ed55eb2782ba3e1e9b6de39a691de2427384
2016-01-21 17:18:47 -08:00
Colin Cross
11a87113ef Merge "Set flag when using sdk tools in place"
am: 41ee5fc07a

* commit '41ee5fc07adf81348a807c2de8d4460598a38fa4':
  Set flag when using sdk tools in place
2016-01-22 00:04:05 +00:00
James Hawkins
bc5dc64232 bootstat: Add bootstat to the embedded target to support logging boot
time across devices.

Bug: 21724738
Change-Id: I165e8597103ea235a0826e321a1658823c4b4664
2016-01-21 15:39:45 -08:00
Colin Cross
41ee5fc07a Merge "Set flag when using sdk tools in place" 2016-01-21 23:36:26 +00:00
Tao Bao
3ea04365dc Merge "Makefile: Fix the location for payload signing key."
am: 27a1201989

* commit '27a1201989d782af30a30186a05448dbbe3304b8':
  Makefile: Fix the location for payload signing key.
2016-01-21 23:19:16 +00:00
Dan Willemsen
537e093fe8 Merge "Pass the arm/thumb cflags to assembly files"
am: 60c9200c1e

* commit '60c9200c1ee3f5d983c5f9d9cc1724f6010daca2':
  Pass the arm/thumb cflags to assembly files
2016-01-21 23:19:02 +00:00
Tao Bao
cf7eb025f8 Merge "Makefile: Add the payload public key into system image."
am: b49d05e72e

* commit 'b49d05e72e03c4d51c81ec8fcedd463ea5b0e28f':
  Makefile: Add the payload public key into system image.
2016-01-21 23:18:50 +00:00
Tao Bao
27a1201989 Merge "Makefile: Fix the location for payload signing key." 2016-01-21 22:37:46 +00:00
Tao Bao
23c3db9372 Makefile: Fix the location for payload signing key.
CL in [1] put it in a wrong path.

[1] commit 38812d684b

Bug: 25715402
Change-Id: I01a105888844011eee083d5f4d694223599fa067
2016-01-21 14:33:22 -08:00
Dan Willemsen
60c9200c1e Merge "Pass the arm/thumb cflags to assembly files" 2016-01-21 22:31:11 +00:00
Tao Bao
b49d05e72e Merge "Makefile: Add the payload public key into system image." 2016-01-21 22:21:31 +00:00
Christopher Wiley
cfd817d058 Merge "Separate aidl dependencies from compiler dependencies"
am: 8edda3afdf

* commit '8edda3afdf1bf3327706d89a5b4b5ce53feedbe5':
  Separate aidl dependencies from compiler dependencies
2016-01-21 18:27:02 +00:00
Christopher Wiley
7c52b2d878 Merge "Keep aidl generated C++ inside the generated folder"
am: 11feb8b075

* commit '11feb8b075ce48fc4b6386049a666a5e888247f8':
  Keep aidl generated C++ inside the generated folder
2016-01-21 18:26:54 +00:00
Alex Klyubin
de5bc04717 Sign APKs using SHA-256 instead of SHA-1 when possible.
This changes the build system to provide the signapk tool with the
minSdkVersion of the APK being signed. signapk in turn will then use
SHA-256 instead of SHA-1 if minSdkVersion is 18 (JB MR2) or higher
(see c2c49ed0c1).

To avoid increasing incremental OTA update package sizes for already
released platforms, release build scripts disable the above logic when
signing target files ZIPs for pre-N platforms.

Bug: 25643280
Change-Id: I048393e0971d0d6559dbd69ea902754c6c7cab14
2016-01-21 10:25:12 -08:00
Christopher Wiley
8edda3afdf Merge "Separate aidl dependencies from compiler dependencies" 2016-01-21 18:19:05 +00:00
Christopher Wiley
11feb8b075 Merge "Keep aidl generated C++ inside the generated folder" 2016-01-21 18:17:29 +00:00
Tao Bao
38812d684b Makefile: Add the payload public key into system image.
For non-Brillo devices using AB update, add the payload signing public
key to the system image
(system/etc/update_engine/update-payload-key.pub.pem).

We first need to sign the payload with some private key, and pack it
into an Android OTA package. Then the whole zip package will be signed
again with the device key. This is to comply with the two existing OTA
flows (Android and CrOS).

We use the same device key to do the two signings, but update_engine
expects the key in RSA public key format. This CL extracts the public
key from x509 certificate and adds it to the system image.

Bug: 25715402
Change-Id: I6f6c1148534250ddb6d9e554175c7a35bceda99e
2016-01-20 21:29:00 -08:00
Alex Klyubin
aafc1e9665 Merge "Command-line flag to disable signing with APK Signature Scheme v2."
am: 3cc3605010

* commit '3cc36050109fa1f310f11fca980ac415cb58bee7':
  Command-line flag to disable signing with APK Signature Scheme v2.
2016-01-21 01:28:23 +00:00
Colin Cross
d3f3ab77fd Set flag when using sdk tools in place
New version of build/ execute the tools from prebuilts/sdk/tools in
place, old versions copy them to $(HOST_OUT_EXECUTABLES).  build/ and
prebuilts/sdk often use mixed versions, set a flag that
prebuilts/sdk/tools/Android.mk can use to determine when it is using an
old build/ directory.

Change-Id: Iad2f96c35203fd3b0976946d229bfa8ab4acb150
2016-01-20 16:08:49 -08:00
Alex Klyubin
dd910c5945 Make signapk sign using APK Signature Scheme v2.
APKs are now signed with the usual JAR signature scheme and then
with the APK Signature Scheme v2.

APK Signature Scheme v2 is a whole-file signature scheme which aims
to protect every single bit of the APK as opposed to the JAR signature
scheme which protects only the names and uncompressed contents of ZIP
entries.

The two main goals of APK Signature Scheme v2 are:
1. Detect any unauthorized modifications to the APK. This is achieved
   by making the signature cover every byte of the APK being signed.
2. Enable much faster signature and integrity verification. This is
   achieved by requiring only a minimal amount of APK parsing before
   the signature is verified, thus completely bypassing ZIP entry
   decompression and by making integrity verification parallelizable
   by employing a hash tree.

Bug: 25794543
Change-Id: I275d2a6d0a98504891985309b9dfff2e0e44b878
2016-01-20 13:35:21 -08:00
Alex Klyubin
3cc3605010 Merge "Command-line flag to disable signing with APK Signature Scheme v2." 2016-01-20 21:02:29 +00:00
Alex Klyubin
9b54a565c9 Command-line flag to disable signing with APK Signature Scheme v2.
This change makes signapk not reject the --disable-v2 command-line
flag which may be used by build scripts in some branches. The flag
is currently ignored.

This change is landed separately from the actual support for APK
Signature Scheme v2 because of unbundled branches which use prebuilt
versions of signapk.

Bug: 25794543
Change-Id: I900966244b8b6296b1f443bf98830cc7f7cc81a8
2016-01-20 12:55:16 -08:00
Christopher Wiley
087f327304 Separate aidl dependencies from compiler dependencies
Both aidl and clang/gcc were putting their dependencies in the same
place.  Move aidl's dependencies to a file ending with .aidl.P rather
than the compiler's .P.

While here, inform kati that we have these special dep files.

Bug:26409006
Test: Rebuild, note both files being generated

Change-Id: I29d2eea822235d60713c2059f3a314e475eb5aa3
2016-01-20 12:54:09 -08:00
Christopher Wiley
257796c62d Keep aidl generated C++ inside the generated folder
Transform ../ to dotdot/ for C++ generateds from .aidl source files.
This forces us to use one layer of indirection to calculate the build
rules for .aidl files, since we can no longer use a pattern rule.

This was tested by modifying system/tools/aidl's Android.mk to refer to
its .aidl files by going up two directories and then repeating the
directories again.  When I print the build rules with $(info) I see that
dotdot/ appears in appropriate places (C++ paths, but not .aidl paths).

Bug: 26407018
Test: Described above.

Change-Id: I397c9d10408c0c66d8b5a247a1f34eb4bf4f74ce
2016-01-20 09:17:20 -08:00
Chih-hung Hsieh
2ba3e15de1 Merge "Set USE_CLANG_PLATFORM_BUILD to default true."
am: c36a9760e1

* commit 'c36a9760e17bc0ce1cc815572886e640bb0ded18':
  Set USE_CLANG_PLATFORM_BUILD to default true.
2016-01-19 23:57:53 +00:00