|
53 | 53 | submodules: recursive |
54 | 54 | fetch-depth: 0 |
55 | 55 | - run: git config --system --add safe.directory '*' |
56 | | - - run: c4core-install ${{matrix.cxx}} |
| 56 | + - run: | |
| 57 | + # retry if it fails |
| 58 | + c4core-install ${{matrix.cxx}} \ |
| 59 | + || c4core-install ${{matrix.cxx}} \ |
| 60 | + || c4core-install ${{matrix.cxx}} |
57 | 61 | - name: show info |
58 | 62 | run: source .github/setenv.sh && c4_show_info |
59 | 63 | - name: shared64-configure--------------------------------------------------- |
@@ -124,7 +128,11 @@ jobs: |
124 | 128 | submodules: recursive |
125 | 129 | fetch-depth: 0 |
126 | 130 | - run: git config --system --add safe.directory '*' |
127 | | - - run: c4core-install ${{matrix.cxx}} |
| 131 | + - run: | |
| 132 | + # retry if it fails |
| 133 | + c4core-install ${{matrix.cxx}} \ |
| 134 | + || c4core-install ${{matrix.cxx}} \ |
| 135 | + || c4core-install ${{matrix.cxx}} |
128 | 136 | - name: show info |
129 | 137 | run: source .github/setenv.sh && c4_show_info |
130 | 138 | - name: shared64-configure--------------------------------------------------- |
@@ -195,7 +203,11 @@ jobs: |
195 | 203 | submodules: recursive |
196 | 204 | fetch-depth: 0 |
197 | 205 | - run: git config --system --add safe.directory '*' |
198 | | - - run: c4core-install ${{matrix.cxx}} |
| 206 | + - run: | |
| 207 | + # retry if it fails |
| 208 | + c4core-install ${{matrix.cxx}} \ |
| 209 | + || c4core-install ${{matrix.cxx}} \ |
| 210 | + || c4core-install ${{matrix.cxx}} |
199 | 211 | - name: show info |
200 | 212 | run: source .github/setenv.sh && c4_show_info |
201 | 213 | - name: shared64-configure--------------------------------------------------- |
@@ -266,7 +278,11 @@ jobs: |
266 | 278 | submodules: recursive |
267 | 279 | fetch-depth: 0 |
268 | 280 | - run: git config --system --add safe.directory '*' |
269 | | - - run: c4core-install ${{matrix.cxx}} |
| 281 | + - run: | |
| 282 | + # retry if it fails |
| 283 | + c4core-install ${{matrix.cxx}} \ |
| 284 | + || c4core-install ${{matrix.cxx}} \ |
| 285 | + || c4core-install ${{matrix.cxx}} |
270 | 286 | - name: show info |
271 | 287 | run: source .github/setenv.sh && c4_show_info |
272 | 288 | - name: shared64-configure--------------------------------------------------- |
@@ -579,7 +595,16 @@ jobs: |
579 | 595 | -DRYML_DBG=OFF |
580 | 596 | - name: 'build Debug ::: -m${{matrix.bits}}' |
581 | 597 | run: | |
582 | | - cmake --build build/Debug --target ryml-test-build --parallel --verbose |
| 598 | + numprocs=`_c4getnumcores` |
| 599 | + if [ -n "0"] ; then |
| 600 | + if [ "0" == "1" ] ; then |
| 601 | + if (( $numprocs > 1 )) ; then |
| 602 | + numprocs=$(($numprocs / 2)) |
| 603 | + fi |
| 604 | + fi |
| 605 | + fi |
| 606 | + export CMAKE_BUILD_PARALLEL_LEVEL=$numprocs |
| 607 | + cmake --build build/Debug --target ryml-test-build --parallel $numprocs --verbose |
583 | 608 | - name: 'run Debug ::: -m${{matrix.bits}}' |
584 | 609 | run: | |
585 | 610 | source .github/setenv.sh |
@@ -607,7 +632,16 @@ jobs: |
607 | 632 | -DRYML_DBG=OFF |
608 | 633 | - name: 'build Release ::: -O1 -DNDEBUG -m${{matrix.bits}}' |
609 | 634 | run: | |
610 | | - cmake --build build/Release --target ryml-test-build --parallel --verbose |
| 635 | + numprocs=`_c4getnumcores` |
| 636 | + if [ -n "0"] ; then |
| 637 | + if [ "0" == "1" ] ; then |
| 638 | + if (( $numprocs > 1 )) ; then |
| 639 | + numprocs=$(($numprocs / 2)) |
| 640 | + fi |
| 641 | + fi |
| 642 | + fi |
| 643 | + export CMAKE_BUILD_PARALLEL_LEVEL=$numprocs |
| 644 | + cmake --build build/Release --target ryml-test-build --parallel $numprocs --verbose |
611 | 645 | - name: 'run Release ::: -O1 -DNDEBUG -m${{matrix.bits}}' |
612 | 646 | run: | |
613 | 647 | source .github/setenv.sh |
@@ -635,7 +669,16 @@ jobs: |
635 | 669 | -DRYML_DBG=OFF |
636 | 670 | - name: 'build Release ::: -O2 -DNDEBUG -m${{matrix.bits}}' |
637 | 671 | run: | |
638 | | - cmake --build build/Release --target ryml-test-build --parallel --verbose |
| 672 | + numprocs=`_c4getnumcores` |
| 673 | + if [ -n "0"] ; then |
| 674 | + if [ "0" == "1" ] ; then |
| 675 | + if (( $numprocs > 1 )) ; then |
| 676 | + numprocs=$(($numprocs / 2)) |
| 677 | + fi |
| 678 | + fi |
| 679 | + fi |
| 680 | + export CMAKE_BUILD_PARALLEL_LEVEL=$numprocs |
| 681 | + cmake --build build/Release --target ryml-test-build --parallel $numprocs --verbose |
639 | 682 | - name: 'run Release ::: -O2 -DNDEBUG -m${{matrix.bits}}' |
640 | 683 | run: | |
641 | 684 | source .github/setenv.sh |
@@ -663,7 +706,16 @@ jobs: |
663 | 706 | -DRYML_DBG=OFF |
664 | 707 | - name: 'build Release ::: -O3 -DNDEBUG -m${{matrix.bits}}' |
665 | 708 | run: | |
666 | | - cmake --build build/Release --target ryml-test-build --parallel --verbose |
| 709 | + numprocs=`_c4getnumcores` |
| 710 | + if [ -n "0"] ; then |
| 711 | + if [ "0" == "1" ] ; then |
| 712 | + if (( $numprocs > 1 )) ; then |
| 713 | + numprocs=$(($numprocs / 2)) |
| 714 | + fi |
| 715 | + fi |
| 716 | + fi |
| 717 | + export CMAKE_BUILD_PARALLEL_LEVEL=$numprocs |
| 718 | + cmake --build build/Release --target ryml-test-build --parallel $numprocs --verbose |
667 | 719 | - name: 'run Release ::: -O3 -DNDEBUG -m${{matrix.bits}}' |
668 | 720 | run: | |
669 | 721 | source .github/setenv.sh |
@@ -691,7 +743,16 @@ jobs: |
691 | 743 | -DRYML_DBG=OFF |
692 | 744 | - name: 'build Release ::: -Os -DNDEBUG -m${{matrix.bits}}' |
693 | 745 | run: | |
694 | | - cmake --build build/Release --target ryml-test-build --parallel --verbose |
| 746 | + numprocs=`_c4getnumcores` |
| 747 | + if [ -n "0"] ; then |
| 748 | + if [ "0" == "1" ] ; then |
| 749 | + if (( $numprocs > 1 )) ; then |
| 750 | + numprocs=$(($numprocs / 2)) |
| 751 | + fi |
| 752 | + fi |
| 753 | + fi |
| 754 | + export CMAKE_BUILD_PARALLEL_LEVEL=$numprocs |
| 755 | + cmake --build build/Release --target ryml-test-build --parallel $numprocs --verbose |
695 | 756 | - name: 'run Release ::: -Os -DNDEBUG -m${{matrix.bits}}' |
696 | 757 | run: | |
697 | 758 | source .github/setenv.sh |
@@ -788,7 +849,11 @@ jobs: |
788 | 849 | submodules: recursive |
789 | 850 | fetch-depth: 0 |
790 | 851 | - run: git config --system --add safe.directory '*' |
791 | | - - run: c4core-install ${{matrix.cxx}} |
| 852 | + - run: | |
| 853 | + # retry if it fails |
| 854 | + c4core-install ${{matrix.cxx}} \ |
| 855 | + || c4core-install ${{matrix.cxx}} \ |
| 856 | + || c4core-install ${{matrix.cxx}} |
792 | 857 | - name: show info |
793 | 858 | run: source .github/setenv.sh && c4_show_info |
794 | 859 | - name: shared64-configure--------------------------------------------------- |
|
0 commit comments