diff --git a/Android.bp b/Android.bp index 151e98bdd..ef42c84c4 100644 --- a/Android.bp +++ b/Android.bp @@ -435,7 +435,7 @@ toolchain_library { src: "prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32/lib/libwinpthread.a", }, }, - notice: ":mingw-libwinpthread-notice", + notice: "../../prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/licenses/mingw-w64-svn-r5861/mingw-w64-libraries/winpthreads/COPYING", } toolchain_library { diff --git a/android/androidmk.go b/android/androidmk.go index f15076800..493ba97e4 100644 --- a/android/androidmk.go +++ b/android/androidmk.go @@ -277,8 +277,8 @@ func translateAndroidModule(ctx SingletonContext, w io.Writer, mod blueprint.Mod } } - if amod.noticeFile != nil { - fmt.Fprintln(&data.preamble, "LOCAL_NOTICE_FILE :=", amod.noticeFile.String()) + if amod.commonProperties.Notice != nil { + fmt.Fprintln(&data.preamble, "LOCAL_NOTICE_FILE :=", "$(LOCAL_PATH)/"+*amod.commonProperties.Notice) } if host { diff --git a/android/module.go b/android/module.go index f24930639..bf49ca29b 100644 --- a/android/module.go +++ b/android/module.go @@ -441,7 +441,6 @@ type ModuleBase struct { noAddressSanitizer bool installFiles Paths checkbuildFiles Paths - noticeFile Path // Used by buildTargetSingleton to create checkbuild and per-directory build targets // Only set on the final variant of each module @@ -790,11 +789,6 @@ func (a *ModuleBase) GenerateBuildActions(blueprintCtx blueprint.ModuleContext) a.installFiles = append(a.installFiles, ctx.installFiles...) a.checkbuildFiles = append(a.checkbuildFiles, ctx.checkbuildFiles...) - - if a.commonProperties.Notice != nil { - // For filegroup-based notice file references. - a.noticeFile = ctx.ExpandSource(*a.commonProperties.Notice, "notice") - } } if a == ctx.FinalModule().(Module).base() { diff --git a/android/mutator.go b/android/mutator.go index b77c2f091..b9c44e83a 100644 --- a/android/mutator.go +++ b/android/mutator.go @@ -207,11 +207,6 @@ func (mutator *mutator) Parallel() MutatorHandle { func depsMutator(ctx BottomUpMutatorContext) { if m, ok := ctx.Module().(Module); ok && m.Enabled() { m.DepsMutator(ctx) - - // For filegroup-based notice file references. - if m.base().commonProperties.Notice != nil { - ExtractSourceDeps(ctx, m.base().commonProperties.Notice) - } } }