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

Commit 144865c5 authored by Steven Moreland's avatar Steven Moreland
Browse files

Use vendor variant of libstagefright_foundation.

Rather than having a lib called libstagefright_foundation and one
called libstagefright_foundation_vendor, we now just have one library
and the build system keeps track of the vendor APIs that are exposed.

Test: (sanity) boot device, watch (part of) DRM protected movie.
Change-Id: I49f1c557ae8f93092bad5314e0630583cc7dc710
Merged-In: I49f1c557ae8f93092bad5314e0630583cc7dc710
parent 69545369
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -38,7 +38,7 @@ cc_library_shared {
    shared_libs: [
        "libcrypto",
        "liblog",
        "libstagefright_foundation_vendor",
        "libstagefright_foundation",
        "libutils",
    ],

+1 −1
Original line number Diff line number Diff line
@@ -31,7 +31,7 @@ cc_test {
        "libcrypto",
        "libdrmclearkeyplugin",
        "liblog",
        "libstagefright_foundation_vendor",
        "libstagefright_foundation",
        "libutils",
    ],
}
+42 −49
Original line number Diff line number Diff line
COMMON_SRCS = [
        "AAtomizer.cpp",
        "ABitReader.cpp",
        "ABuffer.cpp",
        "ADebug.cpp",
        "AHandler.cpp",
        "AHierarchicalStateMachine.cpp",
        "ALooper.cpp",
        "ALooperRoster.cpp",
        "AMessage.cpp",
        "ANetworkSession.cpp",
        "AString.cpp",
        "AStringUtils.cpp",
        "ColorUtils.cpp",
        "MediaBuffer.cpp",
        "MediaBufferGroup.cpp",
        "MetaData.cpp",
        "ParsedMessage.cpp",
        "base64.cpp",
        "hexdump.cpp",
]

COMMON_LIBS = [
        "libbinder",
        "libutils",
        "libui",
        "libcutils",
        "liblog",
]

cc_defaults {
    name: "libstagefright_foundation-defaults",
cc_library_shared {
    name: "libstagefright_foundation",
    vendor_available: true,

    include_dirs: [
        "frameworks/av/include",
@@ -59,6 +30,45 @@ cc_defaults {
        "-Wall",
    ],

    shared_libs: [
        "libbinder",
        "libutils",
        "libui",
        "libcutils",
        "liblog",
        "libpowermanager",
    ],

    srcs: [
        "AAtomizer.cpp",
        "ABitReader.cpp",
        "ABuffer.cpp",
        "ADebug.cpp",
        "AHandler.cpp",
        "AHierarchicalStateMachine.cpp",
        "ALooper.cpp",
        "ALooperRoster.cpp",
        "AMessage.cpp",
        "ANetworkSession.cpp",
        "AString.cpp",
        "AStringUtils.cpp",
        "AWakeLock.cpp",
        "ColorUtils.cpp",
        "MediaBuffer.cpp",
        "MediaBufferGroup.cpp",
        "MetaData.cpp",
        "ParsedMessage.cpp",
        "base64.cpp",
        "hexdump.cpp",
    ],

    target: {
        vendor: {
            exclude_shared_libs: ["libpowermanager"],
            exclude_srcs: ["AWakeLock.cpp"],
        },
    },

    clang: true,

    sanitize: {
@@ -72,20 +82,3 @@ cc_defaults {
        },
    },
}

cc_library_shared {
    name: "libstagefright_foundation",
    defaults: ["libstagefright_foundation-defaults"],

    srcs: COMMON_SRCS + ["AWakeLock.cpp"],
    shared_libs: COMMON_LIBS + ["libpowermanager"],
}

cc_library_shared {
    name: "libstagefright_foundation_vendor",
    defaults: ["libstagefright_foundation-defaults"],
    vendor: true,

    srcs: COMMON_SRCS,
    shared_libs: COMMON_LIBS,
}