// Copyright (C) 2019 The Android Open Source Project
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//      http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package {
    // See: http://go/android-license-faq
    // A large-scale-change added 'default_applicable_licenses' to import
    // all of the 'license_kinds' from "frameworks_base_license"
    // to get the below license kinds:
    //   SPDX-license-identifier-Apache-2.0
    default_applicable_licenses: ["frameworks_base_license"],
}

java_defaults {
    name: "mimemap-defaults",
    srcs: [
        "java/android/content/type/DefaultMimeMapFactory.java",
    ],
    sdk_version: "core_platform",
}

java_library {
    name: "mimemap",
    defaults: ["mimemap-defaults"],
    static_libs: ["mimemap-res.jar"],
    visibility: [
        "//frameworks/base:__subpackages__",
    ],
}

java_library {
    name: "mimemap-testing",
    defaults: ["mimemap-defaults"],
    static_libs: ["mimemap-testing-res.jar"],
    jarjar_rules: "jarjar-rules.txt",
    visibility: [
        "//cts/tests/tests/mimemap:__subpackages__",
        "//frameworks/base:__subpackages__",
    ],
}

// The mimemap-res.jar and mimemap-testing-res.jar genrules produce a .jar that
// has the resource file in a subdirectory res/ and testres/, respectively.
// They need to be in different paths because one of them ends up in a
// bootclasspath jar whereas the other one ends up in a test jar. Bootclasspath
// resources hide test or application resources under the same path because
// ClassLoader.getResource(String) consults the parent ClassLoader first.
//
// Further notes:
//  - the "cp" command will flatten any directory paths that occur in $(in),
//    but here they happen to already be in the root directory. If we needed
//    to preserve sub paths then we might want to zip the files first and then
//    unzip them below the new parent directory.
//  - the path names "res/" and "testres/" and duplicated in .java source files
//    (DefaultMimeMapFactory.java and MimeMapTest.java, as of October 2019).
java_genrule {
    name: "mimemap-res.jar",
    tools: [
        "soong_zip",
    ],
    srcs: [":mime.types.minimized"],
    out: ["mimemap-res.jar"],
    cmd: "mkdir $(genDir)/res/ && cp $(in) $(genDir)/res/ && $(location soong_zip) -C $(genDir) -o $(out) -D $(genDir)/res/",
}

// The same as mimemap-res.jar except that the resources are placed in a different directory.
// They get bundled with CTS so that CTS can compare a device's MimeMap implementation vs.
// the stock Android one from when CTS was built.
java_genrule {
    name: "mimemap-testing-res.jar",
    tools: [
        "soong_zip",
    ],
    srcs: [":mime.types.minimized"],
    out: ["mimemap-testing-res.jar"],
    cmd: "mkdir $(genDir)/testres/ && cp $(in) $(genDir)/testres/ && $(location soong_zip) -C $(genDir) -o $(out) -D $(genDir)/testres/",
}

// Combination of all *mime.types.minimized resources.
filegroup {
    name: "mime.types.minimized",
    visibility: [
        "//visibility:private",
    ],
    srcs: [
        ":debian.mime.types.minimized",
        ":android.mime.types.minimized",
        ":vendor.mime.types.minimized",
    ],
}

java_genrule {
    name: "android.mime.types.minimized",
    visibility: [
        "//visibility:private",
    ],
    out: ["android.mime.types"],
    srcs: [
        "java-res/android.mime.types",
    ],
    //    strip comments            normalize whitepace       drop empty lines
    cmd: "awk '{gsub(/#.*$$/,\"\"); $$1=$$1; print;}' $(in) | grep ' ' > $(out)",
}

// Unlike the other *mime.types files, vendor.mime.types gets '?' prepended to
// every field so that its mappings will never overwrite earlier mappings by
// the other resource files. http://b/141842825
java_genrule {
    name: "vendor.mime.types.minimized",
    visibility: [
        "//visibility:private",
    ],
    out: ["vendor.mime.types"],
    srcs: [
        "java-res/vendor.mime.types",
    ],
    //    strip comments            normalize whitepace       drop empty lines           prepend ? to fields that are missing it
    cmd: "awk '{gsub(/#.*$$/,\"\"); $$1=$$1; print;}' $(in) | (grep ' ' || echo -n '') | awk '{for(i=1;i<=NF;i++) { sub(/^\\??/, \"?\", $$i); }; print}' > $(out)",
}
