Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b62e707e authored by Alec Mouri's avatar Alec Mouri Committed by Android (Google) Code Review
Browse files

Merge "libgui: add aidl header lib" into sc-dev

parents 6acbc8a9 cdedc5d6
Loading
Loading
Loading
Loading
+55 −6
Original line number Diff line number Diff line
@@ -39,12 +39,50 @@ cc_library_headers {
    min_sdk_version: "29",
}

cc_library_headers {
    name: "libgui_aidl_headers",
    vendor_available: true,
    static_libs: [
        "libgui_aidl_static",
    ],

    export_static_lib_headers: [
        "libgui_aidl_static",
    ],
}

filegroup {
    name: "libgui_aidl",
    srcs: ["aidl/**/*.aidl"],
    path: "aidl/",
}

cc_library_static {
    name: "libgui_aidl_static",
    vendor_available: true,
    srcs: [
        ":libgui_aidl",
    ],

    shared_libs: [
        "libbinder",
        "libui",
    ],

    local_include_dirs: [
        "include",
    ],

    export_shared_lib_headers: [
        "libbinder",
    ],

    aidl: {
        export_aidl_headers: true
    }
}


cc_library_shared {
    name: "libgui",
    vendor_available: true,
@@ -56,10 +94,16 @@ cc_library_shared {

    defaults: ["libgui_bufferqueue-defaults"],

    static_libs: [
        "libgui_aidl_static",
    ],
    export_static_lib_headers: [
        "libgui_aidl_static",
    ],

    srcs: [
        ":framework_native_aidl",
        ":inputconstants_aidl",
        ":libgui_aidl",
        ":libgui_bufferqueue_sources",

        "BitTube.cpp",
@@ -115,6 +159,10 @@ cc_library_shared {
        "libinput",
    ],

    export_header_lib_headers: [
        "libgui_aidl_headers",
    ],

    // bufferhub is not used when building libgui for vendors
    target: {
        vendor: {
@@ -136,15 +184,16 @@ cc_library_shared {
        },
    },

    aidl: {
        export_aidl_headers: true,
    },

    header_libs: [
        "libdvr_headers",
        "libgui_aidl_headers",
        "libpdx_headers",
    ],

    aidl: {
        export_aidl_headers: true,
    },

    pgo: {
        sampling: true,
        profile_file: "libgui/libgui.profdata",
@@ -175,8 +224,8 @@ cc_library_static {

    srcs: [
        ":inputconstants_aidl",
        ":libgui_aidl",
        ":libgui_bufferqueue_sources",
        ":libgui_aidl",
    ],
}

+5 −2
Original line number Diff line number Diff line
@@ -18,7 +18,6 @@

#include <stdint.h>

#include <android/os/IInputConstants.h>
#include <binder/Parcel.h>

namespace android {
@@ -31,7 +30,11 @@ struct FrameTimelineInfo {
    int64_t vsyncId = INVALID_VSYNC_ID;

    // The id of the input event that caused this buffer
    int32_t inputEventId = android::os::IInputConstants::INVALID_INPUT_EVENT_ID;
    // Default is android::os::IInputConstants::INVALID_INPUT_EVENT_ID = 0
    // We copy the value of the input event ID instead of including the header, because libgui
    // header libraries containing FrameTimelineInfo must be available to vendors, but libinput is
    // not directly vendor available.
    int32_t inputEventId = 0;

    status_t write(Parcel& output) const;
    status_t read(const Parcel& input);