Merge branch 'windows_fixes' into 'master'
Disable windows swift generation See merge request vato007/picar!2
This commit is contained in:
@@ -16,7 +16,8 @@ task copyPythonCode(type: Copy, dependsOn: configurations.python){
|
|||||||
}
|
}
|
||||||
|
|
||||||
task build(type: Exec, dependsOn: copyPythonCode) {
|
task build(type: Exec, dependsOn: copyPythonCode) {
|
||||||
commandLine 'python3', 'setup.py', 'bdist_wheel'
|
executable 'python3'
|
||||||
|
args 'setup.py', 'bdist_wheel'
|
||||||
}
|
}
|
||||||
|
|
||||||
task clean {
|
task clean {
|
||||||
|
|||||||
@@ -6,3 +6,4 @@ u-msgpack-python
|
|||||||
grpcio-tools
|
grpcio-tools
|
||||||
rplidar
|
rplidar
|
||||||
pyzmq
|
pyzmq
|
||||||
|
wheel
|
||||||
@@ -22,19 +22,21 @@ configurations {
|
|||||||
protobuf {
|
protobuf {
|
||||||
protoc { artifact = 'com.google.protobuf:protoc:3.11.0' }
|
protoc { artifact = 'com.google.protobuf:protoc:3.11.0' }
|
||||||
plugins {
|
plugins {
|
||||||
swift {
|
|
||||||
path = "$projectDir/grpc_plugins/protoc-gen-swift"
|
|
||||||
}
|
|
||||||
grpc {
|
grpc {
|
||||||
artifact = 'io.grpc:protoc-gen-grpc-java:1.28.1' // CURRENT_GRPC_VERSION
|
artifact = 'io.grpc:protoc-gen-grpc-java:1.28.1' // CURRENT_GRPC_VERSION
|
||||||
}
|
}
|
||||||
grpc_python {
|
grpc_python {
|
||||||
path = "$projectDir/grpc_plugins/grpc_python_plugin_1.28.1-${osdetector.classifier}"
|
path = "$projectDir/grpc_plugins/grpc_python_plugin_1.28.1-${osdetector.classifier}"
|
||||||
}
|
}
|
||||||
|
if(osdetector.os != 'windows'){
|
||||||
|
swift {
|
||||||
|
path = "$projectDir/grpc_plugins/protoc-gen-swift"
|
||||||
|
}
|
||||||
grpc_swift {
|
grpc_swift {
|
||||||
path = "$projectDir/grpc_plugins/protoc-gen-grpc-swift-$osdetector.classifier"
|
path = "$projectDir/grpc_plugins/protoc-gen-grpc-swift-$osdetector.classifier"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
generateProtoTasks {
|
generateProtoTasks {
|
||||||
all().each { task ->
|
all().each { task ->
|
||||||
task.builtins {
|
task.builtins {
|
||||||
@@ -43,13 +45,14 @@ protobuf {
|
|||||||
python {}
|
python {}
|
||||||
}
|
}
|
||||||
task.plugins {
|
task.plugins {
|
||||||
swift{}
|
|
||||||
grpc { // Options added to --grpc_out
|
grpc { // Options added to --grpc_out
|
||||||
option 'lite'
|
option 'lite'
|
||||||
}
|
}
|
||||||
grpc_python {
|
grpc_python {
|
||||||
outputSubDir = 'python'
|
outputSubDir = 'python'
|
||||||
}
|
}
|
||||||
|
if(osdetector.os != 'windows'){
|
||||||
|
swift{}
|
||||||
grpc_swift {
|
grpc_swift {
|
||||||
outputSubDir = 'swift'
|
outputSubDir = 'swift'
|
||||||
}
|
}
|
||||||
@@ -57,6 +60,7 @@ protobuf {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
task packPythonGrpc(type: Zip, dependsOn: protobuf.generateProtoTasks.all()) {
|
task packPythonGrpc(type: Zip, dependsOn: protobuf.generateProtoTasks.all()) {
|
||||||
from protobuf.generatedFilesBaseDir + '/main/python'
|
from protobuf.generatedFilesBaseDir + '/main/python'
|
||||||
|
|||||||
Reference in New Issue
Block a user