Merge "Order apex files by destination path not source path"
diff --git a/apex/apex.go b/apex/apex.go
index 26ac457..a8fbf22 100644
--- a/apex/apex.go
+++ b/apex/apex.go
@@ -1980,7 +1980,9 @@
// Sort to have consistent build rules
sort.Slice(filesInfo, func(i, j int) bool {
- return filesInfo[i].builtFile.String() < filesInfo[j].builtFile.String()
+ // Sort by destination path so as to ensure consistent ordering even if the source of the files
+ // changes.
+ return filesInfo[i].path() < filesInfo[j].path()
})
////////////////////////////////////////////////////////////////////////////////////////////