The Android Open Source Project | 7c1b96a | 2008-10-21 07:00:00 -0700 | [diff] [blame^] | 1 | LOCAL_PATH:= $(call my-dir) |
| 2 | |
| 3 | # |
| 4 | # Set USE_CAMERA_STUB for non-emulator and non-simulator builds, if you want |
| 5 | # the camera service to use the fake camera. For emulator or simulator builds, |
| 6 | # we always use the fake camera. |
| 7 | # |
| 8 | ifeq ($(BOARD_CAMERA_LIBRARIES),) |
| 9 | USE_CAMERA_STUB:=true |
| 10 | else |
| 11 | USE_CAMERA_STUB:=false |
| 12 | endif #libcamerastub |
| 13 | |
| 14 | ifeq ($(USE_CAMERA_STUB),true) |
| 15 | # |
| 16 | # libcamerastub |
| 17 | # |
| 18 | |
| 19 | include $(CLEAR_VARS) |
| 20 | |
| 21 | LOCAL_SRC_FILES:= \ |
| 22 | CameraHardwareStub.cpp \ |
| 23 | FakeCamera.cpp |
| 24 | |
| 25 | LOCAL_MODULE:= libcamerastub |
| 26 | |
| 27 | LOCAL_SHARED_LIBRARIES:= libui |
| 28 | |
| 29 | include $(BUILD_STATIC_LIBRARY) |
| 30 | endif # USE_CAMERA_STUB |
| 31 | |
| 32 | # |
| 33 | # libcameraservice |
| 34 | # |
| 35 | |
| 36 | include $(CLEAR_VARS) |
| 37 | |
| 38 | LOCAL_SRC_FILES:= \ |
| 39 | CameraService.cpp |
| 40 | |
| 41 | LOCAL_SHARED_LIBRARIES:= \ |
| 42 | libui \ |
| 43 | libutils \ |
| 44 | libcutils |
| 45 | |
| 46 | LOCAL_MODULE:= libcameraservice |
| 47 | |
| 48 | LOCAL_CFLAGS+=-DLOG_TAG=\"CameraService\" |
| 49 | |
| 50 | ifeq ($(USE_CAMERA_STUB), true) |
| 51 | LOCAL_STATIC_LIBRARIES += libcamerastub |
| 52 | LOCAL_CFLAGS += -include CameraHardwareStub.h |
| 53 | else |
| 54 | LOCAL_SHARED_LIBRARIES += $(BOARD_CAMERA_LIBRARIES) |
| 55 | endif |
| 56 | |
| 57 | include $(BUILD_SHARED_LIBRARY) |
| 58 | |