benchmark icon indicating copy to clipboard operation
benchmark copied to clipboard

[BUG] PFM_ROOT is not used when ENABLE_LIBPFM=ON

Open chipot opened this issue 1 year ago • 0 comments

Describe the bug The usual way to point cmake to a dependency via <Name>_ROOT variable or via CMAKE_PREFIX_PATH is not working.

System Which OS, compiler, and compiler version are you using:

  • OS: Linux
  • Compiler and version: GCC 13.0

To reproduce Steps to reproduce the behavior:

  1. pull main branch
  2. build/install libpfm4 anywhere except in standard system path
  3. cmake -D BENCHMARK_ENABLE_LIBPFM=ON -D PFM_ROOT=/the/path/to/libpfm4/
  4. cmake configure succeeds, but did not find libpfm, and thus the support is disabled.

Expected behavior I expected to be able to inject PFM_ROOT to where I installed libpfm, but could not. Looking into it more, the custom FindPFM.cmake module is not doing the right thing.

chipot avatar Jul 10 '23 16:07 chipot