-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathappveyor.yml
45 lines (39 loc) · 1.87 KB
/
appveyor.yml
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
41
42
43
44
45
version: '{branch}-{build}'
image:
- Visual Studio 2019
- Ubuntu1804
environment:
global:
CMAKE_BUILD_PARALLEL_LEVEL: 2
matrix:
- BUILD_TYPE: Release
- BUILD_TYPE: Debug
install:
# set version environment variable
- ps: $env:GIT_REPO_VERSION = "$(git describe --tags --always)"
# appveyor workaround: initialize all submodules
- git submodule update --init --recursive
# install multilib compilers
- sh: sudo apt-get -qq update
- sh: sudo apt-get -qq -y install g++-multilib gcc-multilib
- sh: "echo g++ version: $(g++ --version | cut -d$'\n' -f1)"
# set CMake platform arg on MSVC
- ps: |
if ($isWindows) {
$CMAKE_ARGS = "-AWin32", "-Thost=x86"
} else {
$CMAKE_ARGS = "-DCMAKE_CXX_FLAGS=-m32", "-DCMAKE_C_FLAGS=-m32"
}
before_build:
- git clone --quiet https://github.com/jbeder/yaml-cpp.git yaml-cpp
- git -C yaml-cpp checkout tags/yaml-cpp-0.6.3
- ps: cmake -Wno-dev --no-warn-unused-cli -DCMAKE_BUILD_TYPE="$env:BUILD_TYPE" -DCMAKE_INSTALL_PREFIX=yaml-cpp-install -DYAML_CPP_BUILD_CONTRIB=OFF -DYAML_CPP_BUILD_TOOLS=OFF -DYAML_CPP_BUILD_TESTS=OFF -DBUILD_GMOCK=OFF -DYAML_MSVC_SHARED_RT=OFF @CMAKE_ARGS -S yaml-cpp -B yaml-cpp-build
- ps: cmake --build yaml-cpp-build --config $env:BUILD_TYPE --target install
build_script:
- ps: cmake -DCMAKE_BUILD_TYPE="$env:BUILD_TYPE" -Dyaml-cpp_DIR=yaml-cpp-install/share/cmake/yaml-cpp -DLOGCORE_VERSION="$env:GIT_REPO_VERSION" -DLOGCORE_INSTALL_DEV=OFF @CMAKE_ARGS -S . -B build
- ps: cmake --build build --target package --config $env:BUILD_TYPE
- ps: cmake -DCMAKE_BUILD_TYPE="$env:BUILD_TYPE" -Dyaml-cpp_DIR=yaml-cpp-install/share/cmake/yaml-cpp -DLOGCORE_VERSION="$env:GIT_REPO_VERSION" -DLOGCORE_INSTALL_DEV=ON @CMAKE_ARGS -S . -B build
- ps: cmake --build build --target package --config $env:BUILD_TYPE
artifacts:
- path: 'build/*.zip'
- path: 'build/*.tar.gz'