blob: 67cd8754a3c74249e9d34ccf710c1baba626d165 [file] [log] [blame]
Dan Albert0fbb5322016-10-04 17:49:33 -07001// Copyright (C) 2016 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
Jesse Hallb9d7b812019-04-12 16:05:37 -070015// Headers module is in external/vulkan-headers/Android.bp.
Bob Badour3c538232021-02-12 21:26:48 -080016package {
17 // See: http://go/android-license-faq
18 // A large-scale-change added 'default_applicable_licenses' to import
19 // all of the 'license_kinds' from "frameworks_native_license"
20 // to get the below license kinds:
21 // SPDX-license-identifier-Apache-2.0
22 default_applicable_licenses: ["frameworks_native_license"],
23}
24
Dan Albert0fbb5322016-10-04 17:49:33 -070025ndk_library {
Dan Willemsen219db6c2017-04-07 15:48:39 -070026 name: "libvulkan",
Dan Albert0fbb5322016-10-04 17:49:33 -070027 symbol_file: "libvulkan.map.txt",
28 first_version: "24",
Dan Albertb9c62a62017-01-05 15:58:50 -080029 unversioned_until: "current",
Dan Albert0fbb5322016-10-04 17:49:33 -070030}
Colin Cross7884c192016-12-05 13:26:22 -080031
Jesse Hall408eda02019-04-12 15:39:16 -070032llndk_library {
Colin Cross8af6d1c2020-10-19 13:38:00 -070033 name: "libvulkan.llndk",
Jesse Hall408eda02019-04-12 15:39:16 -070034 symbol_file: "libvulkan.map.txt",
35 export_llndk_headers: [
36 "vulkan_headers_llndk",
37 ],
38}
39
Colin Cross7884c192016-12-05 13:26:22 -080040cc_library_shared {
41 name: "libvulkan",
Colin Cross8af6d1c2020-10-19 13:38:00 -070042 llndk_stubs: "libvulkan.llndk",
Colin Cross7884c192016-12-05 13:26:22 -080043 clang: true,
44 sanitize: {
45 misc_undefined: ["integer"],
46 },
47
48 cflags: [
49 "-DLOG_TAG=\"vulkan\"",
50 "-DVK_USE_PLATFORM_ANDROID_KHR",
51 "-DVK_NO_PROTOTYPES",
52 "-fvisibility=hidden",
53 "-fstrict-aliasing",
Colin Cross1383d9f2019-11-06 13:33:40 -080054 "-Wextra",
Colin Cross7884c192016-12-05 13:26:22 -080055 "-Werror",
56 "-Wno-padded",
Colin Cross1383d9f2019-11-06 13:33:40 -080057 "-Wno-sign-compare",
Colin Cross7884c192016-12-05 13:26:22 -080058 "-Wno-switch-enum",
Colin Cross1383d9f2019-11-06 13:33:40 -080059 "-Wno-unused-variable",
60 "-Wno-unused-function",
Colin Cross7884c192016-12-05 13:26:22 -080061
dimitrya7cc50d2018-12-10 17:06:07 +010062 // Have clang emit complete debug_info.
63 "-fstandalone-debug",
64
Colin Cross7884c192016-12-05 13:26:22 -080065 //"-DLOG_NDEBUG=0",
66 ],
67
68 cppflags: [
Colin Cross7884c192016-12-05 13:26:22 -080069 "-Wno-c99-extensions",
70 "-Wno-c++98-compat-pedantic",
71 "-Wno-exit-time-destructors",
Dan Stoza71bded52016-10-19 11:10:33 -070072 "-Wno-float-equal",
Colin Cross7884c192016-12-05 13:26:22 -080073 "-Wno-global-constructors",
74 "-Wno-zero-length-array",
75 ],
76
77 srcs: [
78 "api.cpp",
79 "api_gen.cpp",
80 "debug_report.cpp",
81 "driver.cpp",
82 "driver_gen.cpp",
83 "layers_extensions.cpp",
84 "stubhal.cpp",
85 "swapchain.cpp",
Colin Cross7884c192016-12-05 13:26:22 -080086 ],
87
Stephen Kiazyke77dce22017-03-14 15:38:12 -070088 header_libs: [
Jesse Hall408eda02019-04-12 15:39:16 -070089 "hwvulkan_headers",
Paul Duffin08026182019-09-12 15:01:28 +010090 "libnativeloader-headers",
Colin Cross7884c192016-12-05 13:26:22 -080091 "vulkan_headers",
Sundong Ahnbc37dd52020-04-23 21:21:00 +090092 "libsurfaceflinger_headers",
Colin Cross7884c192016-12-05 13:26:22 -080093 ],
Jesse Hall408eda02019-04-12 15:39:16 -070094 export_header_lib_headers: ["vulkan_headers"],
Colin Cross7884c192016-12-05 13:26:22 -080095 shared_libs: [
Courtney Goeltzenleuchter7671d462018-01-24 11:51:01 -080096 "android.hardware.configstore@1.0",
97 "android.hardware.configstore-utils",
Jaekyun Seokd56dec82016-11-25 16:20:40 +090098 "libziparchive",
Colin Cross7884c192016-12-05 13:26:22 -080099 "libhardware",
100 "libsync",
101 "libbase",
Courtney Goeltzenleuchter7671d462018-01-24 11:51:01 -0800102 "libhidlbase",
Colin Cross7884c192016-12-05 13:26:22 -0800103 "liblog",
Mathias Agopian991d2542017-02-06 13:51:32 -0800104 "libui",
Jiyong Park27c39e12017-05-08 13:00:02 +0900105 "libgraphicsenv",
Colin Cross7884c192016-12-05 13:26:22 -0800106 "libutils",
107 "libcutils",
108 "libz",
Jiyong Park2d81f3c2019-01-29 00:36:19 +0900109 "libnativebridge_lazy",
110 "libnativeloader_lazy",
Brian Andersondc96fdf2017-03-20 16:54:25 -0700111 "libnativewindow",
Yiwei Zhang06c66fb2020-10-14 08:42:26 -0700112 "libvndksupport",
Daniel Kochf25f5bb2017-10-05 00:26:58 -0400113 "android.hardware.graphics.common@1.0",
Sundong Ahnbc37dd52020-04-23 21:21:00 +0900114 "libSurfaceFlingerProp",
Colin Cross7884c192016-12-05 13:26:22 -0800115 ],
Jesse Hall79927812017-03-23 11:03:23 -0700116 static_libs: ["libgrallocusage"],
Colin Cross7884c192016-12-05 13:26:22 -0800117}