|
19 | 19 | build_type: [Release, Debug] |
20 | 20 | shared_libraries: [ON, OFF] |
21 | 21 | platform: [ x64, x86 ] |
22 | | - |
| 22 | + |
23 | 23 | steps: |
24 | 24 | - uses: actions/checkout@v2 |
25 | 25 |
|
|
28 | 28 | with: |
29 | 29 | arch: ${{matrix.platform}} |
30 | 30 |
|
31 | | - - name: Setup Ninja |
| 31 | + - name: Set up Ninja |
32 | 32 | uses: ashutoshvarma/setup-ninja@master |
33 | 33 | with: |
34 | 34 | version: 1.10.0 |
|
38 | 38 | with: |
39 | 39 | python-version: 3.7 |
40 | 40 |
|
41 | | - - name: Restore conan cache |
| 41 | + - name: Restore Conan cache |
42 | 42 | uses: actions/cache@v2 |
43 | 43 | with: |
44 | 44 | path: ${{github.workspace}}/conanCache |
@@ -68,23 +68,131 @@ jobs: |
68 | 68 | conan install .. --build missing |
69 | 69 | dir .. |
70 | 70 | tree /f ../conanCache |
71 | | - |
| 71 | +
|
72 | 72 | - name: Build |
73 | 73 | run: | |
74 | | - cd build |
75 | | - cmake -GNinja -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -DBUILD_SHARED_LIBS=${{matrix.shared_libraries}} -DEXIV2_ENABLE_NLS=OFF -DEXIV2_ENABLE_PNG=ON -DEXIV2_ENABLE_WEBREADY=ON -DEXIV2_BUILD_UNIT_TESTS=ON -DEXIV2_ENABLE_WIN_UNICODE=OFF -DEXIV2_TEAM_WARNINGS_AS_ERRORS=ON -DEXIV2_ENABLE_BMFF=ON -DCMAKE_INSTALL_PREFIX=install .. |
76 | | - ninja |
| 74 | + cmake -GNinja ` |
| 75 | + -DCMAKE_BUILD_TYPE=${{matrix.build_type}} ` |
| 76 | + -DBUILD_SHARED_LIBS=${{matrix.shared_libraries}} ` |
| 77 | + -DEXIV2_ENABLE_NLS=OFF ` |
| 78 | + -DEXIV2_ENABLE_WIN_UNICODE=OFF ` |
| 79 | + -DEXIV2_ENABLE_WEBREADY=ON ` |
| 80 | + -DEXIV2_ENABLE_BMFF=ON ` |
| 81 | + -DEXIV2_BUILD_UNIT_TESTS=ON ` |
| 82 | + -DEXIV2_TEAM_WARNINGS_AS_ERRORS=ON ` |
| 83 | + -DCMAKE_INSTALL_PREFIX=install ` |
| 84 | + -S . -B build && ` |
| 85 | + cmake --build build |
77 | 86 |
|
78 | 87 | - name: Install |
79 | 88 | run: | |
80 | 89 | cd build |
81 | | - ninja install |
| 90 | + cmake --install . |
82 | 91 | tree /f install |
83 | 92 |
|
84 | 93 | - name: Test |
85 | 94 | if: ${{matrix.platform == 'x64'}} |
86 | | - env: |
87 | | - EXIV2_EXT: .exe |
88 | 95 | run: | |
89 | | - cd build |
90 | | - ctest --output-on-failure |
| 96 | + ctest --test-dir build --output-on-failure |
| 97 | +
|
| 98 | + msys2: |
| 99 | + runs-on: windows-latest |
| 100 | + strategy: |
| 101 | + fail-fast: false |
| 102 | + matrix: |
| 103 | + build_type: [Release, Debug] |
| 104 | + shared_libraries: [ON, OFF] |
| 105 | + sys: [MINGW64] |
| 106 | + name: MSYS2 ${{matrix.sys}} - BuildType:${{matrix.build_type}} - SHARED:${{matrix.shared_libraries}} |
| 107 | + defaults: |
| 108 | + run: |
| 109 | + shell: msys2 {0} |
| 110 | + steps: |
| 111 | + - uses: actions/checkout@v2 |
| 112 | + |
| 113 | + - name: Set up MSYS2 |
| 114 | + uses: msys2/setup-msys2@v2 |
| 115 | + with: |
| 116 | + msystem: ${{matrix.sys}} |
| 117 | + update: true |
| 118 | + install: >- |
| 119 | + base-devel |
| 120 | + pacboy: >- |
| 121 | + toolchain:p |
| 122 | + cmake:p |
| 123 | + ninja:p |
| 124 | + expat:p |
| 125 | + gettext:p |
| 126 | + gtest:p |
| 127 | + libiconv:p |
| 128 | + python-lxml:p |
| 129 | + zlib:p |
| 130 | +
|
| 131 | + - name: Build |
| 132 | + run: | |
| 133 | + cmake -GNinja \ |
| 134 | + -DCMAKE_CXX_FLAGS=-Wno-deprecated \ |
| 135 | + -DCMAKE_BUILD_TYPE=${{matrix.build_type}} \ |
| 136 | + -DBUILD_SHARED_LIBS=${{matrix.shared_libraries}} \ |
| 137 | + -DEXIV2_ENABLE_NLS=ON \ |
| 138 | + -DEXIV2_ENABLE_WIN_UNICODE=ON \ |
| 139 | + -DEXIV2_ENABLE_WEBREADY=ON \ |
| 140 | + -DEXIV2_ENABLE_BMFF=ON \ |
| 141 | + -DEXIV2_BUILD_UNIT_TESTS=ON \ |
| 142 | + -S . -B build && \ |
| 143 | + cmake --build build |
| 144 | +
|
| 145 | + - name: Test |
| 146 | + run: | |
| 147 | + ctest --test-dir build --output-on-failure |
| 148 | +
|
| 149 | + cygwin: |
| 150 | + runs-on: windows-latest |
| 151 | + strategy: |
| 152 | + fail-fast: false |
| 153 | + matrix: |
| 154 | + build_type: [Release] |
| 155 | + shared_libraries: [ON] |
| 156 | + platform: [x64] |
| 157 | + name: Cygwin ${{matrix.platform}} - BuildType:${{matrix.build_type}} - SHARED:${{matrix.shared_libraries}} |
| 158 | + env: |
| 159 | + SHELLOPTS: igncr |
| 160 | + defaults: |
| 161 | + run: |
| 162 | + shell: C:\tools\cygwin\bin\bash.exe -eo pipefail '{0}' |
| 163 | + steps: |
| 164 | + # Make sure we don't check out scripts using Windows CRLF line endings |
| 165 | + - run: git config --global core.autocrlf input |
| 166 | + shell: pwsh |
| 167 | + - uses: actions/checkout@v2 |
| 168 | + |
| 169 | + - name: Set up Cygwin |
| 170 | + uses: egor-tensin/setup-cygwin@v3 |
| 171 | + with: |
| 172 | + platform: ${{matrix.platform}} |
| 173 | + packages: >- |
| 174 | + gcc-g++ |
| 175 | + cmake |
| 176 | + ninja |
| 177 | + libexpat-devel |
| 178 | + libxml2-devel |
| 179 | + libxslt-devel |
| 180 | + python38-lxml |
| 181 | + zlib-devel |
| 182 | + - name: Build |
| 183 | + run: | |
| 184 | + cmake -GNinja \ |
| 185 | + -DCMAKE_CXX_FLAGS=-Wno-deprecated \ |
| 186 | + -DCMAKE_BUILD_TYPE=${{matrix.build_type}} \ |
| 187 | + -DBUILD_SHARED_LIBS=${{matrix.shared_libraries}} \ |
| 188 | + -DEXIV2_ENABLE_NLS=OFF \ |
| 189 | + -DEXIV2_ENABLE_WIN_UNICODE=OFF \ |
| 190 | + -DEXIV2_ENABLE_WEBREADY=ON \ |
| 191 | + -DEXIV2_ENABLE_BMFF=ON \ |
| 192 | + -DEXIV2_BUILD_UNIT_TESTS=OFF \ |
| 193 | + -S . -B build && \ |
| 194 | + cmake --build build |
| 195 | +
|
| 196 | + - name: Test |
| 197 | + run: | |
| 198 | + ctest --test-dir build --output-on-failure |
0 commit comments