• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// Copyright 2010 The Android Open Source Project
2
3cc_library {
4    name: "libext4_utils",
5    host_supported: true,
6    srcs: [
7        "make_ext4fs.c",
8        "ext4fixup.c",
9        "ext4_utils.c",
10        "allocate.c",
11        "contents.c",
12        "extent.c",
13        "indirect.c",
14        "sha1.c",
15        "wipe.c",
16        "crc16.c",
17        "ext4_sb.c",
18    ],
19    // Various instances of dereferencing a type-punned pointer in extent.c
20    cflags: ["-fno-strict-aliasing"],
21    export_include_dirs: ["include"],
22    shared_libs: [
23        "libsparse",
24    ],
25
26    target: {
27        host: {
28            static_libs: ["libsparse"],
29            shared_libs: ["libz-host"],
30        },
31        linux: {
32            static_libs: ["libselinux"],
33        },
34        darwin: {
35            static_libs: ["libselinux"],
36        },
37        windows: {
38            host_ldlibs: ["-lws2_32"],
39            enabled: true,
40        },
41
42        android: {
43            srcs: [
44                "key_control.cpp",
45                "ext4_crypt.cpp",
46            ],
47            shared_libs: [
48                "libbase",
49                "libselinux",
50            ],
51
52            static: {
53                srcs: [
54                    "ext4_crypt_init_extensions.cpp",
55                ],
56                static_libs: [
57                    "liblogwrap",
58                ]
59            },
60            shared: {
61                cflags: ["-DREAL_UUID"],
62                shared_libs: [
63                    "libcutils",
64                    "libext2_uuid",
65                    "libz",
66                ]
67            },
68        },
69    },
70}
71