aboutsummaryrefslogtreecommitdiff
path: root/examples/addressbook/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'examples/addressbook/Makefile')
-rw-r--r--examples/addressbook/Makefile12
1 files changed, 12 insertions, 0 deletions
diff --git a/examples/addressbook/Makefile b/examples/addressbook/Makefile
new file mode 100644
index 0000000..7fe8add
--- /dev/null
+++ b/examples/addressbook/Makefile
@@ -0,0 +1,12 @@
+PLUGIN = ../../generator/protoc_gen_nim
+
+all: writer reader
+
+writer: writer.nim addressbook_pb.nim
+ nim c writer.nim
+
+reader: reader.nim addressbook_pb.nim
+ nim c reader.nim
+
+addressbook_pb.nim: addressbook.proto
+ protoc --plugin=protoc-gen-nim=$(PLUGIN) --nim_out=. -I. addressbook.proto