blob: a466adb4eee4f9ca8625f5d82b8ab0794b72afa0 [file] [log] [blame]
Santiago Etchebehereac7512d2021-03-04 18:26:29 -08001//
2// Copyright (C) 2021 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8// http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15//
16
17//
18// Build rule for WallpaperPicker2 dependencies lib.
19//
Bob Badour2021dd72021-03-19 03:57:19 -070020package {
21 default_applicable_licenses: ["Android-Apache-2.0"],
22}
23
Santiago Etchebehereac7512d2021-03-04 18:26:29 -080024android_library {
25 name: "wallpaper-common-deps",
26
27 static_libs: [
28 "androidx.appcompat_appcompat",
29 "androidx.cardview_cardview",
30 "androidx.exifinterface_exifinterface",
31 "androidx.recyclerview_recyclerview",
32 "androidx.slice_slice-view",
33 "androidx-constraintlayout_constraintlayout",
34 "com.google.android.material_material",
35 "glide-prebuilt",
36 "libbackup",
37 "subsampling-scale-image-view",
38 "SystemUISharedLib",
39 "volley",
40 ],
41
42 resource_dirs: ["res"],
43
44 optimize: {
45 enabled: false,
46 },
47
48 sdk_version: "current",
49
50 manifest: "AndroidManifest-empty.xml",
51
52 visibility: [
53 ":__subpackages__",
54 "//packages/apps/ThemePicker",
55 "//vendor:__subpackages__",
56 ],
57}
58
59filegroup {
60 name: "WallpaperPicker2_srcs",
61 srcs: [
62 "src/**/*.java",
63 "src/**/*.kt",
64 ],
65}
66
67genrule {
68 name: "WallpaperPicker2_res",
69 tools: ["soong_zip"],
70 srcs: [
71 "res/**/*"
72 ],
73 out: ["wallpaperpicker2_res.zip"],
74 cmd: "INPUTS=($(in)) && "
75 + "RES_DIR=$$(dirname $$(dirname $${INPUTS[0]})) && "
76 + "$(location soong_zip) -o $(out) -C $$RES_DIR -D $$RES_DIR && "
77 + "cp $(out) ."
78}
79
80java_defaults {
81 name: "WallpaperPicker2_defaults",
82
83 static_libs: [
84 "wallpaper-common-deps",
85 ],
86
87 srcs: [
88 ":WallpaperPicker2_srcs",
89 "src_override/**/*.java",
90 "src_override/**/*.kt",
91 ],
92 resource_zips: [":WallpaperPicker2_res"],
93
94 certificate: "",
95
96 optimize: {
97 enabled: false,
98 },
99
100 privileged: true,
101 system_ext_specific: true,
102
103 use_embedded_native_libs: true,
104
105 manifest: "AndroidManifest.xml",
106}
107
108//
109// Build app code.
110//
111android_app {
112 name: "WallpaperPicker2",
113
114 defaults: ["WallpaperPicker2_defaults"],
115
116 platform_apis: true,
117}