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