From abe2fea38b2431edd9a18d59914aea281230f89c Mon Sep 17 00:00:00 2001 From: Mattijs Korpershoek Date: Thu, 12 Oct 2023 12:20:00 +0200 Subject: Revert "android: mm: Stub libhardware for build tests" The VNDK, which is included as a subproject can provide libhardware. Remove the stub and use the VNDK instead. This reverts commit b9ecd85ed1fee2e9d715368b24592ad3009131d8. Signed-off-by: Mattijs Korpershoek --- src/android/mm/libhardware_stub.c | 17 ----------------- src/android/mm/meson.build | 12 ++++-------- 2 files changed, 4 insertions(+), 25 deletions(-) delete mode 100644 src/android/mm/libhardware_stub.c diff --git a/src/android/mm/libhardware_stub.c b/src/android/mm/libhardware_stub.c deleted file mode 100644 index 00f15cd9..00000000 --- a/src/android/mm/libhardware_stub.c +++ /dev/null @@ -1,17 +0,0 @@ -/* SPDX-License-Identifier: Apache-2.0 */ -/* - * Copyright (C) 2023, Ideas on Board - * - * libhardware_stub.c - Android libhardware stub for test compilation - */ - -#include - -#include - -int hw_get_module(const char *id __attribute__((__unused__)), - const struct hw_module_t **module) -{ - *module = NULL; - return -ENOTSUP; -} diff --git a/src/android/mm/meson.build b/src/android/mm/meson.build index e3e0484c..85f12f91 100644 --- a/src/android/mm/meson.build +++ b/src/android/mm/meson.build @@ -4,14 +4,10 @@ platform = get_option('android_platform') if platform == 'generic' android_hal_sources += files(['generic_camera_buffer.cpp', 'generic_frame_buffer_allocator.cpp']) - android_deps += [libdl] - - libhardware = dependency('libhardware', required : false) - if libhardware.found() - android_deps += [libhardware] - else - android_hal_sources += files(['libhardware_stub.c']) - endif + android_deps += [ + libdl, + dependency('libhardware'), + ] elif platform == 'cros' android_hal_sources += files(['cros_camera_buffer.cpp', 'cros_frame_buffer_allocator.cpp']) -- cgit v1.2.1