macOS build #807
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 build" | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| schedule: | |
| - cron: '0 7 * * 2' | |
| jobs: | |
| build: | |
| runs-on: macos-latest | |
| steps: | |
| - name: Repository checkout | |
| uses: actions/checkout@v3 | |
| - name: Before_install | |
| run: | | |
| uname -a | |
| g++ --version | |
| whoami | |
| pwd | |
| - name: Install dependencies via homebrew | |
| run: | | |
| brew update | |
| brew install ncurses | |
| brew install autoconf-archive | |
| brew install automake | |
| brew install libtool | |
| brew install pkg-config | |
| - name: Test on macOS | |
| run: | | |
| autoreconf -v --install --force | |
| ./configure --prefix=/usr CPPFLAGS=-I/opt/homebrew/opt/ncurses/include | |
| CPU_COUNT="$( ( ( getconf _NPROCESSORS_ONLN 2>/dev/null || (getconf NPROCESSORS_ONLN 2>/dev/null) ) || nprocx 2>/dev/null ) || echo "1")" | |
| JOBS="$(( $((CPU_COUNT / 2)) > 1 ? $((CPU_COUNT / 2)) : 1 ))" | |
| make -j$JOBS | |