Commit Graph

46532 Commits

Author SHA1 Message Date
Colin Cross
71aa08677d Merge "Export Soong install rules to Make" am: 1caea35278 am: 7f5f69f9ba am: 5e5d6332b4
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869552

Change-Id: Ifc2d7a00569bdb8dcef9853f27e07824cef3d59d
2021-11-01 22:23:07 +00:00
Colin Cross
5e5d6332b4 Merge "Export Soong install rules to Make" am: 1caea35278 am: 7f5f69f9ba
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869552

Change-Id: Idf2e8d7503f49ea3df962ee1ca6a26daf9360ad6
2021-11-01 22:05:02 +00:00
Colin Cross
7f5f69f9ba Merge "Export Soong install rules to Make" am: 1caea35278
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869552

Change-Id: If4139b06b8e07ab7cddb9ed1f428495e7dafe0d8
2021-11-01 21:47:57 +00:00
Colin Cross
1caea35278 Merge "Export Soong install rules to Make" 2021-11-01 21:31:56 +00:00
Treehugger Robot
9daf45125d Merge "Create prebuilt system modules for all API scopes" am: 2bbd2c55c5 am: ef70b722db am: 2c812cb270
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1875855

Change-Id: I83735a349273669731fafe738b126169b76b3607
2021-11-01 20:07:03 +00:00
Treehugger Robot
2c812cb270 Merge "Create prebuilt system modules for all API scopes" am: 2bbd2c55c5 am: ef70b722db
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1875855

Change-Id: Idd1b95efd88354e04110e82f88f4b934e2c0e6a8
2021-11-01 19:51:23 +00:00
Treehugger Robot
ef70b722db Merge "Create prebuilt system modules for all API scopes" am: 2bbd2c55c5
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1875855

Change-Id: I180ae8fa05ab72e4e3c6c0cce5a19eea55d6f395
2021-11-01 19:33:16 +00:00
Treehugger Robot
086a0913aa Merge changes I346ac9c0,I57352aa0 am: 57be76d9ac am: 061abc7259 am: 49753eca77
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1875854

Change-Id: I0df294128a7789684481055fe18b7b6d3e38b416
2021-11-01 19:20:16 +00:00
Treehugger Robot
2bbd2c55c5 Merge "Create prebuilt system modules for all API scopes" 2021-11-01 19:16:03 +00:00
Treehugger Robot
49753eca77 Merge changes I346ac9c0,I57352aa0 am: 57be76d9ac am: 061abc7259
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1875854

Change-Id: Ie794197f49ea4825f477d34cea074efe5f1169ff
2021-11-01 18:53:07 +00:00
Treehugger Robot
061abc7259 Merge changes I346ac9c0,I57352aa0 am: 57be76d9ac
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1875854

Change-Id: I2bfef4479f413f4eca23a831612b4277e27c49c3
2021-11-01 18:27:36 +00:00
Treehugger Robot
57be76d9ac Merge changes I346ac9c0,I57352aa0
* changes:
  Make prebuilt_api test environment realistic
  Add test for prebuilt_apis creation of system modules
2021-11-01 18:11:06 +00:00
Treehugger Robot
02c857bdd0 Merge "Make manifest_check errors colorful." am: 0888700fe1 am: d2a38198e0 am: 074031e402
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1877316

Change-Id: I00a5d1e166147d14fb16163132d9a1cab9ecbe3b
2021-11-01 18:08:49 +00:00
Treehugger Robot
074031e402 Merge "Make manifest_check errors colorful." am: 0888700fe1 am: d2a38198e0
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1877316

Change-Id: Ic76f22379b2c6c1586f89c8bcf4669621c1db53e
2021-11-01 17:46:53 +00:00
Treehugger Robot
d2a38198e0 Merge "Make manifest_check errors colorful." am: 0888700fe1
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1877316

Change-Id: Idd8323833406b0e358abb947c615ff889ccf1d11
2021-11-01 17:29:05 +00:00
Treehugger Robot
0888700fe1 Merge "Make manifest_check errors colorful." 2021-11-01 17:11:52 +00:00
Paul Duffin
245849abe6 Dist API specific core-for-system-modules am: bce9f08d02 am: 381f698843 am: 9474d1a187
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1873693

