• Ian Rogers's avatar
    perf python: Switch module to linking libraries from building source · 9dabf400
    Ian Rogers authored
    setup.py was building most perf sources causing setup.py to mimic the
    Makefile logic as well as flex/bison code to be stubbed out, due to
    complexity building. By using libraries fewer functions are stubbed
    out, the build is faster and the Makefile logic is reused which should
    simplify updating. The libraries are passed through LDFLAGS to avoid
    complexity in python.
    
    Force the -fPIC flag for libbpf.a to ensure it is suitable for linking
    into the perf python module.
    Signed-off-by: default avatarIan Rogers <irogers@google.com>
    Reviewed-by: default avatarJames Clark <james.clark@arm.com>
    Cc: Suzuki K Poulose <suzuki.poulose@arm.com>
    Cc: Kees Cook <keescook@chromium.org>
    Cc: Palmer Dabbelt <palmer@dabbelt.com>
    Cc: Albert Ou <aou@eecs.berkeley.edu>
    Cc: Nick Terrell <terrelln@fb.com>
    Cc: Gary Guo <gary@garyguo.net>
    Cc: Alex Gaynor <alex.gaynor@gmail.com>
    Cc: Boqun Feng <boqun.feng@gmail.com>
    Cc: Wedson Almeida Filho <wedsonaf@gmail.com>
    Cc: Ze Gao <zegao2021@gmail.com>
    Cc: Alice Ryhl <aliceryhl@google.com>
    Cc: Andrei Vagin <avagin@google.com>
    Cc: Yicong Yang <yangyicong@hisilicon.com>
    Cc: Jonathan Cameron <jonathan.cameron@huawei.com>
    Cc: Guo Ren <guoren@kernel.org>
    Cc: Miguel Ojeda <ojeda@kernel.org>
    Cc: Will Deacon <will@kernel.org>
    Cc: Mike Leach <mike.leach@linaro.org>
    Cc: Leo Yan <leo.yan@linux.dev>
    Cc: Oliver Upton <oliver.upton@linux.dev>
    Cc: John Garry <john.g.garry@oracle.com>
    Cc: Benno Lossin <benno.lossin@proton.me>
    Cc: Björn Roy Baron <bjorn3_gh@protonmail.com>
    Cc: Andreas Hindborg <a.hindborg@samsung.com>
    Cc: Paul Walmsley <paul.walmsley@sifive.com>
    Signed-off-by: default avatarNamhyung Kim <namhyung@kernel.org>
    Link: https://lore.kernel.org/r/20240625214117.953777-8-irogers@google.com
    9dabf400
setup.py 3.51 KB