• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1//
2// Copyright (C) 2019 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
17package {
18    // See: http://go/android-license-faq
19    // A large-scale-change added 'default_applicable_licenses' to import
20    // all of the 'license_kinds' from "packages_providers_MediaProvider_license"
21    // to get the below license kinds:
22    //   SPDX-license-identifier-Apache-2.0
23    default_applicable_licenses: ["packages_providers_MediaProvider_license"],
24}
25
26cc_library_shared {
27    name: "libfuse_jni",
28
29    srcs: [
30        "jni_init.cpp",
31        "com_android_providers_media_FuseDaemon.cpp",
32        "FuseDaemon.cpp",
33        "FuseUtils.cpp",
34        "MediaProviderWrapper.cpp",
35        "ReaddirHelper.cpp",
36        "RedactionInfo.cpp",
37        "node.cpp"
38    ],
39
40    header_libs: [
41        "libnativehelper_header_only",
42    ],
43
44    export_include_dirs: ["include"],
45
46    shared_libs: [
47        "liblog",
48        "libfuse",
49        "libandroid"
50    ],
51
52    static_libs: [
53        "libbase_ndk",
54    ],
55
56    cflags: [
57        "-Wall",
58        "-Werror",
59        "-Wno-unused-parameter",
60        "-Wno-unused-variable",
61        "-Wthread-safety",
62
63        "-D_FILE_OFFSET_BITS=64",
64        "-DFUSE_USE_VERSION=34",
65    ],
66
67    tidy: true,
68    tidy_checks: [
69        "-google-runtime-int",
70    ],
71
72    sdk_version: "current",
73    stl: "c++_static",
74    min_sdk_version: "30",
75}
76
77cc_test {
78    name: "fuse_node_test",
79    test_suites: ["device-tests", "mts-mediaprovider"],
80    test_config: "fuse_node_test.xml",
81
82    compile_multilib: "both",
83    multilib: {
84        lib32: { suffix: "32", },
85        lib64: { suffix: "64", },
86    },
87
88    srcs: [
89        "node_test.cpp",
90        "node.cpp",
91        "ReaddirHelper.cpp",
92        "RedactionInfo.cpp",
93    ],
94
95    local_include_dirs: ["include"],
96
97    static_libs: [
98        "libbase_ndk",
99    ],
100
101    shared_libs: [
102        "liblog",
103    ],
104
105    tidy: true,
106
107    sdk_version: "current",
108    stl: "c++_static",
109}
110
111cc_test {
112    name: "RedactionInfoTest",
113    test_suites: ["device-tests", "mts-mediaprovider"],
114    test_config: "RedactionInfoTest.xml",
115
116    compile_multilib: "both",
117    multilib: {
118        lib32: { suffix: "32", },
119        lib64: { suffix: "64", },
120    },
121
122    srcs: [
123        "RedactionInfoTest.cpp",
124        "RedactionInfo.cpp",
125    ],
126
127    local_include_dirs: ["include"],
128
129    static_libs: [
130        "libbase_ndk",
131    ],
132
133    shared_libs: [
134        "liblog",
135    ],
136
137    tidy: true,
138
139    sdk_version: "current",
140    stl: "c++_static",
141}
142
143cc_test {
144    name: "FuseUtilsTest",
145    test_suites: ["device-tests", "mts-mediaprovider"],
146    test_config: "FuseUtilsTest.xml",
147
148    compile_multilib: "both",
149    multilib: {
150        lib32: { suffix: "32", },
151        lib64: { suffix: "64", },
152    },
153
154    srcs: [
155        "FuseUtilsTest.cpp",
156        "FuseUtils.cpp",
157    ],
158
159    header_libs: [
160        "libnativehelper_header_only",
161    ],
162
163    local_include_dirs: ["include"],
164
165    static_libs: [
166        "libbase_ndk",
167    ],
168
169    shared_libs: [
170        "liblog",
171    ],
172
173    tidy: true,
174
175    sdk_version: "current",
176    stl: "c++_static",
177}
178