Capture snapshot headers in parallel
VNDK and vendor snapshot singleton work in a single thread, so globbing in singleton results in ridiculus running time. Moving codes to GenerateAndroidBuildActions to reduce running time. Bug: 150406226 Test: VNDK_SNAPSHOT_BUILD_ARTIFACTS=true m dist vndk vendor-snapshot Test: vendorSnapshotSingleton build time became 0.56s (from 10s) Test: build.ninja building time became 1m11s (from 1m21s) Change-Id: I4a081eef5847c62ca00280ca426f5b4e10f87b59
This commit is contained in:
7
cc/cc.go
7
cc/cc.go
@@ -1465,6 +1465,13 @@ func (c *Module) GenerateAndroidBuildActions(actx android.ModuleContext) {
|
||||
c.Properties.HideFromMake = false // unhide
|
||||
// Note: this is still non-installable
|
||||
}
|
||||
|
||||
// glob exported headers for snapshot, if BOARD_VNDK_VERSION is current.
|
||||
if i, ok := c.linker.(snapshotLibraryInterface); ok && ctx.DeviceConfig().VndkVersion() == "current" {
|
||||
if isSnapshotAware(ctx, c) {
|
||||
i.collectHeadersForSnapshot(ctx)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if c.installable() {
|
||||
|
Reference in New Issue
Block a user