rust: rust-project.json: Skip disabled modules

Disabled modules may not have a valid root path.

Bug: 313410568
Test: SOONG_GEN_RUST_PROJECT=1 m nothing
Change-Id: I253cca18493193245aa198adfce5fd75cf27cefb
This commit is contained in:
Matthew Maurer 2023-11-27 17:51:58 +00:00
parent db72f7ed80
commit 5a3c71c1aa

View file

@ -119,6 +119,9 @@ func isModuleSupported(ctx android.SingletonContext, module android.Module) (*Mo
if !ok {
return nil, false
}
if !rModule.Enabled() {
return nil, false
}
return rModule, true
}