blob: b3d9e647354a12780c16e75447b52b28a2f04122 [file] [log] [blame]
Jeff Brown5912f952013-07-01 19:10:31 -07001# Copyright (C) 2013 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
15LOCAL_PATH:= $(call my-dir)
16
17# libinput is partially built for the host (used by build time keymap validation tool)
18# These files are common to host and target builds.
19
20commonSources := \
21 Input.cpp \
22 InputDevice.cpp \
23 Keyboard.cpp \
24 KeyCharacterMap.cpp \
25 KeyLayoutMap.cpp \
26 VirtualKeyMap.cpp
27
28deviceSources := \
29 $(commonSources) \
30 InputTransport.cpp \
31 VelocityControl.cpp \
32 VelocityTracker.cpp
33
34hostSources := \
35 $(commonSources)
36
37# For the host
38# =====================================================
39
40include $(CLEAR_VARS)
41
42LOCAL_SRC_FILES:= $(hostSources)
43
44LOCAL_MODULE:= libinput
45
46LOCAL_MODULE_TAGS := optional
47
48include $(BUILD_HOST_STATIC_LIBRARY)
49
50
51# For the device
52# =====================================================
53
54include $(CLEAR_VARS)
55
56LOCAL_SRC_FILES:= $(deviceSources)
57
58LOCAL_SHARED_LIBRARIES := \
59 liblog \
60 libcutils \
61 libutils \
62 libbinder \
63 libskia \
64 libz
65
66LOCAL_C_INCLUDES := \
67 external/skia/include/core \
68 external/icu4c/common \
69 external/zlib
70
71LOCAL_MODULE:= libinput
72
73LOCAL_MODULE_TAGS := optional
74
75include $(BUILD_SHARED_LIBRARY)
76
77
78# Include subdirectory makefiles
79# ============================================================
80
81# If we're building with ONE_SHOT_MAKEFILE (mm, mmm), then what the framework
82# team really wants is to build the stuff defined by this makefile.
83ifeq (,$(ONE_SHOT_MAKEFILE))
84include $(call first-makefiles-under,$(LOCAL_PATH))
85endif