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

Commit 9139ce1

Browse files
authored
Merge pull request #117 from rust-lang/dupes
Attempt to fix duplicate rust-src packages in dist builds
2 parents cd1ab26 + 5486ad1 commit 9139ce1

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

master/master.cfg

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1424,6 +1424,16 @@ def finish_dist(f, local_dist_dir, dist_subdirs, s3_addy, remote_dist_dir, compo
14241424
f.addStep(MasterShellCommand(name="rm commit-id",
14251425
command=["sh", "-c", rm_commit_ids_cmd]))
14261426

1427+
# Remove the rust-src package from all but the 'linux' platform. This
1428+
# package is produced by all builders and if we don't drop the dupes now
1429+
# then the subsequent 'cp' command to consolidate them will fail.
1430+
non_linux_dist_subdirs = list(dist_subdirs)
1431+
non_linux_dist_subdirs = non_linux_dist_subdirs.remove("linux")
1432+
non_linux_dist_dirs = [(local_dist_dir + "/" + p) for p in non_linux_dist_subdirs]
1433+
rm_dupes_cmd = "find " + " ".join(non_linux_dist_dirs) + " -name rust-src-" + channel + ".tar.gz | xargs rm -f"
1434+
f.addStep(MasterShellCommand(name="removing duplicate source packages",
1435+
command=["sh", "-c", WithProperties(rm_dupes_cmd)]))
1436+
14271437
# Consolidate everything that's left under one directory for final upload. There
14281438
# should be no duplicate artifacts across platforms at this point.
14291439
final_dist_dir = local_dist_dir + "/final"

0 commit comments

Comments
 (0)