Change-Id: Ib930f158b2cd943a0ea2dab2408c5b2c310851fe
2021-11-01 16:56:35 +00:00
Paul Duffin
9474d1a187 Dist API specific core-for-system-modules am: bce9f08d02 am: 381f698843
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1873693

Change-Id: I51465180108017ffe8f492b909a53056a3807ac0
2021-11-01 16:44:12 +00:00
Paul Duffin
b077bcc6bc Create prebuilt system modules for all API scopes
Previously, system modules were only created for the public API scope.
This change creates them for any API scope as long as its directory has
a core-for-system-modules.jar.

It does that by hooking into the existing logic for creating a
java_import for all jars in the API directories and creating a
java_system_modules for every core-for-system-modules.jar file. That
avoids the need for extra path globs.

Test: m droid
      m sdk_public_current_system_modules
      - works as expected.
      m sdk_module-lib_current_system_modules
      - fails with missing target as expected.
      touch prebuilts/sdk/current/module-lib/core-for-system-modules.jar
      m sdk_module-lib_current_system_modules
      - fails with invalid jar file as expected.
Bug: 204189791
Change-Id: I27a264941009e03439d5d847dab14a7b4f6f119f
2021-11-01 16:37:49 +00:00
Paul Duffin
1cad3a53db Make prebuilt_api test environment realistic
Previously, the fixture preparer for prebuilt_apis would add a
core-for-system-modules.jar file in every API directory even though
currently they only exist in the public API directories.

This change makes the test environment more realistic by only creating
them for the public API. Rather than hard code that into the test code
(which would duplicate the hard coding in the decodeSdkDep func) this
extracts a function that is used by both. That ensures that any changes
to that func will be reflected in both the test and runtime behavior.

Bug: 204189791
Test: m nothing
Change-Id: I346ac9c0dcf407c61de16b6027663a05821bcf62
2021-11-01 16:36:23 +00:00
Paul Duffin
6d448b7a0a Add test for prebuilt_apis creation of system modules
Previously, there were no tests for this (outside uses in other tests).
This change adds a test that uses the fixture preparers that create a
prebuilt_api in order to make prebuilt APIs available. That ensures
that both the prebuilt_api is working as expected and the preparer
creates a realistic test environment.

Bug: 204189791
Test: m nothing
Change-Id: I57352aa00f7b268e5286be92f177764dd63ba7e8
2021-11-01 16:36:02 +00:00
Paul Duffin
381f698843 Dist API specific core-for-system-modules am: bce9f08d02
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1873693

Change-Id: Ic4206df7453370b3073a4656843d1bfadafadf8b
2021-11-01 16:13:34 +00:00
Ulya Trafimovich
b4c19f8a31 Make manifest_check errors colorful.
Insert ANSI escape codes in the error text. Colors are red, blue, green
and some text is in bold --- these are all bright enough on either dark
or light background.

Also, add a link to the online documentation.

Bug: 132357300
Test: manually mangle one of Android.bp files to get a manifest_check
  error and observe that it is colorful.
Change-Id: I2af2aa0415d0eb0eabc88dc5504198e11bfb91b6
2021-11-01 14:39:46 +00:00
Paul Duffin
bce9f08d02 Dist API specific core-for-system-modules
Previously, the dist only contained a core-for-system-modules.jar for
the public API. This change adds API specific directories containing a
core-for-system-modules.jar file for each of the following APIs:
* public
* module-lib

Bug: 204189791
Test: rm -fr out/dist
      m sdk dist
      find out/dist -name core-for-system-modules.jar
      - outputted the following:
      out/dist/core-for-system-modules.jar
      out/dist/system-modules/module-lib/core-for-system-modules.jar
      out/dist/system-modules/public/core-for-system-modules.jar
Change-Id: Id1845926e2085f70d58e9fc22e9c11cb3d62b919
2021-11-01 14:01:39 +00:00
Joe Onorato
6cc658af6b Merge "Add support for java streaming proto" am: 22e973c539 am: a224d53694 am: c1ce0ed41c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1874416

