Camera: Update camera service to use new HIDL HALs, part 1
- Add CameraProviderManager
- Enumerates individual camera provider HAL instances, as well
as the devices they provide
- Handles dynamic provider and device appearance/disappearance
- Maps device names to public API namespace
- Add unit tests for CameraProviderManager
- Add logic to enable new HIDL path
- Switch various bits of service internals to use string camera IDs,
though leaving most camera1-facing bits using int IDs, since that's
what the old API uses.
- Update CameraService to use CameraProviderManager instead of
the legacy camera HAL
- Update clients to pass through provider manager to devices instead
of just camera module
- Still TODO:
- Update Camera3Device to use new HIDL interface
- Update CameraHardwareInterface to use new HIDL interface
- Update dump()
- Update vendor tag handling
Test: New unit tests pass, camera CTS passes with Treble disabled
Bug: 30985004
Bug: 32991422
Change-Id: I7ac41f13b9501d5e53256e28c0465ec70aa3980e
diff --git a/services/camera/libcameraservice/tests/Android.mk b/services/camera/libcameraservice/tests/Android.mk
new file mode 100644
index 0000000..179643b
--- /dev/null
+++ b/services/camera/libcameraservice/tests/Android.mk
@@ -0,0 +1,38 @@
+# Copyright 2013 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+LOCAL_PATH:= $(call my-dir)
+include $(CLEAR_VARS)
+
+LOCAL_SRC_FILES:= $(call all-cpp-files-under, .)
+
+LOCAL_SHARED_LIBRARIES := \
+ libcutils \
+ libcameraservice \
+ libhidlbase \
+ liblog \
+ libutils \
+ android.hardware.camera.common@1.0 \
+ android.hardware.camera.provider@2.4 \
+ android.hardware.camera.device@1.0 \
+ android.hardware.camera.device@3.2
+
+LOCAL_C_INCLUDES += \
+
+LOCAL_CFLAGS += -Wall -Wextra -Werror
+
+LOCAL_MODULE:= cameraservice_test
+LOCAL_MODULE_TAGS := tests
+
+include $(BUILD_NATIVE_TEST)