Skip to content

Commit 5a5ecae

Browse files
committed
upgrade to flatbuffers 1.12, add docker
1 parent 42a71b2 commit 5a5ecae

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

92 files changed

+3803
-912
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ notifications:
55
slack:
66
secure: Vd9YKWhC8eRvQ4l0MC1HkjFYqOrN4ZL00zLFMcu//j/kttyEHl0bekjVyWZaTWISJtSq+5UzDyhXjrDOIkKr5coCO4qL3HDc7t2ksSNwfzcHG0ErMW4ho2VtbN8OTfwhwSV5EUdgfqokgg9ONMPeHYsqVZgEYr2TQuDius5zJ/aoiAStuc2hUrTu2z9he4hXcYGCmlbNN0kfBPE2PV/RdZfFLYlfgjKVm0ztInLdGAvWjJY69YTt72Ubt5arrgfFLa/j8/gtvYwwVJ9PaMdExeI62ulplsmqt9kZ8vW6SScHg6vVwj79WExS4s4suXvrF7bUDtqjzeiBU+zDPDgFSFk0f0o9qAc4DiA2er+jEDHM8Q3G/JTdp2ODQMSYWfOX/LAK2TnyqIhGAeNHtwgyTidAGdwAtmgrIHUVan/c366nbJ9Y/GzYepouTUA1VzRnjiI+Qla8u/rJfN230YffHxXmeNnsgc5/Rt4F3gK9rKQFkaDZp86WaiIn6WWG8jatCHgl4ya4o5mlcn4Ftw7ZVv7xkAm58MXpx47BWDb3OcI0ML1ige7ixTBNG6q5Ah1FYHOguMW7JefJTrW60ZSHFupAI959prmaXkFfHu31KRzya/eGgG+Uag0u9Bjc1DUohoJdOFdrqyiK9exMWWnFU5US5Edv9uG8q0WVDZfhKGc=
77
install:
8-
- git clone --branch v1.10.0 https://github.com/google/flatbuffers.git && cd flatbuffers
8+
- git clone --branch v1.12.0 https://github.com/google/flatbuffers.git && cd flatbuffers
99
&& cmake -G "Unix Makefiles" && sudo make install && sudo cp flatc /usr/local/bin/
1010
&& cd ..
1111
script:

Dockerfile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
FROM ubuntu:18.04
2+
3+
RUN apt-get update && apt-get install -y git cmake gcc-5 g++-5 libzmq3-dev
4+
ENV CC=gcc-5
5+
ENV CXX=g++-5
6+
7+
WORKDIR /home
8+
RUN git clone --branch v1.12.0 https://github.com/google/flatbuffers.git
9+
RUN cd flatbuffers && cmake -G "Unix Makefiles" && make install && cp flatc /usr/local/bin/

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,32 @@ We provide `PPX` compiled to all programming languages officially supported by f
2020
* Go
2121
* Java
2222
* JavaScript
23+
* Kotlin
2324
* Lobster
2425
* Lua
2526
* PHP
2627
* Python
2728
* Rust
29+
* Swift
2830
* TypeScript
2931

32+
## Build
33+
34+
In order to recompile PPX to all supported languages, you can clone this repository and run the flatbuffers compiler in a Docker container as follows.
35+
36+
Prerequisite: Install [Docker](https://hub.docker.com/search/?type=edition&offering=community) for your system.
37+
38+
39+
```
40+
git clone https://github.com/pyprob/ppx.git
41+
cd ppx
42+
docker build -t ppx .
43+
export UID=$(id -u)
44+
export GID=$(id -g)
45+
docker run --user $UID:$GID --rm -it -v $PWD:/home ppx sh compile.sh
46+
```
47+
48+
3049
## License
3150

3251
`PPX` is distributed under the BSD License.

compile.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,14 @@ echo Compiling PPX to JavaScript...
3030
rm -rf js
3131
flatc --js -o js ppx.fbs
3232

33+
echo Compiling PPX to Json schema...
34+
rm -rf jsonschema
35+
flatc --jsonschema -o jsonschema ppx.fbs
36+
37+
echo Compiling PPX to Kotlin...
38+
rm -rf kotlin
39+
flatc --kotlin -o kotlin ppx.fbs
40+
3341
echo Compiling PPX to Lobster...
3442
rm -rf lobster
3543
flatc --lobster -o lobster ppx.fbs
@@ -50,6 +58,10 @@ echo Compiling PPX to Rust...
5058
rm -rf rust
5159
flatc --rust -o rust ppx.fbs
5260

61+
echo Compiling PPX to Swift...
62+
rm -rf swift
63+
flatc --swift -o swift ppx.fbs
64+
5365
echo Compiling PPX to TypeScript...
5466
rm -rf ts
5567
flatc --ts -o ts ppx.fbs

0 commit comments

Comments
 (0)