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

Commit 6471db9b authored by Colin Cross's avatar Colin Cross
Browse files

Don't use path to find protoc-gen-javastream

Previous attempts to use a full path in the --plugin argument
failed, but that was because the --plugin argument had the wrong
name (protoc-gen-java-stream instead of protoc-gen-javastream)
and was being completely ignored.  Passing a full path where
the last element of the path is protoc-gen-javastream works fine.

Fixes issues where the command line is expanded with $PATH in
it 58 times which could hit command length limits if $PATH was
even a little bit larger than the default.

Test: m framework
Change-Id: Icd336f522fb8770d9058d18d8a04d24a96405615
parent 85f095e2
Loading
Loading
Loading
Loading
+2 −4
Original line number Diff line number Diff line
@@ -603,11 +603,9 @@ gensrcs {
        "soong_zip",
    ],

    // Append protoc-gen-javastream tool's PATH otherwise aprotoc can't find the plugin tool
    cmd: "export PATH=$$PATH:$$(dirname $(location protoc-gen-javastream)) " +
        "&& mkdir -p $(genDir)/$(in) " +
    cmd: "mkdir -p $(genDir)/$(in) " +
        "&& $(location aprotoc) " +
        "  --plugin=protoc-gen-java-stream=protoc-gen-javastream " +
        "  --plugin=$(location protoc-gen-javastream) " +
        "  --dependency_out=$(depfile) " +
        "  --javastream_out=$(genDir)/$(in) " +
        "  -Iexternal/protobuf/src " +