Functor cache does not work in address sanitizer builds
See for example https://lhcb-nightlies.web.cern.ch/nightly/lhcb-sanitizers/1013/Rec/x86_64_v2-centos7-gcc11-dbg+asan/build
(build/Phys/FunctorCache)$ build/run env LOKI_GENERATE_CPPCODE=2 LOKI_DISABLE_CACHE=1 gaudirun.py LHCb/InstallArea/x86_64_v2-centos7-gcc11-dbg+asan/lib/cmake/LHCb/disable_expandvars.py FunctorDatahandleTest.pkl
# Restarting with LD_PRELOAD='libasan.so'
# --> Including file 'LHCb/InstallArea/x86_64_v2-centos7-gcc11-dbg+asan/lib/cmake/LHCb/disable_expandvars.py'
# <-- End of file 'LHCb/InstallArea/x86_64_v2-centos7-gcc11-dbg+asan/lib/cmake/LHCb/disable_expandvars.py'
# --> Including file 'build/Phys/FunctorCache/FunctorDatahandleTest_srcs/FunctorDatahandleTest.pkl'
# Unpickled 15 configurables
# <-- End of file 'build/Phys/FunctorCache/FunctorDatahandleTest_srcs/FunctorDatahandleTest.pkl'
ApplicationMgr SUCCESS
====================================================================================================================================
Welcome to Rec version 34.4
running on lbbuild302.cern.ch on Sun Aug 14 01:22:42 2022
====================================================================================================================================
==55464==You are trying to dlopen a ./FunctorJitLib_0xc4aa0af5d7f51ec0_0x766d3029f2fd796f.so shared library with RTLD_DEEPBIND flag which is incompatible with sanitizer runtime (see https://github.com/google/sanitizers/issues/611 for details). If you want to run ./FunctorJitLib_0xc4aa0af5d7f51ec0_0x766d3029f2fd796f.so library under sanitizers please remove RTLD_DEEPBIND from dlopen flags.
[command exited with 1]
@chasse could you take a look what would be good fix/workaround?