Skip to content
This repository was archived by the owner on Nov 21, 2018. It is now read-only.

Attempt to fix duplicate rust-src packages in dist builds #117

Merged
merged 1 commit into from
Aug 16, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions master/master.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -1424,6 +1424,16 @@ def finish_dist(f, local_dist_dir, dist_subdirs, s3_addy, remote_dist_dir, compo
f.addStep(MasterShellCommand(name="rm commit-id",
command=["sh", "-c", rm_commit_ids_cmd]))

# Remove the rust-src package from all but the 'linux' platform. This
# package is produced by all builders and if we don't drop the dupes now
# then the subsequent 'cp' command to consolidate them will fail.
non_linux_dist_subdirs = list(dist_subdirs)
non_linux_dist_subdirs = non_linux_dist_subdirs.remove("linux")
non_linux_dist_dirs = [(local_dist_dir + "/" + p) for p in non_linux_dist_subdirs]
rm_dupes_cmd = "find " + " ".join(non_linux_dist_dirs) + " -name rust-src-" + channel + ".tar.gz | xargs rm -f"
f.addStep(MasterShellCommand(name="removing duplicate source packages",
command=["sh", "-c", WithProperties(rm_dupes_cmd)]))

# Consolidate everything that's left under one directory for final upload. There
# should be no duplicate artifacts across platforms at this point.
final_dist_dir = local_dist_dir + "/final"
Expand Down