|
27 | 27 | cc: "clang" |
28 | 28 | flags: "-Os -fPIE" |
29 | 29 | packager: "apt" |
30 | | - packages: "clang" |
| 30 | + packages: "" |
31 | 31 |
|
32 | 32 | - os: ubuntu-latest |
33 | 33 | cxx: "clang++" |
|
39 | 39 | cc: "clang" |
40 | 40 | flags: "-Os -fPIE" |
41 | 41 | packager: "apt" |
42 | | - packages: "clang" |
| 42 | + packages: "" |
43 | 43 |
|
44 | 44 | - os: ubuntu-latest |
45 | 45 | cxx: "g++" |
|
51 | 51 | cc: "gcc" |
52 | 52 | flags: "-Os -fPIE" |
53 | 53 | packager: "apt" |
54 | | - packages: "gcc" |
| 54 | + packages: "" |
55 | 55 |
|
56 | 56 | - os: ubuntu-latest |
57 | 57 | cxx: "g++" |
|
63 | 63 | cc: "gcc" |
64 | 64 | flags: "-Og -g --coverage -fPIE" |
65 | 65 | packager: "apt" |
66 | | - packages: "gcc lcov" |
| 66 | + packages: "lcov" |
67 | 67 |
|
68 | 68 | - os: macos-latest |
69 | 69 | cxx: "clang++" |
@@ -153,6 +153,11 @@ jobs: |
153 | 153 | path-to-lcov: "./coverage.info" |
154 | 154 | github-token: ${{ secrets.github_token }} |
155 | 155 |
|
| 156 | + - name: Failure display available binaries |
| 157 | + if: ${{ failure() }} |
| 158 | + run: | |
| 159 | + ls -la /usr/bin |
| 160 | +
|
156 | 161 | - name: Failure display selected compiler version |
157 | 162 | if: ${{ failure() }} |
158 | 163 | run: | |
@@ -190,6 +195,153 @@ jobs: |
190 | 195 | run: | |
191 | 196 | DYLD_PRINT_LIBRARIES=1 ${{ github.workspace }}/test/.libs/libbitcoin-database-test |
192 | 197 |
|
| 198 | + verify-install-cmake: |
| 199 | + |
| 200 | + strategy: |
| 201 | + fail-fast: false |
| 202 | + |
| 203 | + matrix: |
| 204 | + include: |
| 205 | + - os: ubuntu-latest |
| 206 | + cxx: "clang++" |
| 207 | + link: "dynamic" |
| 208 | + assert: "debug" |
| 209 | + coverage: "nocov" |
| 210 | + boost: "--build-boost" |
| 211 | + icu: "" |
| 212 | + cc: "clang" |
| 213 | + flags: "-Os -fPIE" |
| 214 | + packager: "apt" |
| 215 | + packages: "" |
| 216 | + |
| 217 | + - os: ubuntu-latest |
| 218 | + cxx: "clang++" |
| 219 | + link: "static" |
| 220 | + assert: "ndebug" |
| 221 | + coverage: "nocov" |
| 222 | + boost: "--build-boost" |
| 223 | + icu: "--build-icu --with-icu" |
| 224 | + cc: "clang" |
| 225 | + flags: "-Os -fPIE" |
| 226 | + packager: "apt" |
| 227 | + packages: "" |
| 228 | + |
| 229 | + - os: ubuntu-latest |
| 230 | + cxx: "g++" |
| 231 | + link: "dynamic" |
| 232 | + assert: "ndebug" |
| 233 | + coverage: "nocov" |
| 234 | + boost: "--build-boost" |
| 235 | + icu: "" |
| 236 | + cc: "gcc" |
| 237 | + flags: "-Os -fPIE" |
| 238 | + packager: "apt" |
| 239 | + packages: "" |
| 240 | + |
| 241 | + - os: macos-latest |
| 242 | + cxx: "clang++" |
| 243 | + link: "dynamic" |
| 244 | + assert: "ndebug" |
| 245 | + coverage: "nocov" |
| 246 | + boost: "--build-boost" |
| 247 | + icu: "--build-icu --with-icu" |
| 248 | + cc: "clang" |
| 249 | + flags: "-Os -fPIE" |
| 250 | + packager: "brew" |
| 251 | + packages: "" |
| 252 | + |
| 253 | + - os: macos-latest |
| 254 | + cxx: "clang++" |
| 255 | + link: "static" |
| 256 | + assert: "ndebug" |
| 257 | + coverage: "nocov" |
| 258 | + boost: "--build-boost" |
| 259 | + icu: "--build-icu --with-icu" |
| 260 | + cc: "clang" |
| 261 | + flags: "-Os -fvisibility=hidden -fPIE" |
| 262 | + packager: "brew" |
| 263 | + packages: "" |
| 264 | + |
| 265 | + runs-on: ${{ matrix.os }} |
| 266 | + |
| 267 | + env: |
| 268 | + CC: '${{ matrix.cc }}' |
| 269 | + CXX: '${{ matrix.cxx }}' |
| 270 | + CFLAGS: '${{ matrix.flags }}' |
| 271 | + CXXFLAGS: '${{ matrix.flags }}' |
| 272 | + CI_REPOSITORY: '${{ github.repository }}' |
| 273 | + |
| 274 | + steps: |
| 275 | + - name: Checkout repository |
| 276 | + uses: actions/checkout@v2 |
| 277 | + |
| 278 | + - name: Prepare toolchain [apt] |
| 279 | + if: ${{ matrix.packager == 'apt' }} |
| 280 | + run: | |
| 281 | + sudo apt-get update |
| 282 | + sudo apt-get install git build-essential autoconf automake libtool pkg-config ${{ matrix.packages }} |
| 283 | +
|
| 284 | + - name: Prepare toolchain [brew] |
| 285 | + if: ${{ matrix.packager == 'brew' }} |
| 286 | + run: | |
| 287 | + brew install autoconf automake libtool pkg-config ${{ matrix.packages }} |
| 288 | +
|
| 289 | + - name: Denormalize parameterization |
| 290 | + run: | |
| 291 | + if [[ ${{ matrix.packager }} == 'brew' ]]; then |
| 292 | + echo "CMAKE_LIBRARY_PATH=/usr/local/lib" >> $GITHUB_ENV |
| 293 | + fi |
| 294 | + if [[ ${{ matrix.assert }} == 'ndebug' ]]; then |
| 295 | + echo "ASSERT_NDEBUG=--enable-ndebug -Denable-ndebug=yes" >> $GITHUB_ENV |
| 296 | + else |
| 297 | + echo "ASSERT_NDEBUG=--disable-ndebug -Denable-ndebug=no" >> $GITHUB_ENV |
| 298 | + fi |
| 299 | + if [[ ${{ matrix.link }} == 'dynamic' ]]; then |
| 300 | + echo "LINKAGE=--disable-static" >> $GITHUB_ENV |
| 301 | + else |
| 302 | + echo "LINKAGE=--disable-shared" >> $GITHUB_ENV |
| 303 | + fi |
| 304 | + if [[ ${{ matrix.link }} == 'dynamic' ]]; then |
| 305 | + echo "LDFLAGS=-Wl,-rpath,${{ github.workspace }}/prefixenv/lib" >> $GITHUB_ENV |
| 306 | + fi |
| 307 | +
|
| 308 | + - name: Execute install-cmake.sh |
| 309 | + run: > |
| 310 | + ./install-cmake.sh |
| 311 | + --build-dir=${{ github.workspace }}/build |
| 312 | + --prefix=${{ github.workspace }}/prefixenv |
| 313 | + ${{ env.LINKAGE }} |
| 314 | + ${{ env.ASSERT_NDEBUG }} |
| 315 | + ${{ matrix.boost }} |
| 316 | + ${{ matrix.icu }} |
| 317 | +
|
| 318 | + - name: Coveralls Calculation |
| 319 | + if: ${{ matrix.coverage == 'cov' }} |
| 320 | + run: | |
| 321 | + lcov --directory . --capture --output-file coverage.info |
| 322 | + lcov --remove coverage.info "/usr/*" "${{ github.workspace }}/prefixenv/*" "${{ github.workspace }}/build/*" "${{ github.workspace }}/examples/*" "${{ github.workspace }}/test/*" --output-file coverage.info |
| 323 | + lcov --list coverage.info |
| 324 | +
|
| 325 | + - name: Coveralls.io Upload |
| 326 | + if: ${{ matrix.coverage == 'cov' }} |
| 327 | + uses: coverallsapp/github-action@master |
| 328 | + with: |
| 329 | + path-to-lcov: "./coverage.info" |
| 330 | + github-token: ${{ secrets.github_token }} |
| 331 | + |
| 332 | + - name: Failure Display cmake test output |
| 333 | + if: ${{failure() }} |
| 334 | + run: | |
| 335 | + gcc -v |
| 336 | + clang -v |
| 337 | + echo "--- ENVIRONMENT ---" |
| 338 | + env |
| 339 | + echo "--- END ENVIRONMENT ---" |
| 340 | + cat ${{ github.workspace }}/Testing/Temporary/LastTest.log |
| 341 | + ls ${{ github.workspace }}/prefixenv/lib/pkgconfig/ |
| 342 | + cat ${{ github.workspace }}/prefixenv/lib/pkgconfig/*.pc |
| 343 | + ls ${{ github.workspace }}/prefixenv/lib/cmake |
| 344 | +
|
193 | 345 | verify-sln: |
194 | 346 | strategy: |
195 | 347 | fail-fast: false |
|
0 commit comments