Whamcloud - gitweb
AOSP: [LSC] Add LOCAL_LICENSE_KINDS to external/e2fsprogs
[tools/e2fsprogs.git] / lib / ext2fs / Android.bp
index 8f389ec..919adb1 100644 (file)
@@ -1,9 +1,27 @@
 // Copyright 2017 The Android Open Source Project
 
+package {
+    // See: http://go/android-license-faq
+    // A large-scale-change added 'default_applicable_licenses' to import
+    // all of the 'license_kinds' from "external_e2fsprogs_license"
+    // to get the below license kinds:
+    //   SPDX-license-identifier-GPL
+    //   SPDX-license-identifier-GPL-2.0
+    //   SPDX-license-identifier-LGPL
+    //   SPDX-license-identifier-LGPL-2.1
+    //   SPDX-license-identifier-LGPL-3.0
+    //   legacy_unencumbered
+    default_applicable_licenses: ["external_e2fsprogs_license"],
+}
+
 cc_library {
     name: "libext2fs",
     host_supported: true,
+    ramdisk_available: true,
+    vendor_ramdisk_available: true,
+    recovery_available: true,
     unique_host_soname: true,
+    defaults: ["e2fsprogs-defaults"],
     srcs: [
         "ext2_err.c",
         "alloc.c",
@@ -46,6 +64,7 @@ cc_library {
         "get_pathname.c",
         "getsize.c",
         "getsectsize.c",
+        "hashmap.c",
         "i_block.c",
         "icount.c",
         "imager.c",
@@ -65,6 +84,7 @@ cc_library {
         "namei.c",
         "native.c",
         "newdir.c",
+        "nls_utf8.c",
         "openfs.c",
         "progress.c",
         "punch.c",
@@ -88,34 +108,20 @@ cc_library {
         "test_io.c",
     ],
     shared_libs: [
+        "libext2_com_err",
         "libsparse",
         "libz",
     ],
-    whole_static_libs: [
-        "libext2_com_err"
-    ],
-    cflags: [
-        "-W",
-        "-Wall",
-        "-Wno-unused-parameter",
-        "-Wno-macro-redefined",
-    ],
+    cflags: ["-Wno-unused-parameter"],
     target: {
-        host: {
-            // Consider removing this library as a whole for the host. It is not
-            // in the android side.
-            whole_static_libs: ["libext2_com_err"],
-        },
         android: {
-            shared_libs: [
-                "libext2_com_err",
-                "libext2_uuid",
-            ],
+            shared_libs: [ "libext2_uuid" ],
         },
         windows: {
             enabled: true,
             include_dirs: [ "external/e2fsprogs/include/mingw" ],
             cflags: [
+                "-Wno-error=cpp",
                 "-Wno-format",
                 "-Wno-unused-variable",
             ],