Support genrules as CrtBegin and CrtEnd in rust
Musl will use a genrule output as a linker script in CrtBegin, support genrules as Crt* dependencies. This is equivalent to Ie384089d26459797d0b4b5fef84846507fc508ad in cc. Bug: 216192129 Test: m USE_HOST_MUSL=true host-native Change-Id: Ibc08fdcff7a6bca2a1ec05b781ce929080e211bd
This commit is contained in:
@@ -1224,6 +1224,13 @@ func (mod *Module) depsToPaths(ctx android.ModuleContext) PathDeps {
|
|||||||
lib.exportLinkDirs(linkPath)
|
lib.exportLinkDirs(linkPath)
|
||||||
lib.exportLinkObjects(linkObject.String())
|
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 {
|
if srcDep, ok := dep.(android.SourceFileProducer); ok {
|
||||||
|
Reference in New Issue
Block a user