A non‐negligible fraction of the build process — especially for
incremental builds — is spent calling normpath() over and over again.
Make builds faster by not doing that.
Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
"""before apply_obj_vars for uselib, this removes the standard paths"""
def is_standard_libpath(env, path):
+ normalized_path = os.path.normpath(path)
for _path in env.STANDARD_LIBPATH:
- if _path == os.path.normpath(path):
+ if _path == normalized_path:
return True
return False