[go: nahoru, domu]

blob: ec1f5ac8d71821b85ce09dbb9aca79a8c3d89b13 [file] [log] [blame]
Dan Willemsen1418c822016-08-26 17:39:37 -07001//
2// Copyright (C) 2010 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
Bob Badour091b5e12021-02-12 18:21:27 -080017package {
18 default_applicable_licenses: ["external_speex_license"],
19}
20
21// Added automatically by a large-scale-change that took the approach of
22// 'apply every license found to every target'. While this makes sure we respect
23// every license restriction, it may not be entirely correct.
24//
25// e.g. GPL in an MIT project might only apply to the contrib/ directory.
26//
27// Please consider splitting the single license below into multiple licenses,
28// taking care not to lose any license_kind information, and overriding the
29// default license using the 'licenses: [...]' property on targets as needed.
30//
31// For unused files, consider creating a 'fileGroup' with "//visibility:private"
32// to attach the license to, and including a comment whether the files may be
33// used in the current project.
34// See: http://go/android-license-faq
35license {
36 name: "external_speex_license",
37 visibility: [":__subpackages__"],
38 license_kinds: [
39 "SPDX-license-identifier-BSD",
40 "SPDX-license-identifier-MIT",
41 "legacy_notice",
42 "legacy_unencumbered",
43 ],
44 license_text: [
45 "COPYING",
46 ],
47}
48
Dan Willemsen1418c822016-08-26 17:39:37 -070049cc_library_shared {
50 name: "libspeexresampler",
51
Vijay Venkatraman338925a2017-05-15 12:45:14 -070052 vendor_available: true,
Justin Yun1d16c712020-11-11 18:25:17 +090053 product_available: true,
Justin Yun90cbedc2017-07-24 15:19:44 +090054 vndk: {
55 enabled: true,
56 },
Jooyung Hanc6bfa252019-01-18 15:46:12 +090057 double_loadable: true,
Jooyung Hanf11c3bb2020-05-21 22:44:13 +090058 apex_available: [
59 "//apex_available:platform",
60 "com.android.media",
61 "com.android.media.swcodec",
62 ],
63 min_sdk_version: "29",
64
Dan Willemsen1418c822016-08-26 17:39:37 -070065 arch: {
66 arm: {
67 instruction_set: "arm",
68
Isaac Chenc1e9d192017-09-12 17:03:09 +080069 neon: {
Dan Willemsen1418c822016-08-26 17:39:37 -070070 cflags: ["-D_USE_NEON"],
71 },
72 },
73 },
Elliott Hughesaf8bb902018-06-26 16:57:59 -070074 srcs: ["libspeexdsp/resample.c"],
Dan Willemsen1418c822016-08-26 17:39:37 -070075
76 cflags: [
Elliott Hughesaf8bb902018-06-26 16:57:59 -070077 "-DEXPORT=__attribute__((visibility(\"default\")))",
Dan Willemsen1418c822016-08-26 17:39:37 -070078 "-DFIXED_POINT",
Elliott Hughesaf8bb902018-06-26 16:57:59 -070079 "-DHAVE_STDINT_H",
80 "-DRESAMPLE_FULL_SINC_TABLE",
Dan Willemsen1418c822016-08-26 17:39:37 -070081 "-O3",
82 "-fstrict-aliasing",
83 "-fprefetch-loop-arrays",
Chih-Hung Hsieh13db9822017-09-29 11:20:06 -070084 "-Wall",
85 "-Werror",
Elliott Hughes6f971cb2018-03-29 22:00:08 -070086 "-Wno-sign-compare",
Elliott Hughesaf8bb902018-06-26 16:57:59 -070087 "-Wno-unused-parameter",
Dan Willemsen1418c822016-08-26 17:39:37 -070088 ],
89
90 local_include_dirs: ["include"],
91 export_include_dirs: ["include"],
Ivan Lozano305f9622018-07-10 13:23:52 -070092 sanitize: {
93 integer_overflow: true,
Ivan Lozano3f8778f2018-10-04 14:55:56 -070094 misc_undefined: ["bounds"],
Ivan Lozano305f9622018-07-10 13:23:52 -070095 },
Dan Willemsen1418c822016-08-26 17:39:37 -070096}