You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Makefile
+7-1Lines changed: 7 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,13 @@ all:
9
9
swift build $(CFLAGS)
10
10
cp .build/debug/protoc-gen-swift .
11
11
cp .build/debug/protoc-gen-swiftgrpc .
12
-
12
+
13
+
plugin:
14
+
swift build $(CFLAGS) --product protoc-gen-swift -c release -Xswiftc -static-stdlib
15
+
swift build $(CFLAGS) --product protoc-gen-swiftgrpc -c release -Xswiftc -static-stdlib
16
+
cp .build/release/protoc-gen-swift .
17
+
cp .build/release/protoc-gen-swiftgrpc .
18
+
13
19
project:
14
20
swift package $(CFLAGS) generate-xcodeproj --output SwiftGRPC.xcodeproj
15
21
@-ruby fix-project-settings.rb SwiftGRPC.xcodeproj ||echo"Consider running 'sudo gem install xcodeproj' to automatically set correct indentation settings for the generated project."
Copy file name to clipboardExpand all lines: README.md
+4-2Lines changed: 4 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -71,15 +71,17 @@ generate the necessary support code.
71
71
Binary releases of `protoc`, the Protocol Buffer Compiler, are
72
72
available on [GitHub](https://github.com/google/protobuf/releases).
73
73
74
-
To build the plugins, run `make` in the main directory.
74
+
To build the plugins, run `make plugin` in the main directory.
75
75
This uses the Swift Package Manager to build both of the necessary
76
76
plugins: `protoc-gen-swift`, which generates Protocol Buffer support code
77
77
and `protoc-gen-swiftgrpc`, which generates gRPC interface code.
78
78
79
+
To install these plugins, just copy the two executables (`protoc-gen-swift` and `protoc-gen-swiftgrpc`) that show up in the main directory into a directory that is part of your `PATH` environment variable.
80
+
79
81
### Using the plugins
80
82
81
83
To use the plugins, `protoc` and both plugins should be in your
82
-
search path. Invoke them with commands like the following:
84
+
search path (see above). Invoke them with commands like the following:
0 commit comments