blob: 95c77d4e6499bd60a994d52c0128ad76d4a4963c [file] [log] [blame]
Mathias Agopian83c64e62012-02-20 16:58:20 -08001# Copyright (C) 2010 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# libandroidfw is partially built for the host (used by build time keymap validation tool)
18# These files are common to host and target builds.
19
20# formerly in libutils
21commonUtilsSources:= \
22 Asset.cpp \
23 AssetDir.cpp \
24 AssetManager.cpp \
25 ObbFile.cpp \
26 ResourceTypes.cpp \
Colin Crossa982dc02012-03-22 18:43:07 -070027 StreamingZipInflater.cpp
Mathias Agopian83c64e62012-02-20 16:58:20 -080028
29# formerly in libui
30commonUiSources:= \
31 Input.cpp \
Jeff Brown9f25b7f2012-04-10 14:30:49 -070032 InputDevice.cpp \
Mathias Agopian83c64e62012-02-20 16:58:20 -080033 Keyboard.cpp \
34 KeyCharacterMap.cpp \
35 KeyLayoutMap.cpp \
36 VirtualKeyMap.cpp
37
38commonSources:= \
39 $(commonUtilsSources) \
40 $(commonUiSources)
41
42# For the host
43# =====================================================
44
45include $(CLEAR_VARS)
46
47LOCAL_SRC_FILES:= $(commonSources)
48
49LOCAL_MODULE:= libandroidfw
50
51LOCAL_MODULE_TAGS := optional
52
Mathias Agopian027692b2012-02-21 16:55:25 -080053LOCAL_C_INCLUDES := \
54 external/zlib
55
Mathias Agopian83c64e62012-02-20 16:58:20 -080056include $(BUILD_HOST_STATIC_LIBRARY)
57
58
59# For the device
60# =====================================================
61
62include $(CLEAR_VARS)
63
64LOCAL_SRC_FILES:= \
65 $(commonSources) \
66 BackupData.cpp \
67 BackupHelpers.cpp \
Mathias Agopian49d2b182012-02-27 18:11:20 -080068 CursorWindow.cpp \
Mathias Agopian83c64e62012-02-20 16:58:20 -080069 InputTransport.cpp
70
71LOCAL_SHARED_LIBRARIES := \
72 liblog \
73 libcutils \
74 libutils \
75 libbinder \
76 libskia \
77 libz
78
79LOCAL_C_INCLUDES := \
80 external/skia/include/core \
81 external/icu4c/common \
82 external/zlib
83
84LOCAL_MODULE:= libandroidfw
85
86LOCAL_MODULE_TAGS := optional
87
88include $(BUILD_SHARED_LIBRARY)
89
90
91ifeq ($(TARGET_OS),linux)
92include $(CLEAR_VARS)
93LOCAL_C_INCLUDES += \
94 external/skia/include/core \
95 external/zlib \
96 external/icu4c/common \
97 bionic/libc/private
Mathias Agopiancbc69712012-02-21 14:34:47 -080098LOCAL_LDLIBS := -lrt -ldl -lpthread
Mathias Agopian30c46ad2012-02-21 13:27:59 -080099LOCAL_MODULE := libandroidfw
Mathias Agopian83c64e62012-02-20 16:58:20 -0800100LOCAL_SRC_FILES := $(commonUtilsSources) BackupData.cpp BackupHelpers.cpp
101include $(BUILD_STATIC_LIBRARY)
102endif
103
104
105# Include subdirectory makefiles
106# ============================================================
107
108# If we're building with ONE_SHOT_MAKEFILE (mm, mmm), then what the framework
109# team really wants is to build the stuff defined by this makefile.
110ifeq (,$(ONE_SHOT_MAKEFILE))
111include $(call first-makefiles-under,$(LOCAL_PATH))
112endif