Skip to content

17 fix cygwin action workflow warning #41

17 fix cygwin action workflow warning

17 fix cygwin action workflow warning #41

Workflow file for this run

name: CMake
on:
push: # Keep empty to run on each branch when push the code. Otherwise use branches: [ master ]
branches: [ main ]
pull_request: # Set to master to run only when merge with master branch
branches: [ main ]
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
CYGWIN: winsymlinks:native
# The CMake configure and build commands are platform agnostic and should work equally well on Windows or Linux.
# You can convert this to a matrix build if you need cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
jobs:
linux-build:
name: Build with GNU and LLVM compilers on Linux
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: actions/[email protected]
with:
java-version: 17
java-package: jre
distribution: temurin
- name: Update Linux
# Update compilers, set C/C++ compilers
run: sudo apt-get update
- name: Configure and run areg-sdk-demo on Linux with GNU family
working-directory: ${{github.workspace}}
run: |
cmake -B ./linux-gnu/cache -DINTEGRATE_AREG_BEFORE_PROJECT=TRUE -DAREG_BUILD_ROOT"./linux-gnu" -DAREG_COMPILER_FAMILY=gnu -DAREG_BINARY=share -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./linux-gnu -j 20
- name: Configure and run areg-sdk-demo on Linux with g++ compiler
working-directory: ${{github.workspace}}
run: |
cmake -B ./linux-g++/cache -DINTEGRATE_AREG_BEFORE_PROJECT=TRUE -DAREG_BUILD_ROOT"./linux-g++" -DAREG_COMPILER=g++ -DAREG_BINARY=share -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./linux-g++/cache -j 20
- name: Configure and run areg-sdk-demo on Linux with gcc compiler
working-directory: ${{github.workspace}}
run: |
cmake -B ./linux-gcc/cache -DINTEGRATE_AREG_BEFORE_PROJECT=FALSE -DAREG_BUILD_ROOT"./linux-gcc" -DAREG_COMPILER=gcc -DAREG_BINARY=static -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./linux-gcc/cache -j 20
- name: Configure and run areg-sdk-demo on Linux with LLVM family
working-directory: ${{github.workspace}}
run: |
cmake -B ./linux-llvm/cache -DINTEGRATE_AREG_BEFORE_PROJECT=TRUE -DAREG_BUILD_ROOT"./linux-llvm" -DAREG_COMPILER_FAMILY=llvm -DAREG_BINARY=share -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./linux-llvm/cache -j 20
- name: Configure and run areg-sdk-demo on Linux with clang++ compiler
working-directory: ${{github.workspace}}
run: |
cmake -B ./linux-clang++/cache -DINTEGRATE_AREG_BEFORE_PROJECT=TRUE -DAREG_BUILD_ROOT"./linux-clang++" -DAREG_COMPILER=clang++ -DAREG_BINARY=share -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./linux-clang++/cache -j 20
- name: Configure and run areg-sdk-demo on Linux with clang compiler
working-directory: ${{github.workspace}}
run: |
cmake -B ./linux-clang/cache -DINTEGRATE_AREG_BEFORE_PROJECT=FALSE -DAREG_BUILD_ROOT"./linux-clang" -DAREG_COMPILER=clang -DAREG_BINARY=static -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./linux-clang/cache -j 20
windows-build:
name: Build with MSVC compilers on Windows
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: actions/[email protected]
with:
java-version: 17
java-package: jre
distribution: temurin
- name: Configure and run areg-sdk-demo on Windows with MSVC family
working-directory: ${{github.workspace}}
run: |
cmake -B ./windows-msvc/cache -DINTEGRATE_AREG_BEFORE_PROJECT=TRUE -DAREG_BUILD_ROOT"./windows-msvc" -DAREG_COMPILER_FAMILY=msvc -DAREG_BINARY=share -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./windows-msvc/cache -j 20
- name: Configure and run areg-sdk-demo on Windows with CL compiler
working-directory: ${{github.workspace}}
run: |
cmake -B ./windows-cl/cache -DINTEGRATE_AREG_BEFORE_PROJECT=FALSE -DAREG_BUILD_ROOT"./windows-cl" -DAREG_COMPILER=cl -DAREG_BINARY=static -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./windows-cl/cache -j 20
cygwin-build:
name: Build with GNU compilers on Cygwin
runs-on: windows-latest
env:
CYGWIN: winsymlinks:native
steps:
- run: git config --global core.autocrlf input
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: actions/[email protected]
with:
java-version: 17
java-package: jre
distribution: temurin
- uses: cygwin/cygwin-install-action@master
with:
packages: cmake, dos2unix, flexdll, gcc-g++, git, ncurses, libncurses-devel, make
- name: Update Cygwin
shell: powershell
run: |
# (https://github.com/cygwin/cygwin-install-action/blob/master/action.yml)
Invoke-WebRequest https://cygwin.com/setup-x86_64.exe -OutFile C:\setup.exe
# because setup is a Windows GUI app, make it part of a pipeline to make
# PowerShell wait for it to exit
& C:\setup.exe -qgnO -t | Out-Default
- name: Configure and run areg-sdk-demo on Cygwin with GNU family
working-directory: ${{github.workspace}}
shell: C:\cygwin\bin\bash.exe --noprofile --norc -o igncr -eo pipefail '{0}'
run: |
cmake -B ./cygwin-gnu/cache -DINTEGRATE_AREG_BEFORE_PROJECT=TRUE -DAREG_BUILD_ROOT="./cygwin-gnu" -DAREG_COMPILER_FAMILY=cygwin -DAREG_BINARY=share -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./cygwin-gnu/cache -j 20
- name: Configure and run areg-sdk-demo on cygwin with g++ compiler
shell: C:\cygwin\bin\bash.exe --noprofile --norc -o igncr -eo pipefail '{0}'
working-directory: ${{github.workspace}}
run: |
cmake -B ./cygwin-g++/cache -DINTEGRATE_AREG_BEFORE_PROJECT=TRUE -DAREG_BUILD_ROOT"./cygwin-g++" -DAREG_COMPILER=g++ -DAREG_BINARY=share -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./cygwin-g++/cache -j 20
- name: Configure and run areg-sdk-demo on Cygwin with gcc compiler
shell: C:\cygwin\bin\bash.exe --noprofile --norc -o igncr -eo pipefail '{0}'
working-directory: ${{github.workspace}}
run: |
cmake -B ./cygwin-gcc/cache -DINTEGRATE_AREG_BEFORE_PROJECT=FALSE -DAREG_BUILD_ROOT"./cygwin-gcc" -DAREG_COMPILER=gcc -DAREG_BINARY=static -DAREG_BUILD_TYPE=${{env.BUILD_TYPE}}
cmake --build ./cygwin-gcc/cache -j 20