Commit graph

51861 commits

Author SHA1 Message Date
Matthew Maurer
b983c8971b Revert "rust: Only allow bindgen to produce rlibs."
This reverts commit 53a452d1ff.

Reason for revert: Broken build

Change-Id: I4c1c6f2166c3729ef1916ad7c21e32599c5e692f
2022-08-01 21:59:00 +00:00
Matthew Maurer
53a452d1ff rust: Only allow bindgen to produce rlibs.
Generated bindings are intended to be slim translation layers, usually
consisting of nothing more than type signatures and constants.
Generally, they should also be used in exactly one location by the safe
wrapper for these bindings. By preventing them from building as
`dylib`s, we avoid the per-library overhead of these non-reused pieces
of code.

Additionally, default visibility restrict all bindgen modules to their
subpackages. This is being done both:
* to encourage use of a single safe bindings crate
* to avoid diamond dependency graphs with mixed rlib/dylib dependencies

Bug: 166332519
Test: m; Make sample module use dylib bindgen dependency, see build failure.
Change-Id: I8e9d9cb851c2ec99f4ed63e6e18c4ba26b29721c
2022-08-01 16:28:51 +00:00
Martin Stjernholm
0bb7f0494e Merge "Revert "Implement mixed builds for apex modules."" 2022-07-26 13:52:18 +00:00
Martin Stjernholm
8a3c914942 Revert "Implement mixed builds for apex modules."
Revert submission 2147387-mixed_builds

Reason for revert: Breaks zipapex build on git_master-art-host
Bug: 239925080
Reverted Changes:
I9f1e03e5e:Implement mixed builds for apex modules.
I13d9a0270:Add container and bundle encription key pairs to t...

Change-Id: I0eaad4dd81cac16d634f4c9cec18137a38e30d47
2022-07-26 09:35:39 +00:00
Joe Onorato
b7873a8b0f Merge "Add top level and per-mutator traces to soong_build" 2022-07-22 19:28:53 +00:00
Joe Onorato
2e5e401722 Add top level and per-mutator traces to soong_build
- Top-level trace for all soong_build runs
  - Includes adding Peek() to OncePer because not all soong_build
    invocations have GenerateBuildActions run.
- A trace per mutator invocation

Test: m && build/bazel/scripts/print_analysis_metrics.py
Change-Id: Ief5c04630484fb38ec7e3757de45c7dc294d3b3c
2022-07-22 10:01:35 -07:00
Mu-Le Lee
6f84b7763e Merge "Move LLNDK ABI dumps from vndk/ to platform/" 2022-07-22 10:44:06 +00:00
Cole Faust
b59a3dba02 Merge "Downgrade/disable lint checks" 2022-07-21 19:57:17 +00:00
Treehugger Robot
576bacae1d Merge "Fix typo" 2022-07-21 17:32:49 +00:00
Treehugger Robot
06776d6b6a Merge "Deprecate notice property." 2022-07-21 14:19:28 +00:00
Treehugger Robot
485127c76e Merge "Add option to allow unknown warning options" 2022-07-21 12:23:28 +00:00
Paul Duffin
69d09f49ec Merge "Export any platform_compat_config used by apex to sdk snapshot" 2022-07-21 10:39:27 +00:00
jiajia tang
cd1c27b33f Fix typo
Signed-off-by: jiajia tang <tangjiajia@xiaomi.com>
Change-Id: I23bec7b08c11c33a06dd13eb7b60ea38d4f26a11
2022-07-21 18:04:37 +08:00
Yi Kong
f7f69e4992 Add option to allow unknown warning options
Some build targets pulls cflags from build/soong but has its own choice
of compiler version. This causes errors for due to unknown warning
options. This allows them to suppress such checks.

Test: presubmit
Change-Id: Ia89508d6b92481fb1ed0c90f1fdb4d8e54566349
2022-07-21 15:49:05 +08:00
Treehugger Robot
a9eef7bd2d Merge "Update clang version to clang-r458507" 2022-07-21 07:01:29 +00:00
Yi Kong
eb8d04e589 Update clang version to clang-r458507
Test: presubmit
Bug: 236798112
Change-Id: Iff8df2b5c7faf359d0554994586bbc984b7a1856
2022-07-21 06:43:09 +00:00
Yi-Yo Chiang
da44795563 Remove $PRODUCT_OUT/vendor_kernel_ramdisk on installclean
Make sure the staging directory doesn't have stale file after
installclean.

Test: m installclean && ls $ANDROID_PRODUCT_OUT
Change-Id: Idcd7a883a6cba4b7eb1eb99751f5d03cba365a12
2022-07-21 03:52:02 +00:00
Bob Badour
124f3fe855 Deprecate notice property.
Bug: 192434786

Test: m droid dist

Change-Id: Id47ff3c945b556ea0452a91305f7637bbcc35008
2022-07-20 14:37:13 -07:00
Colin Cross
7d9f760705 Merge "Revert "Make FirstTarget treat HostCross separately from Host"" 2022-07-20 17:38:53 +00:00
Colin Cross
3b56c92977 Revert "Make FirstTarget treat HostCross separately from Host"
This reverts commit c5d7ad6b68.

