Skip to content

Commit

Permalink
Further CI adjustments
Browse files Browse the repository at this point in the history
  • Loading branch information
nberth committed Aug 23, 2024
1 parent 77e5627 commit 5b90cd0
Show file tree
Hide file tree
Showing 5 changed files with 42 additions and 54 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ on:
pull_request:
branches: [ gcos4gnucobol-3.x ]
push:
branches: [ gcos4gnucobol-3.x ]
# manual run in actions tab - for all branches
workflow_dispatch:

Expand All @@ -14,7 +13,8 @@ jobs:
fail-fast: false
matrix:
os:
- macos-latest
# - macos-latest-large # macos 14, amd64
- macos-latest # macos 14, arm64

runs-on: ${{ matrix.os }}

Expand All @@ -41,9 +41,7 @@ jobs:
- name: bootstrap
run: |
./autogen.sh
autoconf
autoreconf --install --force
./build_aux/bootstrap install
- name: Build environment setup
run: |
Expand Down
27 changes: 11 additions & 16 deletions .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ on:
pull_request:
branches: [ gcos4gnucobol-3.x ]
push:
branches: [ gcos4gnucobol-3.x ]
# manual run in actions tab - for all branches
workflow_dispatch:

Expand All @@ -30,7 +29,8 @@ jobs:
- name: Install packages
run: |
sudo apt-get update
sudo apt-get install automake libtool libdb5.3-dev libxml2-dev libcjson-dev bison flex help2man gettext texlive
sudo apt-get install automake libtool libdb5.3-dev libxml2-dev libcjson-dev \
bison flex help2man gettext texlive
- name: Set git user
run: |
Expand Down Expand Up @@ -68,7 +68,8 @@ jobs:
../configure --enable-cobc-internal-checks \
--enable-hardening \
--prefix ${INSTALL_PATH}
echo "VERSION=PACKAGE_VERSION" | cpp -P -imacros config.h | tr -d \" >> $GITHUB_ENV
echo "VERSION=PACKAGE_VERSION" | cpp -P -imacros config.h | tr -d \" \
>> $GITHUB_ENV
- name: Upload config.log
uses: actions/upload-artifact@v4
Expand All @@ -81,17 +82,14 @@ jobs:
run: |
make -C _build --jobs=$(($(nproc)+1))
# - name: check
# run: |
# cd _build
# make check TESTSUITEFLAGS="--jobs=$(($(nproc)+1))"

# note: distcheck also creates the dist tarball
- name: distcheck
run: |
make -C _build distcheck \
TESTSUITEFLAGS="--jobs=$(($(nproc)+1))" \
--jobs=$(($(nproc)+1))
make -C _build distcheck \
TESTSUITEFLAGS="--jobs=$(($(nproc)+1))" \
--jobs=$(($(nproc)+1)) || \
make -C _build/gnucobol-$VERSION/_build/sub/tests check \
TESTSUITEFLAGS="--recheck --verbose"
- name: Upload testsuite.log
uses: actions/upload-artifact@v4
Expand Down Expand Up @@ -136,10 +134,6 @@ jobs:
_build/tests/cobol85/**/*.log
_build/tests/cobol85/**/*.out
- name: install
run: |
make -C _build install
coverage:
name: Coverage and Warnings
Expand Down Expand Up @@ -169,7 +163,8 @@ jobs:
run: |
cd _build
../configure --enable-code-coverage \
CPPFLAGS="-Werror=declaration-after-statement"
CPPFLAGS="-Werror=declaration-after-statement -pedantic" \
CC="gcc -std=c89"
- uses: actions/upload-artifact@v4
if: failure()
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/windows-msvc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ on:
pull_request:
branches: [ gcos4gnucobol-3.x ]
push:
branches: [ gcos4gnucobol-3.x ]
# manual run in actions tab - for all branches
workflow_dispatch:

Expand Down
1 change: 0 additions & 1 deletion .github/workflows/windows-msys1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ on:
pull_request:
branches: [ gcos4gnucobol-3.x ]
push:
branches: [ gcos4gnucobol-3.x ]
# manual run in actions tab - for all branches
workflow_dispatch:

Expand Down
59 changes: 28 additions & 31 deletions .github/workflows/windows-msys2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ on:
pull_request:
branches: [ gcos4gnucobol-3.x ]
push:
branches: [ gcos4gnucobol-3.x ]
# manual run in actions tab - for all branches
workflow_dispatch:

