-
-
Notifications
You must be signed in to change notification settings - Fork 10
/
Makefile.flatbuffers
40 lines (33 loc) · 1.46 KB
/
Makefile.flatbuffers
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
.PHONY: flatbuffers
flatbuffers: flatbuffers_dart flatbuffers_go flatbuffers_ts
flatbuffers_deps:
cd /tmp && \
git clone https://github.com/google/flatbuffers.git -b master && \
cd flatbuffers && \
git checkout v24.3.25 && \
cmake -G "Unix Makefiles" && \
make && \
sudo make install && \
rm -rf /tmp/flatbuffers
flatbuffers_dart:
rm -rf output/flatbuffers/dart && mkdir -p output/flatbuffers/dart
flatc --dart --gen-mutable -o ./output/flatbuffers/dart flatbuffers/*.fbs
flatbuffers_go:
rm -rf output/flatbuffers/go && mkdir -p output/flatbuffers/go
flatc --go --gen-mutable -o ./output/flatbuffers/go flatbuffers/*.fbs
rm -rf bridge/model && mkdir -p bridge/model
cp -r output/flatbuffers/go/model bridge
flatbuffers_ts:
rm -rf output/flatbuffers/ts && mkdir -p output/flatbuffers/ts
flatc --ts --gen-mutable -o ./output/flatbuffers/ts flatbuffers/*.fbs
rm -rf wasm/example/libs && mkdir -p wasm/example/libs
cp -r output/flatbuffers/ts/* wasm/example/libs/
flatbuffers_swift:
rm -rf output/flatbuffers/swift && mkdir -p output/flatbuffers/swift
flatc --swift --gen-mutable -o ./output/flatbuffers/swift flatbuffers/*.fbs
flatbuffers_kotlin:
rm -rf output/flatbuffers/kotlin && mkdir -p output/flatbuffers/kotlin
flatc --kotlin --gen-mutable -o ./output/flatbuffers/kotlin flatbuffers/*.fbs
flatbuffers_java:
rm -rf output/flatbuffers/java && mkdir -p output/flatbuffers/java
flatc --java --gen-mutable -o ./output/flatbuffers/java flatbuffers/*.fbs