Reason for revert: Speculatively reverting as likely cause of mac build breakage

Change-Id: I30fbbaaac28f3a2fe8bc1c05775d3de248199b29
2022-07-20 17:37:37 +00:00
Charisee Chiw
b5aa16f340 Merge "rustc-1.62.0.p1 Build 8836667" 2022-07-20 17:13:27 +00:00
Colin Cross
0243999864 Merge "Make FirstTarget treat HostCross separately from Host" 2022-07-20 15:49:47 +00:00
Paul Duffin
fcf79850d8 Export any platform_compat_config used by apex to sdk snapshot
Previously, the platform_compat_config modules needed to be explicitly
listed in the sdk snapshot and the apex. This change will automatically
export them to the sdk snapshot when the apex is listed in its apexes
property.

Bug: 232401814
Test: m tethering-module-sdk
      # Before this change the generated snapshot did not contain the
      # platform_compat_config, after this change it did.
      m art-module-sdk
      # As that explicitly specifies the platform_compat_config in its
      # compat_configs property this change has no effect.
Change-Id: Ia854b9a52db2b1619fca41a387ce98d7f9f9efe9
2022-07-20 14:18:24 +00:00
Alexander Smundak
0c1b781de5 Merge "Revert "Suppress all progress messages from Ninja if ANDROID_QUIET_BUILD is set."" 2022-07-20 14:10:32 +00:00
Colin Cross
c5d7ad6b68 Make FirstTarget treat HostCross separately from Host
Use Target.Os and Target.HostCross as the key in FirstTarget so that
it returns a separate target for host and host cross architectures.
This is useful when host and host cross are both linux_musl, but
host cross is an independenct architecture like arm64.

Bug: 236052820
Test: cross compile linux_musl-arm64
Change-Id: If75790001afe9d0f9d4d8166f207847851812297
2022-07-19 14:44:34 -07:00
Yi Kong
1b3d5f836c Merge "Enable -Wmisleading-indentation for 1p projects" 2022-07-19 16:53:32 +00:00
Sasha Smundak
2cec8df3a8 Revert "Suppress all progress messages from Ninja if ANDROID_QUIET_BUILD is set."
Reverts commit 827aead340
The change being reverted is the result of misunderstanding of how the
status system works. It has to be reverted because it would suppress
_all_ error messages from Make. Achieving what this change purports is
is more involved and requires changing the code to separate progress message
stream from application output stream.

Test: run failing build with ANDROID_QUIET_BUILD=tree and observe errors being output
Change-Id: If9148a7fa773ae32fb0870a448e9470560e53900
2022-07-19 08:02:42 -07:00
Alexander Smundak
7c81cf6e4e Merge "Output informational messages only when BP2BUILD_VERBOSE is set." 2022-07-19 13:39:44 +00:00
Alexander Smundak
9ec1ff98b7 Merge "Implement mixed builds for apex modules." 2022-07-19 13:38:55 +00:00
Elliott Hughes
f08a664127 Enable -Wmisleading-indentation for 1p projects
Bug: http://b/232926688
Test: treehugger
Change-Id: I7e3458f23e9b2e7a229a4a3eada5d98bdf4731d0
2022-07-19 11:51:59 +00:00
Paul Duffin
c5e02caef3 Merge "Sort files in sdk snapshot zip to ensure consistent behavior" 2022-07-19 09:26:25 +00:00
Treehugger Robot
b3f18a9f9f Merge changes I0484ea34,I188e4824
* changes:
  Distinguish # apex and # systemapi symbols
  Refactor symbolfile script
2022-07-19 06:24:04 +00:00
Jiyong Park
85cc35a143 Distinguish # apex and # systemapi symbols
Previously, the symbol tag `# apex` was treated the same as `#
systemapi`. With this CL, they have different meanings.

`# systemapi`: APIs that are defined in the platform (the non-updatable
part), and are exposed to unbundled system components like APEX

`# apex`: APIs that are defined in the APEX and are exposed to the
platform or other APEXes

Bug: 239274367
Test: m
Change-Id: I0484ea349656dbbd337e5fe3a5970f0ad275b807
2022-07-19 13:47:19 +09:00
Jiyong Park
3f9c41d2f5 Refactor symbolfile script
Introduce the class `Filter` which encapsulates conditions
(architecture, api level, whether llndk is included, etc.) so that we
don't need to touch many places everytime a new condition is added.

In addition, refactor test_symbolfile to reduce duplications

This CL doesn't add a new functionality.

Bug: 239274367
Test: run test_ndkstubgen and test_symbolfile
Change-Id: I188e482492d39ec18134ecc5c908f0d288a754a9
2022-07-19 13:47:15 +09:00
Charisee
d6a5b15dfe rustc-1.62.0.p1 Build 8836667
Test: m rust
Change-Id: I8e22ce766ccfb64263eba794aa75144c58ebb71a
2022-07-18 22:15:44 +00:00
Sasha Smundak
0fd93e0756 Output informational messages only when BP2BUILD_VERBOSE is set.
Test: manual
Change-Id: Ieeb00a002e07b04449d70614ce205c47c1dd7bce
2022-07-18 13:34:44 -07:00
Sasha Smundak
6a2b7c40b3 Implement mixed builds for apex modules.
* Add ApexCqueryInfo to obtain apex artifacts used by the makefile
  generator and downstream modules
