forked from google/flatbuffers
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from hollinwilkins/rust_support
Rust support
- Loading branch information
Showing
273 changed files
with
33,058 additions
and
7,814 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
Thank you for submitting an issue! | ||
|
||
Please make sure you include the names of the affected language(s), compiler version(s), operating system version(s), and FlatBuffers version(s) in your issue title. | ||
|
||
This helps us get the correct maintainers to look at your issue. Here are examples of good titles: | ||
|
||
- Crash when accessing FlatBuffer [C++, gcc 4.8, OS X, master] | ||
- Flatc converts a protobuf 'bytes' field to 'string' in fbs schema file [all languages, FlatBuffers 1.4] | ||
|
||
Include other details as appropriate. | ||
|
||
Thanks! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
Thank you for submitting a PR! | ||
|
||
Please make sure you include the names of the affected language(s) in your PR title. | ||
This helps us get the correct maintainers to look at your issue. | ||
|
||
If you make changes to any of the code generators, be sure to run | ||
`cd tests && sh generate_code.sh` (or equivalent .bat) and include the generated | ||
code changes in the PR. This allows us to better see the effect of the PR. | ||
|
||
If your PR includes C++ code, please adhere to the Google C++ Style Guide, | ||
and don't forget we try to support older compilers (e.g. VS2010, GCC 4.6.3), | ||
so only some C++11 support is available. | ||
|
||
Include other details as appropriate. | ||
|
||
Thanks! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,58 @@ | ||
language: cpp | ||
|
||
os: | ||
- linux | ||
- osx | ||
|
||
compiler: | ||
- gcc | ||
#- clang | ||
|
||
env: | ||
matrix: | ||
- BUILD_TYPE=Debug BIICODE=false | ||
- BUILD_TYPE=Release BIICODE=false | ||
# biicode .deb files no longer available. | ||
# - BUILD_TYPE=Release BIICODE=true | ||
# - BUILD_TYPE=Debug BIICODE=true | ||
global: | ||
# Set at the root level as this is ignored when set under matrix.env. | ||
- GCC_VERSION="4.9" | ||
matrix: | ||
include: | ||
- language: cpp | ||
os: | ||
- linux | ||
- osx | ||
|
||
compiler: | ||
- gcc | ||
#- clang | ||
|
||
env: | ||
matrix: | ||
- BUILD_TYPE=Debug BIICODE=false | ||
- BUILD_TYPE=Release BIICODE=false | ||
# biicode .deb files no longer available. | ||
# - BUILD_TYPE=Release BIICODE=true | ||
# - BUILD_TYPE=Debug BIICODE=true | ||
|
||
before_install: | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get update -qq; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install -qq g++-$GCC_VERSION; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install -qq gcc-$GCC_VERSION; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo ln -s -v -f $(which g++-$GCC_VERSION) /usr/bin/g++; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo ln -s -v -f $(which gcc-$GCC_VERSION) /usr/bin/gcc; fi | ||
|
||
script: | ||
- if [ "$BIICODE" == "false" ]; then cmake -DCMAKE_BUILD_TYPE=$BUILD_TYPE . && make && make test; fi | ||
- if [ "$BIICODE" == "true" ] && [ "$TRAVIS_OS_NAME" == "linux" ]; then ./biicode/support/bii-travis.sh $BUILD_TYPE; fi | ||
|
||
before_install: | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get update -qq; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install -qq g++-$GCC_VERSION; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install -qq gcc-$GCC_VERSION; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo ln -s -v -f $(which g++-$GCC_VERSION) /usr/bin/g++; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo ln -s -v -f $(which gcc-$GCC_VERSION) /usr/bin/gcc; fi | ||
|
||
script: | ||
- if [ "$BIICODE" == "false" ]; then cmake -DCMAKE_BUILD_TYPE=$BUILD_TYPE . && make && make test; fi | ||
- if [ "$BIICODE" == "true" ] && [ "$TRAVIS_OS_NAME" == "linux" ]; then ./biicode/support/bii-travis.sh $BUILD_TYPE; fi | ||
- language: android | ||
sudo: true | ||
android: | ||
components: | ||
- tools | ||
- platform-tools | ||
- build-tools-25.0.2 | ||
- android-25 | ||
- extra-android-m2repository | ||
compiler: | ||
- gcc | ||
before_install: | ||
- git clone https://github.com/urho3d/android-ndk.git $HOME/android-ndk-root | ||
- export ANDROID_NDK_HOME=$HOME/android-ndk-root | ||
# Setup environment for Linux build which is required to build the sample. | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get update -qq; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install -qq g++-$GCC_VERSION; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install -qq gcc-$GCC_VERSION; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo ln -s -v -f $(which g++-$GCC_VERSION) /usr/bin/g++; fi | ||
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo ln -s -v -f $(which gcc-$GCC_VERSION) /usr/bin/gcc; fi | ||
script: | ||
- for build_gradle in $(git ls-files | grep build.gradle); do ( cd "$(dirname "${build_gradle}")" && ./gradlew build ); done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# ------------------- Debianization --------------------- | ||
if (UNIX) | ||
|
||
# Set build environment | ||
SET(CPACK_GENERATOR "TGZ;DEB") | ||
SET(CPACK_SOURCE_TGZ "ON") | ||
|
||
# Common package information | ||
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY | ||
"FlatBuffers is an efficient cross platform serialization library for C++, with support for Java, C# and Go. It was created at Google specifically for game development and other performance-critical applications.") | ||
SET(CPACK_DEBIAN_PACKAGE_HOMEPAGE "https://github.com/google/flatbuffers") | ||
SET(CPACK_DEBIAN_PACKAGE_MAINTAINER "Vitaly Isaev <vitalyisaev2@gmail.com>") | ||
|
||
# Derive package version from git | ||
EXECUTE_PROCESS( | ||
COMMAND date +%Y%m%d | ||
OUTPUT_VARIABLE DATE | ||
OUTPUT_STRIP_TRAILING_WHITESPACE | ||
) | ||
EXECUTE_PROCESS( | ||
COMMAND git describe | ||
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} | ||
OUTPUT_VARIABLE GIT_DESCRIBE_DIRTY | ||
OUTPUT_STRIP_TRAILING_WHITESPACE | ||
) | ||
string(REGEX REPLACE "^v([0-9]+)\\..*" "\\1" VERSION_MAJOR "${GIT_DESCRIBE_DIRTY}") | ||
string(REGEX REPLACE "^v[0-9]+\\.([0-9]+).*" "\\1" VERSION_MINOR "${GIT_DESCRIBE_DIRTY}") | ||
string(REGEX REPLACE "^v[0-9]+\\.[0-9]+\\.([0-9]+).*" "\\1" VERSION_PATCH "${GIT_DESCRIBE_DIRTY}") | ||
string(REGEX REPLACE "^v[0-9]+\\.[0-9]+\\.[0-9]+\\-([0-9]+).*" "\\1" VERSION_COMMIT "${GIT_DESCRIBE_DIRTY}") | ||
SET(CPACK_PACKAGE_VERSION_MAJOR ${VERSION_MAJOR}) | ||
SET(CPACK_PACKAGE_VERSION_MINOR ${VERSION_MINOR}) | ||
SET(CPACK_PACKAGE_VERSION_PATCH ${VERSION_PATCH}) | ||
SET(CPACK_PACKAGE_VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}-${VERSION_COMMIT}") | ||
SET(CPACK_DEBIAN_PACKAGE_VERSION "${CPACK_PACKAGE_VERSION}") | ||
|
||
# Derive architecture | ||
IF(NOT CPACK_DEBIAN_PACKAGE_ARCHITECTURE) | ||
FIND_PROGRAM(DPKG_CMD dpkg) | ||
IF(NOT DPKG_CMD) | ||
MESSAGE(STATUS "Can not find dpkg in your path, default to i386.") | ||
SET(CPACK_DEBIAN_PACKAGE_ARCHITECTURE i386) | ||
ENDIF(NOT DPKG_CMD) | ||
EXECUTE_PROCESS(COMMAND "${DPKG_CMD}" --print-architecture | ||
OUTPUT_VARIABLE CPACK_DEBIAN_PACKAGE_ARCHITECTURE | ||
OUTPUT_STRIP_TRAILING_WHITESPACE | ||
) | ||
ENDIF(NOT CPACK_DEBIAN_PACKAGE_ARCHITECTURE) | ||
|
||
# Package name | ||
SET(CPACK_DEBIAN_PACKAGE_NAME "flatbuffers") | ||
SET(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_SOURCE_DIR}/LICENSE.txt) | ||
SET(CPACK_PACKAGE_FILE_NAME | ||
"${CPACK_DEBIAN_PACKAGE_NAME}_${CPACK_DEBIAN_PACKAGE_VERSION}_${CPACK_DEBIAN_PACKAGE_ARCHITECTURE}") | ||
|
||
endif(UNIX) | ||
|
||
INCLUDE(CPack) |
Oops, something went wrong.