Added initial EXEC preprocessor handling logic in pplex and ppparse. #2072
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: MacOS Workflow | |
| on: | |
| pull_request: | |
| branches: [ gitside-gnucobol-3.x ] | |
| push: | |
| # manual run in actions tab - for all branches | |
| workflow_dispatch: | |
| env: | |
| HOMEBREW_ROOT: /opt/homebrew/opt | |
| jobs: | |
| build: | |
| #runs-on: macos-latest-large # amd64 | |
| runs-on: macos-latest # arm64 | |
| timeout-minutes: 15 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| isam: | |
| - db | |
| - vbisam | |
| steps: | |
| - name: Set git user | |
| run: | | |
| git config --global user.name github-actions | |
| git config --global user.email github-actions-bot@users.noreply.github.com | |
| # Why was this necessary ? Works fine without it... | |
| # - name: Configure git | |
| # run: git config --global core.symlinks false | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Setup build environment | |
| run: | | |
| echo "TERM=vt100" >> $GITHUB_ENV | |
| echo "NPROC=`sysctl -n hw.ncpu`" >> $GITHUB_ENV | |
| - name: Install packages | |
| run: | | |
| brew update || brew update # seldomly failing in most cases rerun works | |
| brew install autoconf automake libtool \ | |
| help2man texinfo libiconv \ | |
| berkeley-db@5 json-c || (echo "brew install returned $?") | |
| # system available bison works fine | |
| #brew install bison | |
| #echo "$HOMEBREW_ROOT/bison/bin" >> $GITHUB_PATH | |
| - name: Restore VBISAM cache | |
| if: ${{ matrix.isam == 'vbisam' }} | |
| id: restore-vbisam | |
| uses: actions/cache/restore@v4 | |
| with: | |
| key: cache-vbisam-macos | |
| path: vbisam | |
| - name: Build VBISAM | |
| if: ${{ matrix.isam == 'vbisam' && | |
| steps.restore-vbisam.outputs.cache-hit != 'true' }} | |
| run: | | |
| curl -LO http://inglenet.ca/Products/GnuCOBOL/vbisam-2.2.tar.Z | |
| mkdir vbisam && tar -xvzf vbisam-2.2.tar.Z -C vbisam --strip-components=1 | |
| cd vbisam | |
| ./configure --prefix=/opt/vbisam \ | |
| CFLAGS="-fstack-protector-strong -fstack-clash-protection -ggdb3 -fasynchronous-unwind-tables" \ | |
| LDFLAGS="-fstack-protector-strong -fstack-clash-protection" \ | |
| CPPFLAGS="-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2" | |
| chmod u+x build_aux/install-sh | |
| make --jobs=$(($(nproc)+1)) | |
| - name: Install VBISAM | |
| if: ${{ matrix.isam == 'vbisam' }} | |
| run: | | |
| sudo make -C vbisam install | |
| echo "CPATH=/opt/vbisam/include" >> $GITHUB_ENV | |
| echo "LIBRARY_PATH=/opt/vbisam/lib" >> $GITHUB_ENV | |
| echo "LD_LIBRARY_PATH=/opt/vbisam/lib" >> $GITHUB_ENV | |
| - name: Save VBISAM cache | |
| if: ${{ matrix.isam == 'vbisam' && | |
| steps.restore-vbisam.outputs.cache-hit != 'true' }} | |
| uses: actions/cache/save@v4 | |
| with: | |
| key: cache-vbisam-macos | |
| path: vbisam | |
| - name: Bootstrap GnuCOBOL | |
| run: | | |
| ./build_aux/bootstrap install | |
| gettextize -f | |
| - name: Configure GnuCOBOL | |
| run: | | |
| mkdir _build && cd _build | |
| ../configure --with-${{ matrix.isam }} \ | |
| --enable-cobc-internal-checks \ | |
| --enable-hardening \ | |
| --with-curses=ncurses \ | |
| --with-json=json-c \ | |
| --prefix=/opt/cobol/gnucobol \ | |
| --with-iconv --with-libiconv-prefix="$HOMEBREW_ROOT/libiconv" \ | |
| BDB_CFLAGS="-I$HOMEBREW_ROOT/berkeley-db@5/include" \ | |
| BDB_LIBS="-L$HOMEBREW_ROOT/berkeley-db@5/lib -ldb" | |
| - name: Build GnuCOBOL | |
| run: make -C _build --jobs=$((${NPROC}+1)) | |
| - name: Upload config.log | |
| if: ${{ !cancelled() }} | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: config-${{ matrix.isam }}.log | |
| path: _build/config.log | |
| # make install must be done before make check, otherwise execution of | |
| # generated COBOL files fail for a missing /usr/local/lib/libcob.dylib | |
| - name: Install GnuCOBOL | |
| run: | | |
| sudo make -C _build install | |
| find /opt/cobol > _build/install.log | |
| - name: Upload install.log | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: install-${{ matrix.isam }}.log | |
| path: _build/install.log | |
| - name: Adjust testsuite | |
| run: | | |
| cd tests/testsuite.src | |
| sed -i '' '/AT_SETUP(\[runtime check: write to internal storage (1)\])/a \ | |
| AT_SKIP_IF(\[true\])' run_misc.at | |
| - name: Adjust testsuite for VBISAM | |
| if: ${{ matrix.isam == 'vbisam' }} | |
| run: | | |
| cd tests/testsuite.src | |
| sed -i '' '/AT_SETUP(\[OUTPUT on INDEXED file to missing directory\])/a \ | |
| AT_SKIP_IF(\[true\])' run_file.at | |
| sed -i '' '/AT_SETUP(\[INDEXED file with LOCK MODE EXCLUSIVE\])/a \ | |
| AT_SKIP_IF(\[true\])' run_file.at | |
| sed -i '' '/AT_SETUP(\[INDEXED file with OPEN WITH LOCK\])/a \ | |
| AT_SKIP_IF(\[true\])' run_file.at | |
| sed -i '' '/AT_SETUP(\[INDEXED file with SHARING NO\])/a \ | |
| AT_SKIP_IF(\[true\])' run_file.at | |
| sed -i '' '/AT_SETUP(\[INDEXED file with SHARING READ ONLY\])/a \ | |
| AT_SKIP_IF(\[true\])' run_file.at | |
| sed -i '' '/AT_SETUP(\[INDEXED file with blocked lock\])/a \ | |
| AT_SKIP_IF(\[true\])' run_file.at | |
| sed -i '' '/AT_SETUP(\[EXTFH: operation OP_GETINFO \/ QUERY-FILE\])/a \ | |
| AT_SKIP_IF(\[true\])' run_file.at | |
| sed -i '' '/AT_SETUP(\[EXTFH: changing record address\])/a \ | |
| AT_SKIP_IF(\[true\])' run_file.at | |
| - name: Run testsuite | |
| run: | | |
| make -C _build check TESTSUITEFLAGS="--jobs=$((${NPROC}+1))" || \ | |
| make -C _build check TESTSUITEFLAGS="--recheck --verbose" | |
| - name: Upload testsuite.log | |
| if: ${{ !cancelled() }} | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: testsuite-${{ matrix.isam }}.log | |
| path: _build/tests/testsuite.log | |
| - name: Cache newcob.val | |
| uses: actions/cache@v4 | |
| with: | |
| path: _build/tests/cobol85/newcob.val | |
| key: newcob-val | |
| enableCrossOsArchive: true | |
| - name: Run NIST85 testsuite | |
| run: make -C _build test --jobs=$((${NPROC}+1)) | |
| - name: Upload NIST85 Test Suite results | |
| if: ${{ !cancelled() }} | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: NIST85 results on ${{ matrix.isam }} | |
| path: | | |
| _build/tests/cobol85/summary.* | |
| _build/tests/cobol85/**/*.log | |
| _build/tests/cobol85/**/*.out | |
| _build/tests/cobol85/**/duration.txt |