Quick script to get API access violations.

Test: $ adb logcat | perl find_api_violations.pl

$ perl find_api_violations.pl --help

DESCRIPTION
    This script parses API violations from "adb logcat". Output is in CSV
    format with columns "package", "symbol", "list".

    The package name is mapped from a PID, parsed from the same log. To ensure
    you get all packages names, you should process the logcat from device boot
    time.

SYNOPSIS
      adb logcat | perl find_api_violations.pl > violations.csv
      cat bugreport.txt | perl find_api_violations.pl --bugreport > violations.csv

OPTIONS
    --[no]lightgrey
        (Don't) show light grey list accesses (default true)

    --[no]darkgrey
        (Don't) show dark grey list accesses (default true)

    --[no]black
        (Don't) show black list accesses (default true)

    --bugreport|-b
        Process a bugreport, rather than raw logcat

    --help

Bug: 64382372
Change-Id: Id4baf10412b016a4bfd80bd3bd25cf9ca437601c
1 file changed