Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f9f641ec authored by Colin Cross's avatar Colin Cross Committed by android-build-merger
Browse files

Only add SDK file dependencies on device builds

am: 300f0388

Change-Id: I83b407f2a90a4bd41b54eb5091dc7a25f8f9e2cf
parents ce7d3a06 300f0388
Loading
Loading
Loading
Loading
+9 −7
Original line number Diff line number Diff line
@@ -571,6 +571,7 @@ func checkLinkType(ctx android.ModuleContext, from *Module, to *Library, tag dep
func (j *Module) collectDeps(ctx android.ModuleContext) deps {
	var deps deps

	if ctx.Device() {
		sdkDep := decodeSdkDep(ctx, String(j.deviceProperties.Sdk_version))
		if sdkDep.invalidVersion {
			ctx.AddMissingDependencies([]string{sdkDep.module})
@@ -579,6 +580,7 @@ func (j *Module) collectDeps(ctx android.ModuleContext) deps {
			deps.classpath = append(deps.classpath, sdkDep.jar)
			deps.aidlIncludeDirs = append(deps.aidlIncludeDirs, sdkDep.aidl)
		}
	}

	ctx.VisitDirectDeps(func(module android.Module) {
		otherName := ctx.OtherModuleName(module)