Skip to content

Commit

Permalink
Adding Electron 32 support, removing 23, 24, 25 windows pre-builts
Browse files Browse the repository at this point in the history
  • Loading branch information
agracio committed Sep 26, 2024
1 parent c0aff22 commit a8aba9e
Show file tree
Hide file tree
Showing 22 changed files with 8 additions and 44 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ jobs:
strategy:
fail-fast: false
matrix:
# os: [macos-13, macos-14, ubuntu-22.04, windows-2022]
os: [ macos-14, ubuntu-22.04]
electron: [32.1.2]
# electron: [29.4.6, 30.5.1, 31.6.0, 32.1.2]
os: [macos-13, macos-14, ubuntu-22.04, windows-2022]
# os: [ macos-14, ubuntu-22.04]
# electron: [32.1.2]
electron: [29.4.6, 30.5.1, 31.6.0, 32.1.2]
# electron: [31.6.0, 32.1.0]

name: test-${{ matrix.os }}-v${{ matrix.electron }}
Expand Down
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,13 @@

| Electron | Node.Js | x86/x64 | arm64 |
| --------------- | ---------------- | ------------------ | ------------------ |
| Electron 23.x | v18.12.1 | :heavy_check_mark: | :x: |
| Electron 24.x | v18.14.0 | :heavy_check_mark: | :x: |
| Electron 25.x | v18.15.0 | :heavy_check_mark: | :x: |
| Electron 26.x | v18.16.1 | :heavy_check_mark: | :x: |
| Electron 27.x | v18.17.1 | :heavy_check_mark: | :x: |
| Electron 28.x | v18.18.2 | :heavy_check_mark: | :x: |
| Electron 29.x | v20.9.0 | :heavy_check_mark: | :heavy_check_mark: |
| Electron 30.x | v20.x | :heavy_check_mark: | :heavy_check_mark: |
| Electron 31.x | v20.x | :heavy_check_mark: | :heavy_check_mark: |
| Electron 32.x | v20.x | :heavy_check_mark: | :heavy_check_mark: |

- You do not need to use the same version of Node.js in your project as Electron Node.js version
- On Linux and macOS `npm install` will compile binaries with correct Node.Js headers for a given Electron version.
Expand Down
Binary file added lib/native/win32/arm64/32.0.0/edge_coreclr.node
Binary file not shown.
Binary file not shown.
Binary file removed lib/native/win32/ia32/23.0.0/edge_coreclr.node
Binary file not shown.
Binary file removed lib/native/win32/ia32/23.0.0/edge_nativeclr.node
Binary file not shown.
Binary file removed lib/native/win32/ia32/24.0.0/edge_coreclr.node
Binary file not shown.
Binary file removed lib/native/win32/ia32/24.0.0/edge_nativeclr.node
Binary file not shown.
Binary file removed lib/native/win32/ia32/25.0.0/edge_coreclr.node
Binary file not shown.
Binary file removed lib/native/win32/ia32/25.0.0/edge_nativeclr.node
Binary file not shown.
Binary file added lib/native/win32/ia32/32.0.0/edge_coreclr.node
Binary file not shown.
Binary file added lib/native/win32/ia32/32.0.0/edge_nativeclr.node
Binary file not shown.
Binary file removed lib/native/win32/x64/23.0.0/edge_coreclr.node
Binary file not shown.
Binary file removed lib/native/win32/x64/23.0.0/edge_nativeclr.node
Binary file not shown.
Binary file removed lib/native/win32/x64/24.0.0/edge_coreclr.node
Binary file not shown.
Binary file removed lib/native/win32/x64/24.0.0/edge_nativeclr.node
Binary file not shown.
Binary file removed lib/native/win32/x64/25.0.0/edge_coreclr.node
Binary file not shown.
Binary file removed lib/native/win32/x64/25.0.0/edge_nativeclr.node
Binary file not shown.
Binary file added lib/native/win32/x64/32.0.0/edge_coreclr.node
Binary file not shown.
Binary file added lib/native/win32/x64/32.0.0/edge_nativeclr.node
Binary file not shown.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"url": "http://tomasz.janczuk.org",
"twitter": "tjanczuk"
},
"version": "31.3.1",
"version": "32.0.0",
"description": "Edge.js: run .NET and Node.js in-process on Electron",
"tags": [
"owin",
Expand Down
38 changes: 2 additions & 36 deletions tools/install.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,24 +117,6 @@ else {
return null;
}

function replaceCppRuntime(){
var files = ['build/build_managed.vcxproj','build/edge_coreclr.vcxproj', 'build/edge_nativeclr.vcxproj'];

files.map(file => {
const res = spawn('sed', ['-i', '-e', 's/std:c++17/std:c++20/g', file], { stdio: 'inherit' });

return new Promise((resolve, reject) => {
res.on("close", code => {
if (code === 0) {
resolve(code)
} else {
reject(code)
}
});
});
});
}

location = locateElectronPrebuilt();
version = null;
electronPath = null;
Expand All @@ -154,25 +136,9 @@ else {
}
if (version !== null)
{
const configure = spawn('node-gyp', ['configure', '--target='+version, '--runtime=electron', '--disturl=https://electronjs.org/headers', '--release'], { stdio: 'inherit' });

if(version.startsWith('32')){
configure.on('close', (code) => {
// spawn('ls', ['-R', 'build'], { stdio: 'inherit' });
spawn('node-gyp', ['build'], { stdio: 'inherit' });

// Promise.all(replaceCppRuntime()).then((code) => {
// spawn('node-gyp', ['build'], { stdio: 'inherit' });
// });
});
}else{
configure.on('close', (code) => {
spawn('node-gyp', ['build'], { stdio: 'inherit' });
});
}
spawn('node-gyp', ['configure', 'build', '--target='+version, '--runtime=electron', '--disturl=https://electronjs.org/headers', '--release'], { stdio: 'inherit' });
}
else{
else
spawn('node-gyp', ['configure', 'build'], { stdio: 'inherit' });
}

}

0 comments on commit a8aba9e

Please sign in to comment.