blob: d3130574ea50e6ef6b7aa188ce5c1e98e812bad6 [file] [log] [blame]
Paul Duffin8150da62019-12-16 17:21:27 +00001// Copyright (C) 2019 The Android Open Source Project
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15package sdk
16
17import "android/soong/android"
18
19func init() {
20 android.RegisterModuleType("module_exports", ModuleExportsFactory)
21 android.RegisterModuleType("module_exports_snapshot", ModuleExportsSnapshotsFactory)
22}
23
24// module_exports defines the exports of a mainline module. The exports are Soong modules
25// which are required by Soong modules that are not part of the mainline module.
26func ModuleExportsFactory() android.Module {
Paul Duffine6029182019-12-16 17:43:48 +000027 return newSdkModule(true)
Paul Duffin8150da62019-12-16 17:21:27 +000028}
29
30// module_exports_snapshot is a versioned snapshot of prebuilt versions of all the exports
31// of a mainline module.
32func ModuleExportsSnapshotsFactory() android.Module {
Paul Duffine6029182019-12-16 17:43:48 +000033 s := newSdkModule(true)
Paul Duffin8150da62019-12-16 17:21:27 +000034 s.properties.Snapshot = true
Paul Duffin8150da62019-12-16 17:21:27 +000035 return s
36}