blob: 5d12d9507c22cbdc36b883974086dad5c1d56b8d [file] [log] [blame]
Colin Crossce2221e2016-12-01 15:55:00 -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
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 "Asset.cpp",
28 "AssetDir.cpp",
29 "AssetManager.cpp",
30 "LocaleData.cpp",
31 "misc.cpp",
32 "ObbFile.cpp",
33 "ResourceTypes.cpp",
34 "StreamingZipInflater.cpp",
35 "TypeWrappers.cpp",
36 "ZipFileRO.cpp",
37 "ZipUtils.cpp",
38 ],
39 export_include_dirs: ["include"],
40 target: {
41 android: {
42 srcs: [
43 "BackupData.cpp",
44 "BackupHelpers.cpp",
45 "CursorWindow.cpp",
46 "DisplayEventDispatcher.cpp",
47 ],
48 shared_libs: [
49 "libziparchive",
50 "libbase",
51 "libbinder",
52 "liblog",
53 "libcutils",
54 "libgui",
55 "libutils",
56 "libz",
57 ],
58 static: {
59 enabled: false,
60 },
61 },
62 host: {
63 cflags: ["-DSTATIC_ANDROIDFW_FOR_TOOLS"],
64 shared: {
65 enabled: false,
66 },
67 shared_libs: ["libz-host"],
68 },
69 windows: {
70 enabled: true,
71 },
72 },
73}