Use protobuf-gradle-plugin to replace a system dependency

This commit is contained in:
iadgovuser29 2023-09-24 11:59:32 -04:00
parent 23d3d61448
commit b3481f1668

View File

@ -1,6 +1,7 @@
plugins {
id 'java'
id 'io.spring.dependency-management' version '1.1.0'
id 'com.google.protobuf' version '0.9.4'
}
java {
@ -50,13 +51,18 @@ dependencies {
annotationProcessor libs.lombok
}
task generateProtoBuf(type:Exec) {
workingDir 'config'
commandLine './genJavaProtoBuf.sh'
protobuf {
protoc {
artifact = 'com.google.protobuf:protoc:3.24.3'
}
}
sourceSets {
main {
proto {
srcDir '../HIRS_ProvisionerTPM2/src'
}
}
}
compileJava.dependsOn generateProtoBuf
test {
useJUnitPlatform()