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

Commit f271aef4 authored by Edwin Wong's avatar Edwin Wong Committed by android-build-team Robot
Browse files

Build static and shared libdrmframeworkcommon.

The libdrmframeworkcommon was statically linked
to multiple libraries used by libfwdlockengine.
When the shared libraries closes, the same block
of static memory will be freed twice.

Test: CTS forwardlock tests
  atest CtsDrmTestCases
Bug: 155647761
Change-Id: Iace1b47a9172264c61ba936f486671c7846edf46
(cherry picked from commit 3be0c0d7)
parent 819799ce
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -14,7 +14,7 @@
// limitations under the License.
//

cc_library_static {
cc_library {
    name: "libdrmframeworkcommon",

    srcs: [
@@ -35,7 +35,11 @@ cc_library_static {

    cflags: ["-Wall", "-Werror"],

    shared_libs: ["libbinder"],
    shared_libs: [
        "libbinder",
        "liblog",
        "libutils"
    ],

    export_include_dirs: ["include"],
}
+1 −2
Original line number Diff line number Diff line
@@ -31,12 +31,11 @@ cc_binary {
        "liblog",
        "libbinder",
        "libdl",
        "libdrmframeworkcommon",
        "libselinux",
        "libstagefright_foundation",
    ],

    static_libs: ["libdrmframeworkcommon"],

    cflags: [
        "-Wall",
        "-Wextra",
+2 −3
Original line number Diff line number Diff line
@@ -29,12 +29,11 @@ cc_library_shared {
        "liblog",
        "libbinder",
        "libdl",
        "libdrmframeworkcommon",
    ],

    static_libs: ["libdrmframeworkcommon"],

    export_include_dirs: ["include"],
    export_static_lib_headers: ["libdrmframeworkcommon"],
    export_shared_lib_headers: ["libdrmframeworkcommon"],

    cflags: ["-Werror"],
}
+1 −1
Original line number Diff line number Diff line
@@ -36,11 +36,11 @@ cc_library_shared {
        "libcrypto",
        "libssl",
        "libdrmframework",
        "libdrmframeworkcommon",
    ],

    static_libs: [
        "libdrmutility",
        "libdrmframeworkcommon",
        "libfwdlock-common",
        "libfwdlock-converter",
        "libfwdlock-decoder",
+1 −2
Original line number Diff line number Diff line
@@ -19,12 +19,11 @@ cc_library_shared {

    srcs: ["src/DrmPassthruPlugIn.cpp"],

    static_libs: ["libdrmframeworkcommon"],

    shared_libs: [
        "libutils",
        "liblog",
        "libdl",
        "libdrmframeworkcommon",
    ],

    local_include_dirs: ["include"],