flatbuffers/appveyor.yml

110 lines
3.2 KiB
YAML
Raw Normal View History

branches:
only:
- master
os: Visual Studio 2015
environment:
global:
# Workaround for https://github.com/conda/conda-build/issues/636
PYTHONIOENCODING: UTF-8
CONDA_INSTALL_LOCN: "C:\\Miniconda35-x64"
CMAKE_OPTIONS: ""
CPP_TEST_OPTIONS: ""
matrix:
- CMAKE_VS_VERSION: "10 2010"
CMAKE_OPTIONS: "-DFLATBUFFERS_BUILD_LEGACY=1"
CPP_TEST_OPTIONS: "--std-cpp c++0x"
MONSTER_EXTRA: "skip"
Conan build packages on CI (#4590) (#4594) * Build Conan package on Travis CI (#4590) - Added multi package support on Linux, running on Travis CI - Only upload when branch is a tag and named "vX.Y.Z" - Replace Conan injection by Conan wrapper - Removed os_build os_arch -- Conan 1.0.1 hotfix Signed-off-by: Uilian Ries <uilianries@gmail.com> * Build Conan package on OSX (#4590) - Added jobs to build Flatbuffers on OSX running on Travis Signed-off-by: Uilian Ries <uilianries@gmail.com> * Build Conan package on Windows (#4590) - Added support necessary to build Flatbuffers on Windows (conan) - Added Appveyor jobs to build Conan package - Only build Conan package when release (tag) Signed-off-by: Uilian Ries <uilianries@gmail.com> * Reduce Conan CI support to simple scripts (#4590) - Removed msvc 10 x86_64 workaround - Updated conan remote address - Added Bincrafters' package tools Signed-off-by: Uilian Ries <uilianries@gmail.com> * Add fPIC option on Conan recipe (#4590) - Add fPIC as optional. It works on Linux and OSX - Update recipe metadata: author, homepage, license - Checking for flatc and flathash on Conan package Signed-off-by: Uilian Ries <uilianries@gmail.com> * Build Conan package on CI (#4590) - Add rule to run conan job only for tags - Run Conan on Linux, OSX and Windows - Update package tool to new interface Signed-off-by: Uilian Ries <uilianries@gmail.com> * Update Conan username (#4590) - Use google as default username Signed-off-by: Uilian Ries <uilianries@gmail.com> * Update OSX version on CI (#4590) - Use latest OSX 9.3 version to build Conan package Signed-off-by: Uilian Ries <uilianries@gmail.com>
2018-08-16 19:17:52 +00:00
- CMAKE_VS_VERSION: "12 2013"
MONSTER_EXTRA: "skip"
- CMAKE_VS_VERSION: "14 2015"
MONSTER_EXTRA: ""
platform:
- x86
- x64
configuration:
- Debug
- Release
before_build:
- set MONSTER_EXTRA=%MONSTER_EXTRA%
- cmake . -G"Visual Studio %CMAKE_VS_VERSION%" -DFLATBUFFERS_CODE_SANITIZE=1 %CMAKE_OPTIONS%
# This cuts down on a lot of noise generated by xamarin warnings.
- del "C:\Program Files (x86)\MSBuild\14.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets"
build:
project: ALL_BUILD.vcxproj
verbosity: minimal
Conan build packages on CI (#4590) (#4594) * Build Conan package on Travis CI (#4590) - Added multi package support on Linux, running on Travis CI - Only upload when branch is a tag and named "vX.Y.Z" - Replace Conan injection by Conan wrapper - Removed os_build os_arch -- Conan 1.0.1 hotfix Signed-off-by: Uilian Ries <uilianries@gmail.com> * Build Conan package on OSX (#4590) - Added jobs to build Flatbuffers on OSX running on Travis Signed-off-by: Uilian Ries <uilianries@gmail.com> * Build Conan package on Windows (#4590) - Added support necessary to build Flatbuffers on Windows (conan) - Added Appveyor jobs to build Conan package - Only build Conan package when release (tag) Signed-off-by: Uilian Ries <uilianries@gmail.com> * Reduce Conan CI support to simple scripts (#4590) - Removed msvc 10 x86_64 workaround - Updated conan remote address - Added Bincrafters' package tools Signed-off-by: Uilian Ries <uilianries@gmail.com> * Add fPIC option on Conan recipe (#4590) - Add fPIC as optional. It works on Linux and OSX - Update recipe metadata: author, homepage, license - Checking for flatc and flathash on Conan package Signed-off-by: Uilian Ries <uilianries@gmail.com> * Build Conan package on CI (#4590) - Add rule to run conan job only for tags - Run Conan on Linux, OSX and Windows - Update package tool to new interface Signed-off-by: Uilian Ries <uilianries@gmail.com> * Update Conan username (#4590) - Use google as default username Signed-off-by: Uilian Ries <uilianries@gmail.com> * Update OSX version on CI (#4590) - Use latest OSX 9.3 version to build Conan package Signed-off-by: Uilian Ries <uilianries@gmail.com>
2018-08-16 19:17:52 +00:00
after_build:
- python conan/appveyor/install.py
- python conan/appveyor/build.py
install:
- set PATH=%CONDA_INSTALL_LOCN%;%CONDA_INSTALL_LOCN%\scripts;%PATH%;
2018-09-12 18:44:51 +00:00
- curl -sSf -o rustup-init.exe https://win.rustup.rs/
- rustup-init.exe -y
- set PATH=%PATH%;C:\Users\appveyor\.cargo\bin
- rustc -V
- cargo -V
test_script:
- call .appveyor\check-generate-code.bat -b %CONFIGURATION%
- "cd tests"
- rem "Building all code"
- generate_code.bat -b %CONFIGURATION% %CPP_TEST_OPTIONS%
- 7z a GeneratedMyGameCode.zip MyGame\
- rem "---------------- C++ -----------------"
- "cd .."
- "%CONFIGURATION%\\flattests.exe"
- "cd tests"
- rem "---------------- Java -----------------"
- "java -version"
- "JavaTest.bat"
2018-09-12 18:44:51 +00:00
- rem "---------------- Rust ----------------"
- "RustTest.bat"
- rem "---------------- JS -----------------"
- "node --version"
- "..\\%CONFIGURATION%\\flatc -b -I include_test monster_test.fbs unicode_test.json"
- "node JavaScriptTest ./monster_test_generated"
- rem "-------------- Python ---------------"
- where python
- python --version
- where pip
- pip --version
- where conda
- conda --version
- rem "installing flatbuffers python library"
- pip install ../python
- rem "testing without installing Numpy"
- python py_test.py 0 0 0
- rem "testing after installing Numpy - disabled"
# FIXME: This has a LOT of unnecessary dependencies and makes the tests fail
# with timeouts.
# - conda install --yes numpy
# - python py_test.py 0 0 0
- rem "---------------- C# -----------------"
# Have to compile this here rather than in "build" above because AppVeyor only
# supports building one project??
- "cd FlatBuffers.Test"
- "msbuild.exe /property:Configuration=Release;OutputPath=tempcs /verbosity:minimal FlatBuffers.Test.csproj"
- "tempcs\\FlatBuffers.Test.exe"
# Run tests with UNSAFE_BYTEBUFFER
- "msbuild.exe /property:Configuration=Release;UnsafeByteBuffer=true;OutputPath=tempcsUnsafe /verbosity:minimal FlatBuffers.Test.csproj"
- "tempcsUnsafe\\FlatBuffers.Test.exe"
# TODO: add more languages.
- "cd ..\\.."
artifacts:
- path: $(CONFIGURATION)\flatc.exe
name: flatc.exe
- path: tests\GeneratedMyGameCode.zip
name: GeneratedMyGameCode.zip