Merge pull request #5929 from JonnyH/PR/fix-oprofile-build-linked-as-needed Fix OPROFILE linux build with -Wl,--as-needed