Skip to content

Commit

Permalink
testing macOS build
Browse files Browse the repository at this point in the history
  • Loading branch information
agracio committed Mar 6, 2025
1 parent 43853ae commit 558db44
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 8 deletions.
11 changes: 6 additions & 5 deletions .github/actions/setup-env/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@ runs:
# path: ~/Library/Caches/node-gyp
# key: '${{ inputs.os }}-${{ inputs.node}}'

- if: runner.os == 'macOS' && inputs.node == 16
shell: bash
name: Add missing packages for macOS NodeJs 16
run: |
pip install setuptools

- name: Cache node modules
id: cache-nodemodules
Expand All @@ -61,6 +56,12 @@ runs:
shell: bash
run: |
node -v && npm -v && dotnet --version && node -p process.platform && node -p process.arch
- if: runner.os == 'macOS' && inputs.node == 16
shell: bash
name: Add missing packages for macOS NodeJs 16
run: |
pip install setuptools
- name: npm install
shell: bash
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,9 @@ jobs:
fail-fast: false
matrix:
# os: [macos-13, macos-14, ubuntu-22.04, ubuntu-22.04-arm, windows-2022]
os: [macos-13, macos-14, macos-15]
os: [macos-13, macos-15]
# node: [18, 20, 22, 23]
node: [16, 20]
node: [16, 18, 20]
steps:

- name: Checkout code
Expand Down
6 changes: 6 additions & 0 deletions lib/edge.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ else if (process.platform === 'win32') {
}
else if(process.platform === 'darwin'){
edgeNative = path.resolve(__dirname, './native/' + process.platform + '/' + process.arch + '/' + nodeVersion + '/' + 'edge_coreclr.node');
if(!fs.existsSync(edgeNative)){
edgeNative = builtEdge;
if(!fs.existsSync(edgeNative)){
throw new Error(`Failed to build edge-js for `);
}
}
}
else {
throw new Error('The edge native module is not available at ' + builtEdge
Expand Down
3 changes: 2 additions & 1 deletion tools/install.js
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ else {
});
}
else{
spawn('node-gyp', ['configure', 'build'], { stdio: 'inherit' });
spawn('node-gyp', ['configure', `--target=${process.version.node}` ,`--runtime=node` `--arch=${process.arch}`], { stdio: 'inherit' });
spawn('node-gyp', ['build'], { stdio: 'inherit' });
}
}
else{
Expand Down

0 comments on commit 558db44

Please sign in to comment.