--- a/Ghidra/Debug/Debugger-rmi-trace/build.gradle +++ b/Ghidra/Debug/Debugger-rmi-trace/build.gradle @@ -40,9 +40,5 @@ task configureGenerateProtoPy { - dependsOn(configurations.protocArtifact) - doLast { - def exe = configurations.protocArtifact.first() - if (!isCurrentWindows()) { - exe.setExecutable(true) - } + // protoc from dev-libs/protobuf, on PATH as a BDEPEND + def exe = "protoc" generateProtoPy.commandLine exe --- a/gradle/hasProtobuf.gradle +++ b/gradle/hasProtobuf.gradle @@ -19,7 +19,2 @@ -configurations { - allProtocArtifacts - protocArtifact -} - def platform = getCurrentPlatformName() @@ -29,32 +24,2 @@ -dependencies { - allProtocArtifacts "com.google.protobuf:protoc:${version}:windows-x86_64@exe" - allProtocArtifacts "com.google.protobuf:protoc:${version}:linux-x86_64@exe" - allProtocArtifacts "com.google.protobuf:protoc:${version}:linux-aarch_64@exe" - allProtocArtifacts "com.google.protobuf:protoc:${version}:osx-x86_64@exe" - allProtocArtifacts "com.google.protobuf:protoc:${version}:osx-aarch_64@exe" - - if (isCurrentWindows()) { - protocArtifact "com.google.protobuf:protoc:${version}:windows-x86_64@exe" - } - if (isCurrentLinux()) { - if (platform.endsWith("x86_64")) { - protocArtifact "com.google.protobuf:protoc:${version}:linux-x86_64@exe" - } - else { - protocArtifact "com.google.protobuf:protoc:${version}:linux-aarch_64@exe" - } - } - if (isCurrentMac()) { - if (platform.endsWith("x86_64")) { - protocArtifact "com.google.protobuf:protoc:${version}:osx-x86_64@exe" - } - else { - protocArtifact "com.google.protobuf:protoc:${version}:osx-aarch_64@exe" - } - } - if (isCurrentOpenBSD()) { - protocArtifact files('/usr/local/bin/protoc') - } -} @@ -67,9 +32,5 @@ task configureGenerateProto { - dependsOn(configurations.protocArtifact) - doLast { - def exe = configurations.protocArtifact.first() - if (!isCurrentWindows()) { - exe.setExecutable(true) - } + // protoc from dev-libs/protobuf, on PATH as a BDEPEND + def exe = "protoc" generateProto.commandLine exe, "--java_out=${generateProto.outdir}", "-I${generateProto.srcdir}" --- a/Ghidra/Debug/ProposedUtils/build.gradle +++ b/Ghidra/Debug/ProposedUtils/build.gradle @@ -29,3 +29,3 @@ dependencies { - api "com.google.protobuf:protobuf-java:${version}" + api files(System.getenv("GENTOO_PROTOBUF_JAR")) api project(':DB') @@ -43 +43,7 @@ } + +jar { + manifest { + attributes("Class-Path": file(System.getenv("GENTOO_PROTOBUF_JAR")).toURI().toString()) + } +} --- /dev/null +++ b/Ghidra/Debug/Debugger-rmi-trace/src/test/java/ghidra/rmi/trace/TraceRmiVersionTest.java @@ -0,0 +1,16 @@ +/* ### + * IP: Apache License 2.0 + */ + +package ghidra.rmi.trace; + +import static org.junit.Assert.assertEquals; + +import org.junit.Test; + +public class TraceRmiVersionTest { + @Test + public void testGeneratedDescriptor() { + assertEquals("trace-rmi.proto", TraceRmi.getDescriptor().getName()); + } +}