Expand All @@ -15,13 +14,15 @@ jobs:
matrix:
os:
- windows-latest
arch:
- x64
target:
- debug
- release

runs-on: ${{ matrix.os }}
include:
- { sys: mingw64, env: x86_64 }
# - { sys: mingw32, env: i686 }
- { sys: ucrt64, env: ucrt-x86_64 }
- { sys: clang64, env: clang-x86_64 }
runs-on: ${{matrix.os}}

steps:

Expand All @@ -44,19 +45,24 @@ jobs:
echo CFGOPT="--enable-debug --enable-cobc-internal-checks --enable-hardening" >> $env:GITHUB_ENV
}
- name: Install MSYS2 packages
- name: Install packages
uses: msys2/setup-msys2@v2
with:
update: true
msystem: ucrt64
install: autoconf automake libtool make mingw-w64-ucrt-x86_64-ncurses mingw-w64-ucrt-x86_64-libxml2 mingw-w64-ucrt-x86_64-cjson mingw-w64-ucrt-x86_64-db mingw-w64-ucrt-x86_64-gmp libdb-devel mingw-w64-ucrt-x86_64-gcc flex bison gmp-devel help2man texinfo gettext-devel
msystem: ${{matrix.sys}}
install: autoconf automake libtool make flex bison help2man texinfo
mingw-w64-${{matrix.env}}-cc
mingw-w64-${{matrix.env}}-gmp gmp-devel
mingw-w64-${{matrix.env}}-gettext-runtime gettext-devel
mingw-w64-${{matrix.env}}-ncurses
mingw-w64-${{matrix.env}}-libxml2
mingw-w64-${{matrix.env}}-cjson
mingw-w64-${{matrix.env}}-db libdb-devel

- name: Bootstrap GnuCOBOL
shell: msys2 {0}
run: |
./autogen.sh
autoconf
autoreconf --install --force
./build_aux/bootstrap install
- name: Configure GnuCOBOL
shell: msys2 {0}
Expand All @@ -65,11 +71,11 @@ jobs:
cd _build
../configure $CFGOPT --with-db --prefix=/opt/cobol/gnucobol
- name: Upload config-${{ matrix.target }}.log
- name: Upload config-${{matrix.sys}}-${{matrix.target}}.log
uses: actions/upload-artifact@v4
if: failure()
with:
name: config-${{ matrix.target }}.log
name: config-${{matrix.sys}}-${{matrix.target}}.log
path: ${{ env.GITHUB_WORKSPACE }}/_build/config.log

- name: Build GnuCOBOL
Expand All @@ -83,34 +89,25 @@ jobs:
sed '/AT_SETUP(\[temporary path invalid\])/a \
AT_SKIP_IF(\[true\])' \
-i tests/testsuite.src/used_binaries.at
make -C _build/tests check TESTSUITEFLAGS="--jobs=$(($(nproc)+1))"
make -C _build/tests test
make -C _build/tests checkall \
--jobs=$(($(nproc)+1)) \
TESTSUITEFLAGS="--jobs=$(($(nproc)+1))" || \
make -C _build/tests check \
TESTSUITEFLAGS="--recheck --verbose"
- name: Upload testsuite-${{ matrix.target }}.log
- name: Upload testsuite-${{matrix.sys}}-${{matrix.target}}.log
uses: actions/upload-artifact@v4
with:
name: testsuite-${{ matrix.target }}.log
name: testsuite-${{matrix.sys}}-${{matrix.target}}.log
path: ${{ env.GITHUB_WORKSPACE }}/_build/tests/testsuite.log

- name: Install GnuCOBOL
shell: msys2 {0}
run: |
make -C _build install
find /opt/cobol > _build/install.log
- name: Upload install-${{ matrix.target }}.log
uses: actions/upload-artifact@v4
with:
name: install-${{ matrix.target }}.log
path: ${{ env.GITHUB_WORKSPACE }}/_build/install.log

- name: Package GnuCOBOL
shell: msys2 {0}
run: |
make -C _build distmingw
- name: Upload GnuCOBOL_mingw-${{ matrix.target }}
- name: Upload GnuCOBOL_mingw-${{matrix.sys}}-${{matrix.target}}
uses: actions/upload-artifact@v4
with:
name: GnuCOBOL_mingw-${{ matrix.target }}
name: GnuCOBOL_mingw-${{matrix.sys}}-${{matrix.target}}
path: ${{ env.GITHUB_WORKSPACE }}/_build/${{ env.DISTDIR }}

0 comments on commit 5b90cd0

Please sign in to comment.