Skip to content

Commit 2a5f1fc

Browse files
authored
Updating to latest generators (alecthomas#112)
1 parent 63f0b5b commit 2a5f1fc

19 files changed

+804
-634
lines changed

FlatBufferA.go

Lines changed: 48 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Makefile

Lines changed: 48 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,84 +1,81 @@
11
# This is necessary due to the use of two conflicting generator commands for capnproto
22
.NOTPARALLEL:
33

4-
all: Colfer.go FlatBufferA.go msgp_gen.go structdef-gogo.pb.go structdef.pb.go structdef.capnp.go structdef.capnp2.go gencode.schema.gen.go gencode-unsafe.schema.gen.go structdefxdr_generated.go structdef-bebop.go structdef_msgpackgen.go musgo.go
4+
all: Colfer.go FlatBufferA.go msgp_gen.go structdef-gogo.pb.go structdef.pb.go structdefxdr_generated.go structdef-bebop.go structdef_msgpackgen.go musgo.go
55

66
Colfer.go:
7-
go run github.com/pascaldekloe/colfer/cmd/colf go
7+
go run github.com/pascaldekloe/colfer/cmd/colf@latest go
88
mv goserbench/Colfer.go .
99
rmdir goserbench
1010

1111
FlatBufferA.go: flatbuffers-structdef.fbs
12-
flatc -g flatbuffers-structdef.fbs
13-
mv flatbuffersmodels/FlatBufferA.go FlatBufferA.go
14-
rmdir flatbuffersmodels
15-
sed -i '' 's/flatbuffersmodels/goserbench/' FlatBufferA.go
12+
flatc --go --go-namespace goserbench flatbuffers-structdef.fbs
13+
mv goserbench/FlatBufferA.go FlatBufferA.go
14+
rmdir goserbench
1615

1716
msgp_gen.go: structdef.go
18-
go run github.com/tinylib/msgp -o msgp_gen.go -file structdef.go -io=false -tests=false
17+
go run github.com/tinylib/msgp@latest -o msgp_gen.go -file structdef.go -io=false -tests=false
1918

2019
structdef_easyjson.go: structdef.go
21-
go run github.com/mailru/easyjson/easyjson -no_std_marshalers -all structdef.go
20+
go run github.com/mailru/easyjson/easyjson@latest -no_std_marshalers -all structdef.go
2221

2322
structdef-gogo.pb.go: structdef-gogo.proto
24-
protoc --gogofaster_out=. -I. -I${GOPATH}/src -I${GOPATH}/src/github.com/gogo/protobuf/protobuf structdef-gogo.proto
23+
protoc --gogofaster_opt=paths=source_relative --gogofaster_out=. -I. -I${GOPATH}/src -I${GOPATH}/src/github.com/gogo/protobuf/protobuf structdef-gogo.proto
2524

2625
structdef.pb.go: structdef.proto
27-
protoc --go_out=. structdef.proto
28-
29-
structdef.capnp2.go: structdef.capnp2
30-
go get -u zombiezen.com/go/capnproto2/... # conflicts with go-capnproto
31-
capnp compile -I${GOPATH}/src -ogo structdef.capnp2
26+
protoc --go_opt=paths=source_relative --go_out=. structdef.proto
3227

33-
structdef.capnp.go: structdef.capnp
34-
go get -u github.com/glycerine/go-capnproto/capnpc-go # conflicts with capnproto2
35-
capnp compile -I${GOPATH}/src -ogo structdef.capnp
28+
#structdef.capnp2.go: structdef.capnp2
29+
# go run zombiezen.com/go/capnproto2/capnpc-go@latest compile -I${GOPATH}/src -ogo structdef.capnp2
3630

37-
gencode.schema.gen.go: gencode.schema
38-
go run github.com/andyleap/gencode go -schema=gencode.schema -package=goserbench
31+
#structdef.capnp.go: structdef.capnp
32+
# go run github.com/glycerine/go-capnproto/capnpc-go@latest compile -I${GOPATH}/src -ogo structdef.capnp
3933

40-
gencode-unsafe.schema.gen.go: gencode-unsafe.schema
41-
go run github.com/andyleap/gencode go -schema=gencode-unsafe.schema -package=goserbench -unsafe
34+
#gencode.schema.gen.go: gencode.schema
35+
# go run github.com/andyleap/gencode@latest go -schema=gencode.schema -package=goserbench
36+
#
37+
#gencode-unsafe.schema.gen.go: gencode-unsafe.schema
38+
# go run github.com/andyleap/gencode@latest go -schema=gencode-unsafe.schema -package=goserbench -unsafe
4239

4340
structdefxdr_generated.go: structdefxdr.go
44-
go run github.com/calmh/xdr/cmd/genxdr -o structdefxdr_generated.go structdefxdr.go
41+
go run github.com/calmh/xdr/cmd/genxdr@latest -o structdefxdr_generated.go structdefxdr.go
4542

4643
structdef-bebop.go:
47-
bebopc-go -i structdef-bebop.bop -o structdef-bebop.go --package goserbench
44+
go run github.com/200sc/bebop/main/bebopc-go@latest -i structdef-bebop.bop -o structdef-bebop.go --package goserbench
4845

4946
structdef_msgpackgen.go: structdef.go
50-
go run github.com/shamaton/msgpackgen -input-file structdef.go -output-file structdef_msgpackgen.go -strict
47+
go run github.com/shamaton/msgpackgen@latest -input-file structdef.go -output-file structdef_msgpackgen.go -strict
5148

5249
musgo.go: structdef.go
53-
go run ./musgo/generate.go
50+
go run ./musgo-gen.go
5451

5552
.PHONY: clean
5653
clean:
57-
rm -f Colfer.go FlatBufferA.go msgp_gen.go structdef-gogo.pb.go structdef.pb.go structdef.capnp.go structdef.capnp2.go gencode.schema.gen.go gencode-unsafe.schema.gen.go structdefxdr_generated.go structdef_msgpackgen.go NoTimeA.musgen.go NoTimeAUnsafe.musgen.go
54+
rm -f Colfer.go FlatBufferA.go msgp_gen.go structdef-gogo.pb.go structdef.pb.go structdefxdr_generated.go structdef_msgpackgen.go NoTimeA.musgen.go NoTimeAUnsafe.musgen.go
5855
.PHONY: install
5956
install:
60-
go get -u github.com/gogo/protobuf/protoc-gen-gogofaster
61-
go get -u github.com/gogo/protobuf/gogoproto
62-
go get -u github.com/golang/protobuf/protoc-gen-go
63-
go get -u github.com/tinylib/msgp
64-
go get -u github.com/andyleap/gencode
65-
go get -u github.com/mailru/easyjson/...
66-
go get -u go.dedis.ch/protobuf
67-
go get -u github.com/Sereal/Sereal/Go/sereal
68-
go get -u github.com/alecthomas/binary
69-
go get -u github.com/davecgh/go-xdr/xdr
70-
go get -u github.com/gogo/protobuf/proto
71-
go get -u github.com/google/flatbuffers/go
72-
go get -u github.com/tinylib/msgp/msgp
73-
go get -u github.com/ugorji/go/codec
74-
go get -u gopkg.in/mgo.v2/bson
75-
go get -u github.com/vmihailenco/msgpack/v4
76-
go get -u github.com/golang/protobuf/proto
77-
go get -u github.com/hprose/hprose-go/io
78-
go get -u github.com/pascaldekloe/colfer/cmd/colf
79-
go get -u github.com/calmh/xdr
80-
go get -u github.com/niubaoshu/gotiny
81-
go get -u github.com/200sc/bebop
82-
go get -u github.com/200sc/bebop/main/bebopc-go
83-
go get -u github.com/shamaton/msgpackgen
84-
go get -u github.com/ymz-ncnk/musgo
57+
go install github.com/gogo/protobuf/protoc-gen-gogofaster@latest
58+
go install github.com/gogo/protobuf/gogoproto@latest
59+
go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
60+
go install github.com/tinylib/msgp@latest
61+
go install github.com/andyleap/gencode@latest
62+
go install github.com/mailru/easyjson@latest
63+
go install go.dedis.ch/protobuf@latest
64+
go install github.com/Sereal/Sereal/Go/sereal@latest
65+
go install github.com/alecthomas/binary@latest
66+
go install github.com/davecgh/go-xdr/xdr@latest
67+
go install github.com/gogo/protobuf/proto@latest
68+
go install github.com/google/flatbuffers/go@latest
69+
go install github.com/tinylib/msgp/msgp@latest
70+
go install github.com/ugorji/go/codec@latest
71+
go install gopkg.in/mgo.v2/bson@latest
72+
go install github.com/vmihailenco/msgpack/v5@latest
73+
go install github.com/golang/protobuf/proto@latest
74+
go install github.com/hprose/hprose-go/io@latest
75+
go install github.com/pascaldekloe/colfer/cmd/colf@latest
76+
go install github.com/calmh/xdr@latest
77+
go install github.com/niubaoshu/gotiny@latest
78+
go install github.com/200sc/bebop@latest
79+
go install github.com/200sc/bebop/main/bebopc-go@latest
80+
go install github.com/shamaton/msgpackgen@latest
81+
go install github.com/ymz-ncnk/musgo@latest

MusgoA.musgen.go

100755100644
Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

MusgoAUnsafe.musgen.go

100755100644
Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)