Skip to content

Commit 60205ad

Browse files
kevintsglbrntt
authored andcommitted
Remove unexported executables from products (#592)
Motivation: From https://developer.apple.com/documentation/swift_packages/product > Executable > Use an executable product to vend an executable target. > Use this only if you want to make the executable available to clients. Several executable products are not meant to be made available to clients, but rather exist for internal integration or performance tests. Further, most of these products are not namespaced and have generic names. The code-generator product, `protoc-gen-grpc-swift`, appears to be the only executable intended for export and it is already appropriately namespaced. Modifications: Unexport the executable products that are not intended for use by clients. Change the `Makefile` to reference the executable targets rather than their derived products. Result: Fewer potential namespace conflicts. This fixed #591.
1 parent 8db70dd commit 60205ad

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ protoc-gen-grpc-swift:
2626
${SWIFT_BUILD} --product protoc-gen-grpc-swift
2727

2828
interop-test-runner:
29-
${SWIFT_BUILD} --product InteroperabilityTestRunner
29+
${SWIFT_BUILD} --target InteroperabilityTestRunner
3030

3131
interop-backoff-test-runner:
32-
${SWIFT_BUILD} --product ConnectionBackoffInteropTestRunner
32+
${SWIFT_BUILD} --target ConnectionBackoffInteropTestRunner
3333

3434
### Xcodeproj and LinuxMain
3535

Package.swift

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,6 @@ let package = Package(
2121
name: "GRPC",
2222
products: [
2323
.library(name: "GRPC", targets: ["GRPC"]),
24-
.executable(name: "InteroperabilityTestRunner", targets: ["GRPCInteroperabilityTests"]),
25-
.executable(name: "ConnectionBackoffInteropTestRunner", targets: ["GRPCConnectionBackoffInteropTest"]),
26-
.executable(name: "PerformanceTestRunner", targets: ["GRPCPerformanceTests"]),
27-
.executable(name: "Echo", targets: ["Echo"]),
2824
.executable(name: "protoc-gen-grpc-swift", targets: ["protoc-gen-grpc-swift"]),
2925
],
3026
dependencies: [

0 commit comments

Comments
 (0)