Whamcloud - gitweb
AOSP: Rename libz-host -> libz
[tools/e2fsprogs.git] / lib / ext2fs / Android.bp
1 // Copyright 2017 The Android Open Source Project
2
3 cc_library {
4     name: "libext2fs",
5     host_supported: true,
6     unique_host_soname: true,
7     srcs: [
8         "ext2_err.c",
9         "alloc.c",
10         "alloc_sb.c",
11         "alloc_stats.c",
12         "alloc_tables.c",
13         "atexit.c",
14         "badblocks.c",
15         "bb_inode.c",
16         "bitmaps.c",
17         "bitops.c",
18         "blkmap64_ba.c",
19         "blkmap64_rb.c",
20         "blknum.c",
21         "block.c",
22         "bmap.c",
23         "check_desc.c",
24         "crc16.c",
25         "crc32c.c",
26         "csum.c",
27         "closefs.c",
28         "dblist.c",
29         "dblist_dir.c",
30         "digest_encode.c",
31         "dirblock.c",
32         "dirhash.c",
33         "dir_iterate.c",
34         "dupfs.c",
35         "expanddir.c",
36         "ext_attr.c",
37         "extent.c",
38         "fallocate.c",
39         "fileio.c",
40         "finddev.c",
41         "flushb.c",
42         "freefs.c",
43         "gen_bitmap.c",
44         "gen_bitmap64.c",
45         "get_num_dirs.c",
46         "get_pathname.c",
47         "getsize.c",
48         "getsectsize.c",
49         "i_block.c",
50         "icount.c",
51         "imager.c",
52         "ind_block.c",
53         "initialize.c",
54         "inline.c",
55         "inline_data.c",
56         "inode.c",
57         "io_manager.c",
58         "ismounted.c",
59         "link.c",
60         "llseek.c",
61         "lookup.c",
62         "mmp.c",
63         "mkdir.c",
64         "mkjournal.c",
65         "namei.c",
66         "native.c",
67         "newdir.c",
68         "openfs.c",
69         "progress.c",
70         "punch.c",
71         "qcow2.c",
72         "rbtree.c",
73         "read_bb.c",
74         "read_bb_file.c",
75         "res_gdt.c",
76         "rw_bitmaps.c",
77         "sha256.c",
78         "sha512.c",
79         "swapfs.c",
80         "symlink.c",
81         "undo_io.c",
82         "unix_io.c",
83         "sparse_io.c",
84         "unlink.c",
85         "valid_blk.c",
86         "version.c",
87         // get rid of this?!
88         "test_io.c",
89     ],
90     shared_libs: [
91         "libsparse",
92         "libz",
93     ],
94     whole_static_libs: [
95         "libext2_com_err"
96     ],
97     cflags: [
98         "-W",
99         "-Wall",
100         "-Wno-unused-parameter",
101         "-Wno-macro-redefined",
102     ],
103     target: {
104         host: {
105             // Consider removing this library as a whole for the host. It is not
106             // in the android side.
107             whole_static_libs: ["libext2_com_err"],
108         },
109         android: {
110             shared_libs: [
111                 "libext2_com_err",
112                 "libext2_uuid",
113             ],
114         },
115         windows: {
116             enabled: true,
117             include_dirs: [ "external/e2fsprogs/include/mingw" ],
118             cflags: [
119                 "-Wno-format",
120             ],
121             host_ldlibs: ["-lws2_32"],
122         },
123     },
124
125     header_libs: ["libext2-headers"],
126     export_include_dirs: ["."],
127     export_header_lib_headers: ["libext2-headers"],
128 }