diff options
author | Romain Jobredeaux <jobredeaux@google.com> | 2023-04-17 22:03:11 +0000 |
---|---|---|
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | 2023-04-17 22:03:11 +0000 |
commit | 8cfa27a8ba0254670dd358f462e6e199c4622850 (patch) | |
tree | 511605b77ecb290a4ec8bec4c91c2ed27d3b6f54 /rules/android/aar_import_aosp_internal/rule.bzl | |
parent | c0f340770a579bbc78696b514b8ad866f59b5db0 (diff) | |
parent | c3104659bb20f00e8733b48e3b7612da39a0eb15 (diff) | |
download | bazel-8cfa27a8ba0254670dd358f462e6e199c4622850.tar.gz |
Merge "Allow sdk transition wrappers in exports of aar_import." am: 146e4150d3 am: c3104659bb
Original change: https://android-review.googlesource.com/c/platform/build/bazel/+/2537759
Change-Id: I00ce03ef3aa02cc9bb41e54cb75fc85ff6f11cdc
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
Diffstat (limited to 'rules/android/aar_import_aosp_internal/rule.bzl')
-rw-r--r-- | rules/android/aar_import_aosp_internal/rule.bzl | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/rules/android/aar_import_aosp_internal/rule.bzl b/rules/android/aar_import_aosp_internal/rule.bzl new file mode 100644 index 00000000..79580f2a --- /dev/null +++ b/rules/android/aar_import_aosp_internal/rule.bzl @@ -0,0 +1,33 @@ +# Copyright (C) 2023 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""aar_import rule.""" + +load(":attrs.bzl", _ATTRS = "ATTRS") +load("@rules_android//rules/aar_import:impl.bzl", _impl = "impl") +load("@rules_android//rules/aar_import:rule.bzl", "RULE_DOC") + +aar_import = rule( + attrs = _ATTRS, + fragments = ["android"], + implementation = _impl, + doc = RULE_DOC, + provides = [ + AndroidIdeInfo, + AndroidLibraryResourceClassJarProvider, + AndroidNativeLibsInfo, + JavaInfo, + ], + toolchains = ["@rules_android//toolchains/android:toolchain_type"], +) |