Change-Id: Iebb924867b3600343832ab63ca47870194ee5f24
2021-11-01 00:52:10 +00:00
Joe Onorato
c1ce0ed41c Merge "Add support for java streaming proto" am: 22e973c539 am: a224d53694
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1874416

Change-Id: I2898febfd2f709d07bef0b92b9f067ead51a3910
2021-11-01 00:40:40 +00:00
Joe Onorato
a224d53694 Merge "Add support for java streaming proto" am: 22e973c539
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1874416

Change-Id: I2b61650dee7adddcd3ce116a2dfd5b7ceb587ee4
2021-11-01 00:26:18 +00:00
Joe Onorato
22e973c539 Merge "Add support for java streaming proto" 2021-11-01 00:14:59 +00:00
Colin Cross
e097970ad8 Merge changes I04f2f558,Ie16a6264,I83a3be9f,Icb3eeef3 am: 91eaa6316a am: 19aa461cc0 am: 204c59ef91
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869551

Change-Id: I30301ab035b28f654b2510fbc28be4003a5ec346
2021-10-30 20:30:46 +00:00
Colin Cross
204c59ef91 Merge changes I04f2f558,Ie16a6264,I83a3be9f,Icb3eeef3 am: 91eaa6316a am: 19aa461cc0
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869551

Change-Id: I512a0433e8517e7062fb9929e2f80d48ae23036b
2021-10-30 19:55:35 +00:00
Colin Cross
19aa461cc0 Merge changes I04f2f558,Ie16a6264,I83a3be9f,Icb3eeef3 am: 91eaa6316a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869551

Change-Id: Ida831ee9684ce97052443a012d5c4986c0d4399c
2021-10-30 19:37:28 +00:00
Colin Cross
91eaa6316a Merge changes I04f2f558,Ie16a6264,I83a3be9f,Icb3eeef3
* changes:
  Rename amod variable in AndroidMkEntries.fillInEntries to base
  Make HostToolPath, HostJNIToolPath and sboxPathForToolRel use pathForInstall
  Add PathForGoBinary
  Remove PathForOutput from InstallPathToOnDevicePath
2021-10-30 19:19:53 +00:00
Colin Cross
a90c335bbe Merge "Use --skip-config --soong-only instead of --skip-make" am: e7fc5a25c5 am: 814909b0f3 am: f9b1f0b3d0
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1875216

Change-Id: I16b442db90929cb1c2da3c3161b79803302400d1
2021-10-30 16:48:36 +00:00
Colin Cross
f9b1f0b3d0 Merge "Use --skip-config --soong-only instead of --skip-make" am: e7fc5a25c5 am: 814909b0f3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1875216

Change-Id: I383e03d4fec215afdf5a4f344364d6eed3aa9a99
2021-10-30 16:30:53 +00:00
Colin Cross
814909b0f3 Merge "Use --skip-config --soong-only instead of --skip-make" am: e7fc5a25c5
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1875216

Change-Id: I3da344ae1c31d292b7e1ef446151893b723a88f5
2021-10-30 16:13:21 +00:00
Colin Cross
e7fc5a25c5 Merge "Use --skip-config --soong-only instead of --skip-make" 2021-10-30 15:56:22 +00:00
Colin Cross
b24afb8f67 Merge "Make installable arch-variant and static vs shared variant for cc modules" am: 4985224198 am: 5dc0ab4daa am: 385517b48d
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1874552

Change-Id: I3569ce5bd3836806049d8f4b1abfac58d0438070
2021-10-30 05:42:33 +00:00
Colin Cross
385517b48d Merge "Make installable arch-variant and static vs shared variant for cc modules" am: 4985224198 am: 5dc0ab4daa
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1874552

Change-Id: I7bdfd8ec00a798076d00a5b893bf54397a0e6e0f
2021-10-30 05:25:40 +00:00
Colin Cross
5dc0ab4daa Merge "Make installable arch-variant and static vs shared variant for cc modules" am: 4985224198
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1874552