* Refactor code common to GenerateAndroidBuildActions and ProcessBazelQueryResponse
* Implement android.MixedBuildBuildable for modules
* Enable mixed build for apex modules with payload_type:"image"

Bug: 232085015
Test: treehugger
Change-Id: I9f1e03e5e7a5b5dde35a5db10c253069543ac973
2022-07-18 13:34:36 -07:00
Paul Duffin
74f1dcd1ab Sort files in sdk snapshot zip to ensure consistent behavior
The order of the files in the sdk snapshot was stable but depended on
how the sdk was built. If the snapshot was created directly then the
files have one order, if it was created by merging in files from other
zips then it has a different order.

This change ensures files are in alphabetical order no matter how the
snapshot zip is constructed.

Bug: 232401814
Test: m media-module-sdk
      # Check the contents of the following zips to ensure that they are sorted
      # after this change.
      # out/soong/.intermediates/packages/modules/Media/apex/media-module-sdk/common_os/media-module-sdk-current.unmerged.zip
      # out/soong/mainline-sdks/media-module-sdk-current.zip
Change-Id: Ie97e0119c07a1f34a2b1d3ea6895f0e76cd195a8
2022-07-18 15:35:50 +00:00
Romain Jobredeaux
b3e7dfbd80 Merge "Enable Java in mixed builds." 2022-07-18 14:51:55 +00:00
Treehugger Robot
e3048505c0 Merge "Move libFlags as well to the RSP file for link actions" 2022-07-18 04:50:41 +00:00
Romain Jobredeaux
2919797aaa Enable Java in mixed builds.
Allowlist manual BUILD files in prebuilts/bazel for
the toolchain setup.

Test: b build build/bazel/examples/java/...
Change-Id: Id649dce631731e5396da4a9fe224e33f8949dd7d
Bug: 196441639
2022-07-17 19:38:23 -07:00
Paul Duffin
b262f883a9 Merge "Use implementation jar for updatable-media in snapshot for S" 2022-07-15 22:32:58 +00:00
Bob Badour
eea1696332 Merge "Keep Notice property from erasing license texts." 2022-07-15 21:24:03 +00:00
Paul Duffin
1364891fad Use implementation jar for updatable-media in snapshot for S
While enabling prebuilts in T we hit b/229932396 which was caused by
some parts of the build depending on the prebuilt updatable-media jar
which used to be a full implementation jar but which is now an invalid
jar as the snapshot must not be including implementation details. We
fixed the issue in T but we are hitting the same problem in S with the
M-2022-07.

That is the first train in which the prebuilt updatable-media module
provides an invalid jar, prior to that it was always providing an
implementation jar. This change tweaks the sdk snapshot generation
code to use an implementation jar for updatable-media in the S
snapshot to avoid partners having to cherry pick changes similar to
those needed to fix b/229932396 in T.

Bug: 239121291
Test: packages/modules/common/build/mainline_modules_sdks.sh
      # Check that S media snapshot includes implementation jar.
      # Check that S art snapshot includes invalid jar.
      # Check that T media snapshot includes invalid jar.
Change-Id: Ib49484d00a60b4ed7f8268e04f9c10a3498edb56
2022-07-15 17:23:10 +00:00
Yi Kong
cc3ad51a36 Merge changes from topic "llvm-stable-r458507"
* changes:
  [bindgen] Allow unrecognised -Wno-* flags on LLVM_NEXT
  Add extra cflags for LLVM_NEXT
2022-07-15 07:30:57 +00:00
Christopher Ferris
70019a90be Merge "Add ability to force compile as 64 bit." 2022-07-14 22:28:37 +00:00
Christopher Ferris
98f102269d Add ability to force compile as 64 bit.
When trying to build a single 64 bit and 32 bit image, there are
a few executables that are prefer32. When set, this will force all
of those targets to be compiled as 64 bit.

Test: With this option, drmserver/mediaserver are built as 64 bit.
Test: Without this option, drmserver/mediaserver are built as 32 bit.
Change-Id: I1c3dbe229f9b612ff76b857ca7163b14e7dc92c5
2022-07-14 13:34:14 -07:00
Bob Badour
9f847581b7 Keep Notice property from erasing license texts.
Remove "default to file in directory". Use explicit applicable license.

Bug: 192434786

Test: m droid dist

Change-Id: Id3d845b2073f151a8c0bad874e7ab005771bdfcb
2022-07-14 10:40:01 -07:00
Cory Barker
b1c8940be1 Merge "Adding support for building AFLpp Test: Build AFL fuzzers locally and ran them" 2022-07-14 16:26:41 +00:00
Yi Kong
4f664e9128 [bindgen] Allow unrecognised -Wno-* flags on LLVM_NEXT
Test: LLVM_NEXT=true m
Bug: 236798112
Change-Id: I5d1625a30d7271c94cba71347f17fbcb0b87f4ae
2022-07-14 12:38:06 +00:00