diff --git a/build/fbcode_builder/getdeps.py b/build/fbcode_builder/getdeps.py index c630f45b4..86993e00e 100755 --- a/build/fbcode_builder/getdeps.py +++ b/build/fbcode_builder/getdeps.py @@ -627,8 +627,10 @@ class BuildCmd(ProjectCmdBase): ) builder.build(install_dirs, reconfigure=reconfigure) - with open(built_marker, "w") as f: - f.write(project_hash) + # Update built_marker only if user hasn't built a specific target + if m == manifest and args.cmake_target == "install": + with open(built_marker, "w") as f: + f.write(project_hash) # Only populate the cache from continuous build runs if args.schedule_type == "continuous":