Change-Id: I076443da26723441f0534187d686cee2ed4b8a88
2021-10-30 05:13:17 +00:00
Colin Cross
4985224198 Merge "Make installable arch-variant and static vs shared variant for cc modules" 2021-10-30 04:56:22 +00:00
Chih-hung Hsieh
9b872ac262 Merge "Add -{checkbuild,tidy} targets only for modules in mm" am: 7b2239f648 am: 6ac43742fc am: 8044ebf38b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1858736

Change-Id: Ief9c7ed6f55e8b8528dd8874ddc41a90ea2551ea
2021-10-30 04:55:15 +00:00
Chih-hung Hsieh
8044ebf38b Merge "Add -{checkbuild,tidy} targets only for modules in mm" am: 7b2239f648 am: 6ac43742fc
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1858736

Change-Id: I80f4d3794d8592c5ae918074d461ace8254bfcfe
2021-10-30 04:43:07 +00:00
Chih-hung Hsieh
6ac43742fc Merge "Add -{checkbuild,tidy} targets only for modules in mm" am: 7b2239f648
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1858736

Change-Id: I9297a7c901e736676e0e03f1b56694b79d5fddbd
2021-10-30 04:14:10 +00:00
Chih-hung Hsieh
7b2239f648 Merge "Add -{checkbuild,tidy} targets only for modules in mm" 2021-10-30 03:57:06 +00:00
Chih-Hung Hsieh
a3d135b1af Add -{checkbuild,tidy} targets only for modules in mm
Test: lunch aosp_coral-userdebug; WITH_TIDY=1
      make 7-libgptutils.coral-checkbuild 7-libgptutils.coral-tidy
Test: only coral libgptutils in out/build-aosp_coral.ninja
Test: lunch aosp_arm64-eng; make has no *libgptutils* tagets
Test: no libgptutils in out/build-aosp_arm64.ninja
Test: lunch aosp_cf_arm64_phone-userdebug; make libskia-checkbuild
Test: lunch aosp_arm64-eng; WITH_TIDY=1 make tidy-soong

Bug: 202763874
Change-Id: I2d5a3fdc627d62e43c3f10e61b338a03c10440be
2021-10-29 18:02:27 -07:00
Treehugger Robot
4c549b825a Merge "apex.custom_sign_tool property" am: cae893ae40 am: e18be41278 am: f11c7c9e18
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869522

Change-Id: I8a56843f67f6a10349d9c4971596979bf1b4ffd3
2021-10-30 00:30:32 +00:00
Treehugger Robot
f11c7c9e18 Merge "apex.custom_sign_tool property" am: cae893ae40 am: e18be41278
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869522

Change-Id: I191fcd8a85296f208f0dbbb151c93bc09f8be7a6
2021-10-30 00:13:05 +00:00
Treehugger Robot
e18be41278 Merge "apex.custom_sign_tool property" am: cae893ae40
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869522

Change-Id: I9d94371728b68252e0056a9574fe7d0791c7ae68
2021-10-29 23:56:00 +00:00
Treehugger Robot
cae893ae40 Merge "apex.custom_sign_tool property" 2021-10-29 23:39:26 +00:00
Colin Cross
6301c3cffa Export Soong install rules to Make
Previously Soong's install rules have been disabled when embedded
in Make (ctx.Config().KatiEnabled() == true).  The primary blocker
for moving installation into Soong has been the `required` proeprty,
which is too vague to be easily handled in Soong.  Keeping
installation in Make has resulted in two host bin directories,
the Make-owned directory (e.g. out/host/linux-x86/bin), and the
Soong-owned directory (e.g. out/soong/host/linux-x86/bin).  The
lack of knowledge in Soong about the final, Make-owned installation
location makes it hard to support NOTICE files entirely in Soong.

This patch begins to solve this problem by supporting the creation of
the installation rules into Soong, but rather than writing the rules
to the ninja file it writes them to a Makefile and lets Kati convert
them to ninja.  This allows Kati to inject extra dependencies to
handle the `required` property.

Converting all modules to create their installation rules in Soong
would be too complex, so only modules that return true from
InstallBypassMake will use the Soong installation rules.  This
is currently only set for robolectric tests.

Bug: 204136549
Test: m checkbuild
Change-Id: I28af9fa7fadece8ea1f98f5efd140c823751cae7
2021-10-29 16:34:55 -07:00