Commits

minux committed 26fc3f8

cmd/dist: remove stray src/pkg/runtime/z* when cleaning

R=golang-dev, bradfitz, dave, rsc, lstoakes, rsc
CC=golang-dev
http://codereview.appspot.com/6180044

  • Participants
  • Parent commits 9f6d21a

Comments (0)

Files changed (1)

src/cmd/dist/build.c

 			xremove(bpathf(&b, "%s/%s", bstr(&path), cleantab[i]+4));
 	}
 
+	// remove src/pkg/runtime/z* unconditionally
+	vreset(&dir);
+	bpathf(&path, "%s/src/pkg/runtime", goroot);
+	xreaddir(&dir, bstr(&path));
+	for(j=0; j<dir.len; j++) {
+		if(hasprefix(dir.p[j], "z"))
+			xremove(bpathf(&b, "%s/%s", bstr(&path), dir.p[j]));
+	}
+
 	if(rebuildall) {
 		// Remove object tree.
 		xremoveall(bpathf(&b, "%s/pkg/obj/%s_%s", goroot, gohostos, gohostarch));