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

Commit 9c176432 authored by Anton Hansson's avatar Anton Hansson Committed by Gerrit Code Review
Browse files

Merge "Convert merged srcjar rule to Android.bp"

parents c1bd0480 a934428b
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -178,6 +178,18 @@ genrule {
        "$(location :frameworks-base-api-module-lib-current.txt)",
}

genrule {
    name: "frameworks-base-api-current.srcjar",
    tools: ["merge_zips"],
    out: ["current.srcjar"],
    cmd: "$(location merge_zips) $(out) $(in)",
    srcs: [
        ":api-stubs-docs-non-updatable",
        ":all-modules-public-stubs-source",
    ],
    visibility: ["//visibility:private"], // Used by make module in //development, mind
}

// This produces the same annotations.zip as framework-doc-stubs, but by using
// outputs from individual modules instead of all the source code.
genrule_defaults {
+0 −13
Original line number Diff line number Diff line
@@ -147,17 +147,6 @@ func createMergedTxt(ctx android.LoadHookContext, txt MergedTxtDefinition) {
	ctx.CreateModule(genrule.GenRuleFactory, &props)
}

func createMergedStubsSrcjar(ctx android.LoadHookContext, modules []string) {
	props := genruleProps{}
	props.Name = proptools.StringPtr(ctx.ModuleName() + "-current.srcjar")
	props.Tools = []string{"merge_zips"}
	props.Out = []string{"current.srcjar"}
	props.Cmd = proptools.StringPtr("$(location merge_zips) $(out) $(in)")
	props.Srcs = append([]string{":api-stubs-docs-non-updatable"}, createSrcs(modules, "{.public.stubs.source}")...)
	props.Visibility = []string{"//visibility:private"} // Used by make module in //development, mind
	ctx.CreateModule(genrule.GenRuleFactory, &props)
}

func createMergedAnnotationsFilegroups(ctx android.LoadHookContext, modules, system_server_modules []string) {
	for _, i := range []struct{
		name    string
@@ -382,8 +371,6 @@ func (a *CombinedApis) createInternalModules(ctx android.LoadHookContext) {
	}
	createMergedTxts(ctx, bootclasspath, system_server_classpath)

	createMergedStubsSrcjar(ctx, bootclasspath)

	createMergedPublicStubs(ctx, bootclasspath)
	createMergedSystemStubs(ctx, bootclasspath)
	createMergedTestStubsForNonUpdatableModules(ctx)