• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2008, 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# Build the Email application itself, along with its tests and tests for the emailcommon
18# static library.  All tests can be run via runtest email
19
20include $(CLEAR_VARS)
21
22# Include res dir from chips, unified, emailcommon, and photoviewer
23chips_dir := ../../../frameworks/ex/chips/res
24unified_email_dir := ../UnifiedEmail
25photo_dir := ../../../frameworks/opt/photoviewer/res ../../../frameworks/opt/photoviewer/activity/res
26emailcommon_dir := emailcommon
27gridlayout_dir := ../../../frameworks/support/v7/gridlayout/res
28res_dir := res $(unified_email_dir)/res $(chips_dir) $(photo_dir) $(emailcommon_dir)/res $(gridlayout_dir)
29
30LOCAL_MODULE_TAGS := optional
31
32LOCAL_SRC_FILES := $(call all-java-files-under, $(unified_email_dir)/src)
33LOCAL_SRC_FILES += $(call all-java-files-under, src/com/android)
34LOCAL_SRC_FILES += $(call all-java-files-under, src/com/beetstra)
35
36LOCAL_RESOURCE_DIR := $(addprefix $(LOCAL_PATH)/, $(res_dir))
37
38# Use assets dir from UnifiedEmail
39# (the default package target doesn't seem to deal with multiple asset dirs)
40LOCAL_ASSET_DIR := $(LOCAL_PATH)/$(unified_email_dir)/assets
41
42LOCAL_AAPT_FLAGS := --auto-add-overlay
43LOCAL_AAPT_FLAGS += --extra-packages com.android.ex.chips:com.android.mail:com.android.email:com.android.emailcommon:com.android.ex.photo:android.support.v7.gridlayout
44
45LOCAL_STATIC_JAVA_LIBRARIES := android-common com.android.emailcommon com.android.emailsync guava android-common-chips libphotoviewer
46LOCAL_STATIC_JAVA_LIBRARIES += android-support-v4
47LOCAL_STATIC_JAVA_LIBRARIES += android-support-v7-gridlayout
48LOCAL_STATIC_JAVA_LIBRARIES += android-support-v13
49
50LOCAL_PACKAGE_NAME := Email
51
52LOCAL_PROGUARD_FLAG_FILES := proguard.flags $(unified_email_dir)/proguard.flags
53
54LOCAL_SDK_VERSION := current
55
56include $(BUILD_PACKAGE)
57
58# only include rules to build other stuff for the original package, not the derived package.
59ifeq ($(strip $(LOCAL_PACKAGE_OVERRIDES)),)
60# additionally, build unit tests in a separate .apk
61include $(call all-makefiles-under,$(LOCAL_PATH))
62endif
63