From 546a5af5b8a04fa5e07e7e14ec54cda4fff39211 Mon Sep 17 00:00:00 2001 From: Lovell Fuller Date: Wed, 17 Apr 2024 14:56:14 +0100 Subject: [PATCH] CI: Add darwin-arm64 to matrix Updates dependencies where possible whilst still maintaining support for Node.js 10. --- .github/workflows/ci.yml | 25 +++++++++++++++---------- package.json | 2 +- 2 files changed, 16 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ce92863..539de48 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,22 +41,26 @@ jobs: container: node:16-alpine3.12 - os: ubuntu-22.04 container: node:18-alpine3.14 - - os: macos-11 + - os: macos-12 nodejs_version: 10 nodejs_arch: x64 prebuild: true - - os: macos-11 + - os: macos-12 nodejs_version: 12 nodejs_arch: x64 - - os: macos-11 + - os: macos-12 nodejs_version: 14 nodejs_arch: x64 - - os: macos-11 + - os: macos-12 nodejs_version: 16 nodejs_arch: x64 - - os: macos-11 + - os: macos-12 nodejs_version: 18 nodejs_arch: x64 + - os: macos-14 + nodejs_version: 18 + nodejs_arch: arm64 + prebuild: true - os: windows-2019 nodejs_version: 10 nodejs_arch: x86 @@ -89,8 +93,6 @@ jobs: - os: windows-2019 nodejs_version: 18 nodejs_arch: x64 - env: - CXXFLAGS: "-march=nehalem" steps: - name: Dependencies (Linux glibc) if: contains(matrix.container, 'centos') @@ -103,22 +105,25 @@ jobs: if: contains(matrix.container, 'rockylinux') run: | curl -sL https://rpm.nodesource.com/setup_${{ matrix.nodejs_version }}.x | bash - - dnf install -y gcc-toolset-11-gcc-c++ make git python3 nodejs fontconfig google-noto-sans-fonts + dnf install -y gcc-toolset-11-gcc-c++ make git python3 nodejs echo "/opt/rh/gcc-toolset-11/root/usr/bin" >> $GITHUB_PATH - name: Dependencies (Linux musl) if: contains(matrix.container, 'alpine') run: apk add build-base git python3 --update-cache - name: Dependencies (Python 3.10 - macOS, Windows) if: contains(matrix.os, 'macos') || contains(matrix.os, 'windows') - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.10' - name: Dependencies (Node.js - macOS, Windows) if: contains(matrix.os, 'macos') || contains(matrix.os, 'windows') - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: ${{ matrix.nodejs_version }} architecture: ${{ matrix.nodejs_arch }} + - name: Add compiler flags + if: matrix.os != 'macos-14' + run: echo "CXXFLAGS=-march=nehalem" >> $GITHUB_ENV - name: Checkout uses: actions/checkout@v3 - name: Install diff --git a/package.json b/package.json index 9c198cf..32e2d22 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,7 @@ ], "dependencies": { "node-addon-api": "^5.1.0", - "prebuild-install": "^7.1.1" + "prebuild-install": "^7.1.2" }, "devDependencies": { "cc": "^3.0.1",