diff --git a/rust/rust.go b/rust/rust.go index ee573fa43..0a941bf2d 100644 --- a/rust/rust.go +++ b/rust/rust.go @@ -1224,6 +1224,13 @@ func (mod *Module) depsToPaths(ctx android.ModuleContext) PathDeps { lib.exportLinkDirs(linkPath) lib.exportLinkObjects(linkObject.String()) } + } else { + switch { + case depTag == cc.CrtBeginDepTag: + depPaths.CrtBegin = append(depPaths.CrtBegin, android.OutputFileForModule(ctx, dep, "")) + case depTag == cc.CrtEndDepTag: + depPaths.CrtEnd = append(depPaths.CrtEnd, android.OutputFileForModule(ctx, dep, "")) + } } if srcDep, ok := dep.(android.SourceFileProducer); ok {