• A
    perf build: Allow explicitely disabling the NO_SYSCALL_TABLE variable · 43de3869
    Arnaldo Carvalho de Melo 提交于
    This is useful to see if, on x86, the legacy libaudit still works, as it
    is used in architectures that don't have the SYSCALL_TABLE logic and we
    want to have it tested in 'make -C tools/perf/ build-test'.
    
    E.g.:
    
    Without having audit-libs-devel installed:
    
      $ make NO_SYSCALL_TABLE=1 O=/tmp/build/perf -C tools/perf install-bin
      make: Entering directory '/home/acme/git/perf/tools/perf'
        BUILD:   Doing 'make -j12' parallel build
      <SNIP>
      Auto-detecting system features:
      <SNIP>
      ...                      libaudit: [ OFF ]
      ...                        libbfd: [ on  ]
      ...                        libcap: [ on  ]
      <SNIP>
      Makefile.config:664: No libaudit.h found, disables 'trace' tool, please install audit-libs-devel or libaudit-dev
      <SNIP>
    
    After installing it:
    
      $ rm -rf /tmp/build/perf ; mkdir -p /tmp/build/perf
      $ time make NO_SYSCALL_TABLE=1 O=/tmp/build/perf  -C tools/perf install-bin ; perf test python
      make: Entering directory '/home/acme/git/perf/tools/perf'
        BUILD:   Doing 'make -j12' parallel build
        HOSTCC   /tmp/build/perf/fixdep.o
        HOSTLD   /tmp/build/perf/fixdep-in.o
        LINK     /tmp/build/perf/fixdep
      Warning: Kernel ABI header at 'tools/arch/x86/include/asm/msr-index.h' differs from latest version at 'arch/x86/include/asm/msr-index.h'
      diff -u tools/arch/x86/include/asm/msr-index.h arch/x86/include/asm/msr-index.h
      Warning: Kernel ABI header at 'tools/perf/util/hashmap.h' differs from latest version at 'tools/lib/bpf/hashmap.h'
      diff -u tools/perf/util/hashmap.h tools/lib/bpf/hashmap.h
      Warning: Kernel ABI header at 'tools/perf/util/hashmap.c' differs from latest version at 'tools/lib/bpf/hashmap.c'
      diff -u tools/perf/util/hashmap.c tools/lib/bpf/hashmap.c
    
      Auto-detecting system features:
      <SNIP>
      ...                      libaudit: [ on  ]
      ...                        libbfd: [ on  ]
      ...                        libcap: [ on  ]
      <SNIP>
      $ ldd ~/bin/perf | grep audit
      	libaudit.so.1 => /lib64/libaudit.so.1 (0x00007fc18978e000)
      $
    Acked-by: NJiri Olsa <jolsa@kernel.org>
    Cc: Adrian Hunter <adrian.hunter@intel.com>
    Cc: Ingo Molnar <mingo@kernel.org>
    Cc: Namhyung Kim <namhyung@kernel.org>
    Link: http://lore.kernel.org/lkml/20200529155552.463-3-acme@kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
    43de3869
Makefile.perf 36.5 KB