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

Commit f87aae53 authored by Ulyana Trafimovich's avatar Ulyana Trafimovich Committed by Gerrit Code Review
Browse files

Merge "Fix handling of "prebuilt_" prefix in classLoaderContextForUsesLibDeps."

parents 9cb1577a e14f80b2
Loading
Loading
Loading
Loading
+3 −3
Original line number Original line Diff line number Diff line
@@ -1262,12 +1262,12 @@ func (u *usesLibrary) classLoaderContextForUsesLibDeps(ctx android.ModuleContext
			return
			return
		}
		}


		dep := ctx.OtherModuleName(m)
		dep := android.RemoveOptionalPrebuiltPrefix(ctx.OtherModuleName(m))


		if lib, ok := m.(UsesLibraryDependency); ok {
		if lib, ok := m.(UsesLibraryDependency); ok {
			libName := android.RemoveOptionalPrebuiltPrefix(dep)
			libName := dep
			if ulib, ok := m.(ProvidesUsesLib); ok && ulib.ProvidesUsesLib() != nil {
			if ulib, ok := m.(ProvidesUsesLib); ok && ulib.ProvidesUsesLib() != nil {
				libName = android.RemoveOptionalPrebuiltPrefix(*ulib.ProvidesUsesLib())
				libName = *ulib.ProvidesUsesLib()
				// Replace module name with library name in `uses_libs`/`optional_uses_libs` in
				// Replace module name with library name in `uses_libs`/`optional_uses_libs` in
				// order to pass verify_uses_libraries check (which compares these properties
				// order to pass verify_uses_libraries check (which compares these properties
				// against library names written in the manifest).
				// against library names written in the manifest).