Android.bp revision da431a22da38f9c4085b5d71ed9a9c6122c6a5a6
1// 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 15// libandroidfw is partially built for the host (used by obbtool, aapt, and others) 16 17cc_library { 18 name: "libandroidfw", 19 host_supported: true, 20 cflags: [ 21 "-Wall", 22 "-Werror", 23 "-Wunused", 24 "-Wunreachable-code", 25 ], 26 srcs: [ 27 "ApkAssets.cpp", 28 "Asset.cpp", 29 "AssetDir.cpp", 30 "AssetManager.cpp", 31 "AssetManager2.cpp", 32 "AttributeResolution.cpp", 33 "ChunkIterator.cpp", 34 "LoadedArsc.cpp", 35 "LocaleData.cpp", 36 "misc.cpp", 37 "ObbFile.cpp", 38 "ResourceTypes.cpp", 39 "StreamingZipInflater.cpp", 40 "TypeWrappers.cpp", 41 "Util.cpp", 42 "ZipFileRO.cpp", 43 "ZipUtils.cpp", 44 ], 45 export_include_dirs: ["include"], 46 target: { 47 android: { 48 srcs: [ 49 "BackupData.cpp", 50 "BackupHelpers.cpp", 51 "CursorWindow.cpp", 52 "DisplayEventDispatcher.cpp", 53 ], 54 shared_libs: [ 55 "libziparchive", 56 "libbase", 57 "libbinder", 58 "liblog", 59 "libcutils", 60 "libgui", 61 "libutils", 62 "libz", 63 ], 64 static: { 65 enabled: false, 66 }, 67 }, 68 host: { 69 cflags: ["-DSTATIC_ANDROIDFW_FOR_TOOLS"], 70 shared: { 71 enabled: false, 72 }, 73 static_libs: [ 74 "libziparchive", 75 "libbase", 76 "liblog", 77 "libcutils", 78 "libutils", 79 ], 80 shared_libs: [ 81 "libz-host", 82 ], 83 }, 84 windows: { 85 enabled: true, 86 cppflags: ["-Wno-missing-field-initializers"], // The Windows compiler warns 87 // incorrectly for value 88 // initialization with {}. 89 }, 90 }, 91} 92