After configuring and building with --enable-perfmon: % readelf -d /usr/bin/stap | grep NEEDED 0x00000001 (NEEDED) Shared library: [libpfm3.so.3] 0x00000001 (NEEDED) Shared library: [libelf.so.1] 0x00000001 (NEEDED) Shared library: [libstdc++.so.6] 0x00000001 (NEEDED) Shared library: [libm.so.6] 0x00000001 (NEEDED) Shared library: [libgcc_s.so.1] 0x00000001 (NEEDED) Shared library: [libc.so.6] % readelf -d /usr/bin/lket-b2a | grep NEEDED 0x00000001 (NEEDED) Shared library: [libpfm3.so.3] 0x00000001 (NEEDED) Shared library: [libglib-2.0.so.0] 0x00000001 (NEEDED) Shared library: [libc.so.6] % readelf -d /usr/lib/systemtap/stpd | grep NEEDED 0x00000001 (NEEDED) Shared library: [libpfm3.so.3] 0x00000001 (NEEDED) Shared library: [libpthread.so.0] 0x00000001 (NEEDED) Shared library: [libc.so.6] But only stap binary actually uses libpfm.
This was fixed incidentally to the suspension of the perfmon code in the translator. Once it returns, we'll make sure that such LIBS are kept to the appropriate binaries.