Android.bp 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. // 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. cc_defaults {
  15. name: "libhidl-defaults",
  16. cflags: [
  17. "-Wall",
  18. "-Wdocumentation", // since some users use this
  19. "-Werror",
  20. "-Wextra-semi",
  21. ],
  22. }
  23. cc_test {
  24. name: "libhidl_test",
  25. defaults: ["libhidl-defaults"],
  26. gtest: false,
  27. srcs: ["test_main.cpp"],
  28. test_suites: ["device-tests"],
  29. shared_libs: [
  30. "[email protected]",
  31. "libbase",
  32. "libhidlbase",
  33. "libhidltransport",
  34. "libhwbinder",
  35. "liblog",
  36. "libutils",
  37. "libcutils",
  38. ],
  39. static_libs: ["libgtest", "libgmock"],
  40. cflags: [
  41. "-O0",
  42. "-g",
  43. ],
  44. }
  45. cc_defaults {
  46. name: "libhidlbase-combined-impl",
  47. defaults: [
  48. "libhwbinder-impl-shared-libs",
  49. "libhidlbase-impl-shared-libs",
  50. "libhidltransport-impl-shared-libs",
  51. ],
  52. whole_static_libs: [
  53. "libhidlbase-impl-internal",
  54. "libhidltransport-impl-internal",
  55. ],
  56. }
  57. cc_library {
  58. name: "libhidlbase",
  59. defaults: ["libhidlbase-combined-impl"],
  60. recovery_available: true,
  61. vendor_available: true,
  62. vndk: {
  63. enabled: true,
  64. support_system_process: true,
  65. },
  66. whole_static_libs: [
  67. "libhwbinder-impl-internal",
  68. ],
  69. }
  70. // Only libhwbinder_benchmark needs to have pgo enabled. When all places
  71. // support having PGO selectively enabled, all places can use libhwbinder.
  72. //
  73. // http://b/77320844
  74. cc_library {
  75. name: "libhidlbase_pgo",
  76. defaults: [
  77. "libhidlbase-combined-impl",
  78. "hwbinder_benchmark_pgo",
  79. ],
  80. whole_static_libs: [
  81. "libhwbinder_pgo-impl-internal",
  82. ],
  83. }
  84. // WARNING: deprecated
  85. // This library is no longer required, and dependencies should be taken
  86. // on libhidlbase instead.
  87. cc_library {
  88. name: "libhidltransport",
  89. recovery_available: true,
  90. vendor_available: true,
  91. vndk: {
  92. enabled: true,
  93. support_system_process: true,
  94. },
  95. }