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

Commit 99486a62 authored by Andy Hung's avatar Andy Hung
Browse files

audio: enable frameworks/av bpfmt PREUPLOAD hooks

Test: treehugger
Test: repo upload -dry-run .
Bug: 333438494
Change-Id: Iaf2a6474f09c8017b883a2cb2a08ff6087cdd84d
parent 9f179836
Loading
Loading
Loading
Loading
+21 −0
Original line number Diff line number Diff line
@@ -4,9 +4,30 @@ mainline_hook = ${REPO_ROOT}/frameworks/av/tools/mainline_hook_partial.sh ${REPO
hidden_api_txt_checksorted_hook = ${REPO_ROOT}/tools/platform-compat/hiddenapi/checksorted_sha.sh ${PREUPLOAD_COMMIT} ${REPO_ROOT}

[Builtin Hooks]
bpfmt = true
clang_format = true

[Builtin Hooks Options]
# Enable sort and limit subfolder checks
bpfmt = -s
    media/audio/
    media/audioserver/
    media/libaaudio/
    media/libaudioclient/
    media/libaudiofoundation/
    media/libaudiohal/
    media/libaudioprocessing/
    media/libaudiousecasevalidation/
    media/libeffects/
    media/libmediametrics/
    media/libnbaio/
    media/libnblog/
    services/audioflinger/
    services/audioparameterparser/
    services/audiopolicy/
    services/medialog/
    services/oboeservice/

# Only turn on clang-format check for the following subfolders.
clang_format = --commit ${PREUPLOAD_COMMIT} --style file --extensions c,h,cc,cpp
               media/libaudioclient/tests/
+1 −4
Original line number Diff line number Diff line
@@ -92,13 +92,10 @@ cc_library {
    cflags: [
        "-Wall",
        "-Werror",
        // By default, all symbols are hidden.

        // "-fvisibility=hidden",
        // AAUDIO_API is used to explicitly export a function or a variable as a visible symbol.
        "-Wno-unused-parameter",
        "-Wthread-safety",

        // AAUDIO_API is used to explicitly export a function or a variable as a visible symbol.
        "-DAAUDIO_API=__attribute__((visibility(\"default\")))",
    ],

+1 −2
Original line number Diff line number Diff line
@@ -26,9 +26,8 @@ cc_defaults {

        // uncomment to disable NEON on architectures that actually do support NEON, for benchmarking

        // "-DUSE_NEON=false",
        "-Werror",

        // "-DUSE_NEON=false",
    ],

    arch: {
+5 −5
Original line number Diff line number Diff line
@@ -16,8 +16,8 @@ cc_library {
    name: "libmediametrics",

    srcs: [
        "MediaMetricsItem.cpp",
        "MediaMetrics.cpp",
        "MediaMetricsItem.cpp",
    ],

    shared_libs: [
@@ -40,8 +40,8 @@ cc_library {

    sanitize: {
        misc_undefined: [
            "unsigned-integer-overflow",
            "signed-integer-overflow",
            "unsigned-integer-overflow",
        ],
        cfi: true,
    },
@@ -51,7 +51,7 @@ cc_library {
        symbol_file: "libmediametrics.map.txt",
        versions: [
            "1",
        ]
        ],
    },

    header_abi_checker: {
+1 −1
Original line number Diff line number Diff line
@@ -115,12 +115,12 @@ audioflinger_base_cflags = [
    "-Wstrict-aliasing",
    "-Wthread-safety",
    //"-Wthread-safety-negative", // experimental - looks broken in R.
    "-fstrict-aliasing",
    "-Wunreachable-code",
    "-Wunreachable-code-break",
    "-Wunreachable-code-return",
    "-Wunused",
    "-Wused-but-marked-unused",
    "-fstrict-aliasing",
]

// Eventually use common tidy defaults
Loading