From 22b2d6817021560d67fa1fca813287a0c864a1c6 Mon Sep 17 00:00:00 2001 From: Tri Vo Date: Tue, 11 Jul 2017 12:53:12 -0700 Subject: [PATCH] Build automotive hals with VNDK. Bug: 37342627 Test: cd hardware/interfaces/automotive && BOARD_VNDK_VERSION=current mma -j64 -k Change-Id: I89e9af8a5fded3a31eedb9942cfba8e8d9614f53 --- CleanSpec.mk | 6 +++++- automotive/vehicle/2.0/default/Android.bp | 7 ++++++- .../vehicle/2.0/default/impl/vhal_v2_0/proto/Android.bp | 1 + automotive/vehicle/2.1/default/Android.bp | 4 +++- 4 files changed, 15 insertions(+), 3 deletions(-) diff --git a/CleanSpec.mk b/CleanSpec.mk index 01b5e7b7f9..91515abba9 100644 --- a/CleanSpec.mk +++ b/CleanSpec.mk @@ -55,4 +55,8 @@ $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/etc/init/android.hardware.bl $(call add-clean-step, rm -rf $(OUT)/soong/.intermediates/) $(call add-clean-step, rm -rf $(OUT_DIR)/soong/.intermediates/hardware/interfaces/) $(call add-clean-step, rm -rf $(OUT_DIR)/soong/.intermediates/hardware/interfaces/) -$(call add-clean-step, find $(PRODUCT_OUT)/system $(PRODUCT_OUT)/vendor -type f -name "android\.hardware\.configstore*" -print0 | xargs -0 rm -f) \ No newline at end of file +$(call add-clean-step, find $(PRODUCT_OUT)/system $(PRODUCT_OUT)/vendor -type f -name "android\.hardware\.configstore*" -print0 | xargs -0 rm -f) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/bin/hw/android.hardware.automotive*) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/lib/hw/android.hardware.automotive*) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/lib64/hw/android.hardware.automotive*) +$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/etc/init/android.hardware.automotive*) diff --git a/automotive/vehicle/2.0/default/Android.bp b/automotive/vehicle/2.0/default/Android.bp index 6d3e902ffa..3e3ff2c852 100644 --- a/automotive/vehicle/2.0/default/Android.bp +++ b/automotive/vehicle/2.0/default/Android.bp @@ -30,12 +30,14 @@ cc_defaults { cc_library_headers { name: "vhal_v2_0_common_headers", + vendor: true, export_include_dirs: ["common/include/vhal_v2_0"], } // Vehicle reference implementation lib cc_library_static { name: "android.hardware.automotive.vehicle@2.0-manager-lib", + vendor: true, defaults: ["vhal_v2_0_defaults"], srcs: [ "common/src/SubscriptionManager.cpp", @@ -50,6 +52,7 @@ cc_library_static { cc_library_shared { name: "android.hardware.automotive.vehicle@2.0-manager-lib-shared", + vendor: true, static_libs: ["android.hardware.automotive.vehicle@2.0-manager-lib"], export_static_lib_headers: ["android.hardware.automotive.vehicle@2.0-manager-lib"], } @@ -57,6 +60,7 @@ cc_library_shared { // Vehicle default VehicleHAL implementation cc_library_static { name: "android.hardware.automotive.vehicle@2.0-default-impl-lib", + vendor: true, defaults: ["vhal_v2_0_defaults"], srcs: [ "impl/vhal_v2_0/EmulatedVehicleHal.cpp", @@ -79,6 +83,7 @@ cc_library_static { cc_test { name: "android.hardware.automotive.vehicle@2.0-manager-unit-tests", + vendor: true, defaults: ["vhal_v2_0_defaults"], whole_static_libs: ["android.hardware.automotive.vehicle@2.0-manager-lib"], srcs: [ @@ -95,7 +100,7 @@ cc_binary { name: "android.hardware.automotive.vehicle@2.0-service", defaults: ["vhal_v2_0_defaults"], init_rc: ["android.hardware.automotive.vehicle@2.0-service.rc"], - proprietary: true, + vendor: true, relative_install_path: "hw", srcs: ["VehicleService.cpp"], shared_libs: [ diff --git a/automotive/vehicle/2.0/default/impl/vhal_v2_0/proto/Android.bp b/automotive/vehicle/2.0/default/impl/vhal_v2_0/proto/Android.bp index 7d68f9e4cd..ec352000c6 100644 --- a/automotive/vehicle/2.0/default/impl/vhal_v2_0/proto/Android.bp +++ b/automotive/vehicle/2.0/default/impl/vhal_v2_0/proto/Android.bp @@ -15,6 +15,7 @@ // Vehicle HAL Protobuf library cc_library_static { name: "android.hardware.automotive.vehicle@2.0-libproto-native", + vendor: true, proto: { export_proto_headers: true, type: "lite", diff --git a/automotive/vehicle/2.1/default/Android.bp b/automotive/vehicle/2.1/default/Android.bp index 0697767927..f6743f261f 100644 --- a/automotive/vehicle/2.1/default/Android.bp +++ b/automotive/vehicle/2.1/default/Android.bp @@ -24,6 +24,7 @@ cc_defaults { // Vehicle reference implementation lib cc_library_static { name: "android.hardware.automotive.vehicle@2.1-manager-lib", + vendor: true, defaults: ["vhal_v2_1_defaults"], srcs: [ "common/src/Obd2SensorStore.cpp", @@ -36,6 +37,7 @@ cc_library_static { // Vehicle default VehicleHAL implementation cc_library_static { name: "android.hardware.automotive.vehicle@2.1-default-impl-lib", + vendor: true, defaults: ["vhal_v2_1_defaults"], srcs: [ "impl/vhal_v2_1/EmulatedVehicleHal.cpp", @@ -65,7 +67,7 @@ cc_binary { name: "android.hardware.automotive.vehicle@2.1-service", defaults: ["vhal_v2_1_defaults"], init_rc: ["android.hardware.automotive.vehicle@2.1-service.rc"], - proprietary: true, + vendor: true, relative_install_path: "hw", srcs: ["service.cpp"], whole_static_libs: ["android.hardware.automotive.vehicle@2.0-libproto-native"],