2 # Copyright (C) 2008 The Android Open Source Project
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
16 LOCAL_PATH := $(call my-dir)
18 # Load framework-specific path mappings used later in the build.
19 include $(LOCAL_PATH)/pathmap.mk
21 # Build the master framework library.
22 # The framework contains too many method references (>64K) for poor old DEX.
23 # So we first build the framework as a monolithic static library then split it
24 # up into smaller pieces.
25 # ============================================================
27 # embedded builds use nothing in frameworks/base
28 ifneq ($(ANDROID_BUILD_EMBEDDED),true)
30 # Copy AIDL files to be preprocessed and included in the SDK,
31 # specified relative to the root of the build tree.
32 # ============================================================
35 # This is used by ide.mk as the list of source files that are
37 INTERNAL_SDK_SOURCE_DIRS := $(addprefix $(LOCAL_PATH)/,$(dirs_to_document))
39 $(call dist-for-goals,sdk,$(INTERNAL_PLATFORM_API_FILE))
40 $(call dist-for-goals,sdk,$(INTERNAL_PLATFORM_SYSTEM_API_FILE))
41 $(call dist-for-goals,sdk,$(INTERNAL_PLATFORM_TEST_API_FILE))
42 $(call dist-for-goals,sdk,$(INTERNAL_PLATFORM_API_FILE):apistubs/android/public/api/android.txt)
43 $(call dist-for-goals,sdk,$(INTERNAL_PLATFORM_SYSTEM_API_FILE):apistubs/android/system/api/android.txt)
44 $(call dist-for-goals,sdk,$(INTERNAL_PLATFORM_TEST_API_FILE):apistubs/android/test/api/android.txt)
46 # sdk.atree needs to copy the whole dir: $(OUT_DOCS)/offline-sdk to the final zip.
47 # So keep offline-sdk-timestamp target here, and unzip offline-sdk-docs.zip to
48 # $(OUT_DOCS)/offline-sdk.
49 $(OUT_DOCS)/offline-sdk-timestamp: $(OUT_DOCS)/offline-sdk-docs-docs.zip
50 $(hide) rm -rf $(OUT_DOCS)/offline-sdk
51 $(hide) mkdir -p $(OUT_DOCS)/offline-sdk
52 ( unzip -qo $< -d $(OUT_DOCS)/offline-sdk && touch -f $@ ) || exit 1
54 .PHONY: docs offline-sdk-docs
55 docs offline-sdk-docs: $(OUT_DOCS)/offline-sdk-timestamp
57 # Run this for checkbuild
58 checkbuild: doc-comment-check-docs
60 # ==== hiddenapi lists =======================================
61 ifneq ($(UNSAFE_DISABLE_HIDDENAPI_FLAGS),true)
62 $(call dist-for-goals,droidcore,$(INTERNAL_PLATFORM_HIDDENAPI_FLAGS))
63 $(call dist-for-goals,droidcore,$(INTERNAL_PLATFORM_HIDDENAPI_GREYLIST_METADATA))
64 endif # UNSAFE_DISABLE_HIDDENAPI_FLAGS
66 # Include subdirectory makefiles
67 # ============================================================
69 # If we're building with ONE_SHOT_MAKEFILE (mm, mmm), then what the framework
70 # team really wants is to build the stuff defined by this makefile.
71 ifeq (,$(ONE_SHOT_MAKEFILE))
72 include $(call first-makefiles-under,$(LOCAL_PATH))
75 endif # ANDROID_BUILD_EMBEDDED