blob: 58f339e3f0c6f32cae38e71bd37aab6b2f9eaa92 [file] [log] [blame]
Bob Badourcb4f9672021-02-12 21:28:10 -08001package {
2 default_applicable_licenses: ["external_tremolo_license"],
3}
4
5// Added automatically by a large-scale-change that took the approach of
6// 'apply every license found to every target'. While this makes sure we respect
7// every license restriction, it may not be entirely correct.
8//
9// e.g. GPL in an MIT project might only apply to the contrib/ directory.
10//
11// Please consider splitting the single license below into multiple licenses,
12// taking care not to lose any license_kind information, and overriding the
13// default license using the 'licenses: [...]' property on targets as needed.
14//
15// For unused files, consider creating a 'fileGroup' with "//visibility:private"
16// to attach the license to, and including a comment whether the files may be
17// used in the current project.
18// See: http://go/android-license-faq
19license {
20 name: "external_tremolo_license",
21 visibility: [":__subpackages__"],
22 license_kinds: [
23 "SPDX-license-identifier-Apache-2.0",
24 "SPDX-license-identifier-BSD",
25 ],
26 license_text: [
27 "NOTICE",
28 ],
29}
30
Dongwon Kang4dd4aad2017-10-19 13:28:13 -070031cc_library {
Colin Cross3b636642017-04-20 13:01:17 -070032 name: "libvorbisidec",
Jiyong Park6fb7d062017-08-07 13:16:05 +090033 vendor_available: true,
Ayushi Khopkar31a0aa82020-04-06 17:16:28 +053034 host_supported: true,
Colin Cross3b636642017-04-20 13:01:17 -070035
36 srcs: [
37 "Tremolo/bitwise.c",
38 "Tremolo/codebook.c",
39 "Tremolo/dsp.c",
40 "Tremolo/floor0.c",
41 "Tremolo/floor1.c",
42 "Tremolo/floor_lookup.c",
43 "Tremolo/framing.c",
44 "Tremolo/mapping0.c",
45 "Tremolo/mdct.c",
46 "Tremolo/misc.c",
47 "Tremolo/res012.c",
48 "Tremolo/treminfo.c",
49 "Tremolo/vorbisfile.c",
50 ],
51
52 arch: {
53 arm: {
54 srcs: [
55 "Tremolo/bitwiseARM.s",
56 "Tremolo/dpen.s",
57 "Tremolo/floor1ARM.s",
58 "Tremolo/mdctARM.s",
59 ],
60 cflags: ["-D_ARM_ASSEM_"],
61 // Assembly code in asm_arm.h does not compile with Clang.
62 clang_asflags: ["-no-integrated-as"],
63
64 instruction_set: "arm",
65 },
66 arm64: {
67 cflags: ["-DONLY_C"],
68 },
Colin Cross3b636642017-04-20 13:01:17 -070069 x86: {
70 cflags: ["-DONLY_C"],
71 },
72 x86_64: {
73 cflags: ["-DONLY_C"],
74 },
75 },
76
77 cflags: [
78 "-O2",
79 "-D_GNU_SOURCE",
Marco Nelissen92fe92d2017-05-11 08:26:37 -070080 "-funsigned-char",
Chih-Hung Hsiehc59d2d72017-09-29 11:32:51 -070081 "-Wall",
82 "-Werror",
83 "-Wno-unused-variable",
Colin Cross3b636642017-04-20 13:01:17 -070084 ],
85
86 local_include_dirs: ["Tremolo"],
87 export_include_dirs: ["."],
88
89 shared_libs: ["liblog"],
Ivan Lozano1f2a6d82018-07-10 13:03:38 -070090
91 sanitize: {
92 integer_overflow: true,
Ivan Lozanoa3eae7a2018-10-04 14:56:52 -070093 misc_undefined: ["bounds"],
Ivan Lozano1f2a6d82018-07-10 13:03:38 -070094 },
Ayushi Khopkar31a0aa82020-04-06 17:16:28 +053095
96 target: {
97 darwin: {
98 enabled: false,
99 },
100 },
Jooyung Han1c8ab972020-04-16 18:48:31 +0900101 min_sdk_version: "29",
Colin Cross3b636642017-04-20 13:01:17 -0700102}