Skip to content

cmBinUtilsLinuxELFLinker: Cache ldconfig results

Running GetLDConfigPaths in every ScanDependencies is expensive.

After a point, in our CI, our packaging times started to surpass our build times. After instrumenting cpack, I saw most of the time was spent cmLDConfigLDConfigTool::GetLDConfigPaths. After this change one of our cpack script, mostly installs shared libraries via install(RUNTIME_DEPENDENCY_SET) is down from 6 minutes to 2 minutes.

Edited by Brad King

Merge request reports