Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Android/art/art/libartpalette/   (Android Betriebssystem Version 17©)  Datei vom 26.5.2026 mit Größe 5 kB image not shown  

Quelle  Android.bp   Sprache: unbekannt

 
Spracherkennung für: .bp vermutete Sprache: Unknown {[0] [0] [0]} [Methode: Schwerpunktbildung, einfache Gewichte, sechs Dimensionen]

//
// 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 "art_license"
    // to get the below license kinds:
    //   SPDX-license-identifier-Apache-2.0
    default_applicable_licenses: ["art_license"],
    default_team: "trendy_team_art_mainline",
}

cc_defaults {
    name: "libartpalette_defaults",
    defaults: ["art_defaults"],
    export_include_dirs: ["include"],
    header_libs: [
        "jni_headers",
    ],
}

cc_library_headers {
    name: "libartpalette-headers",
    export_include_dirs: ["include"],
    host_supported: true,
    visibility: [
        "//art:__subpackages__",
        "//system/libartpalette",
    ],
}

// libartpalette is the dynamic loader of the platform abstraction
// layer. It is only used on Android. For other targets, it just
// implements a fake platform implementation.
art_cc_library {
    name: "libartpalette",
    defaults: ["libartpalette_defaults"],
    host_supported: true,
    visibility: [
        // TODO(b/183483755): Please visibility checks when the prebuilt
        // libartpalette is present but not preferred, and the prebuilt
        // libdexfile hence depends on the source instead.
        // TODO(b/172480617): Alternatively, clean up when we no longer need to
        // support both prebuilts and sources present simultaneously.
        "//prebuilts/module_sdk/art:__subpackages__",
    ],
    header_libs: [
        "libbase_headers",
    ],
    export_header_lib_headers: [
        "jni_headers",
    ],
    target: {
        // Targets supporting dlopen build the client library which loads
        // and binds the methods in the libartpalette-system library.
        android: {
            // libartpalette.so dlopen()'s libartpalette-system.
            runtime_libs: ["libartpalette-system"],
            srcs: ["apex/palette.cc"],
            shared_libs: ["liblog"],
            version_script: "libartpalette.map",
        },
        host_linux: {
            header_libs: ["libbase_headers"],
            srcs: ["system/palette_fake.cc"],
            shared: {
                shared_libs: [
                    "libbase",
                    "liblog",
                ],
            },
            version_script: "libartpalette.map",
        },
        // Targets without support for dlopen just use the sources for
        // the system library which actually implements functionality.
        darwin: {
            enabled: true,
            header_libs: ["libbase_headers"],
            srcs: ["system/palette_fake.cc"],
            static_libs: [
                "libbase",
                "liblog",
            ],
        },
        windows: {
            enabled: true,
            header_libs: ["libbase_headers"],
            srcs: ["system/palette_fake.cc"],
            static_libs: [
                "libbase",
                "liblog",
            ],
        },
    },
    apex_available: [
        "com.android.art",
        "com.android.art.debug",
        // TODO(b/142944931): remove this
        "com.android.runtime", // due to the transitive dependency from linker
    ],
}

art_cc_library {
    name: "libartpalette_fake",
    defaults: ["libartpalette_defaults"],
    srcs: ["system/palette_fake.cc"],
    stem: "libartpalette-system",
    relative_install_path: "art_fake", // Avoid conflict with the real lib.
    shared_libs: [
        "libbase",
        "liblog",
    ],
    compile_multilib: "both",
    visibility: [
        "//visibility:override",
        "//visibility:private",
    ],
}

art_cc_defaults {
    name: "art_libartpalette_tests_defaults",
    srcs: ["apex/palette_test.cc"],
    target: {
        android: {
            static_libs: ["libmodules-utils-build"],
        },
    },
}

// Version of API coverage test for host.
art_cc_test {
    name: "art_libartpalette_tests",
    defaults: [
        "art_gtest_defaults",
        "art_libartpalette_tests_defaults",
    ],
    host_supported: true,
    device_supported: false,
}

// MCTS test for API coverage. This test starts a VM to check the JNI
// notification callbacks, so it should not use art_standalone_gtest_defaults,
// which statically links a runtime via libart-gtest.
art_cc_test {
    name: "art_standalone_libartpalette_tests",
    defaults: [
        "art_standalone_test_defaults",
        "art_libartpalette_tests_defaults",
    ],
    static_libs: [
        "libartbase-testing",
        "libartpalette",
    ],
    shared_libs: [
        "liblog",
        // Bypass stubs to get access to the platform-only JniInvocation APIs.
        // They're not NDK APIs, but have the same stability requirements.
        "libnativehelper#impl",
    ],
    test_config_template: ":art-gtests-target-standalone-cts-template",
    test_suites: [
        "cts",
        "general-tests",
        "mcts-art",
        "mts-art",
    ],

    // Duplicated from art_standalone_gtest_defaults
    compile_multilib: "both",
    multilib: {
        lib32: {
            suffix: "32",
        },
        lib64: {
            suffix: "64",
        },
    },
}

[Dauer der Verarbeitung: 0.21 Sekunden, vorverarbeitet 2026-06-29]