mirror of
https://github.com/liamcottle/reticulum-meshchat.git
synced 2026-12-03 21:30:03 -05:00
Add support for universal Mac build (x64 + arm64)
Changes to package.json: - Enable ASAR packaging (was disabled) - Replace extraFiles with extraResources for Python executables - Old: Resources/app/electron/build/exe - New: Resources/python (outside ASAR, accessible to spawn) - Mac: Add universal build support (x64 + arm64 in single .dmg) - Mac: Add x64ArchFiles rule for Python (cx_Freeze creates universal binaries) - Mac: Add explicit icon configuration - Mac: Update artifact name to include architecture - Remove buildResources directive (conflicted with extraResources) - Remove duplicate extraFiles from win/linux sections (centralized) - Add npm scripts: dist:mac-arm64 and dist:mac-universal Changes to electron/main.js: - Update Python exe path resolution for extraResources location - Check process.resourcesPath/python first (production build) - Fall back to local build/exe for development Changes to .github/workflows/build.yml: - Switch Mac runner from macos-13 (Intel) to macos-14 (Apple Silicon) - Update artifacts pattern from '*-mac.dmg' to '*-mac-*.dmg'
This commit is contained in:
parent
002360399c
commit
1518013225
4 changed files with 69 additions and 111 deletions
66
package.json
66
package.json
|
|
@ -10,7 +10,9 @@
|
|||
"build": "npm run build-frontend && npm run build-backend",
|
||||
"electron-postinstall": "electron-builder install-app-deps",
|
||||
"electron": "npm run electron-postinstall && npm run build && electron .",
|
||||
"dist": "npm run electron-postinstall && npm run build && electron-builder --publish=never"
|
||||
"dist": "npm run electron-postinstall && npm run build && electron-builder --publish=never",
|
||||
"dist:mac-arm64": "npm run electron-postinstall && npm run build && electron-builder --mac --arm64 --publish=never",
|
||||
"dist:mac-universal": "npm run electron-postinstall && npm run build && electron-builder --mac --universal --publish=never"
|
||||
},
|
||||
"license": "MIT",
|
||||
"engines": {
|
||||
|
|
@ -23,30 +25,36 @@
|
|||
"build": {
|
||||
"appId": "com.liamcottle.reticulummeshchat",
|
||||
"productName": "Reticulum MeshChat",
|
||||
"asar": false,
|
||||
"files": [
|
||||
"electron/**/*"
|
||||
"asar": true,
|
||||
"extraResources": [
|
||||
{
|
||||
"from": "build/exe",
|
||||
"to": "python",
|
||||
"filter": ["**/*"]
|
||||
}
|
||||
],
|
||||
"files": [
|
||||
"electron/*.js",
|
||||
"electron/*.html",
|
||||
"electron/assets/**/*",
|
||||
"public/**/*",
|
||||
"package.json"
|
||||
],
|
||||
"directories": {
|
||||
"buildResources": "electron/build"
|
||||
},
|
||||
"mac": {
|
||||
"target": "dmg",
|
||||
"target": {
|
||||
"target": "dmg",
|
||||
"arch": [
|
||||
"universal"
|
||||
]
|
||||
},
|
||||
"identity": null,
|
||||
"artifactName": "ReticulumMeshChat-v${version}-${os}.${ext}",
|
||||
"icon": "electron/build/icon.png",
|
||||
"artifactName": "ReticulumMeshChat-v${version}-${os}-${arch}.${ext}",
|
||||
"x64ArchFiles": "Contents/Resources/python/**/*",
|
||||
"extendInfo": {
|
||||
"NSMicrophoneUsageDescription": "Microphone access is only needed for Audio Calls",
|
||||
"com.apple.security.device.audio-input": true
|
||||
},
|
||||
"extraFiles": [
|
||||
{
|
||||
"from": "build/exe",
|
||||
"to": "Resources/app/electron/build/exe",
|
||||
"filter": [
|
||||
"**/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"win": {
|
||||
"artifactName": "ReticulumMeshChat-v${version}-${os}.${ext}",
|
||||
|
|
@ -57,29 +65,11 @@
|
|||
{
|
||||
"target": "nsis"
|
||||
}
|
||||
],
|
||||
"extraFiles": [
|
||||
{
|
||||
"from": "build/exe",
|
||||
"to": "Resources/app/electron/build/exe",
|
||||
"filter": [
|
||||
"**/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"linux": {
|
||||
"artifactName": "ReticulumMeshChat-v${version}-${os}.${ext}",
|
||||
"target": "AppImage",
|
||||
"extraFiles": [
|
||||
{
|
||||
"from": "build/exe",
|
||||
"to": "resources/app/electron/build/exe",
|
||||
"filter": [
|
||||
"**/*"
|
||||
]
|
||||
}
|
||||
]
|
||||
"target": "AppImage"
|
||||
},
|
||||
"dmg": {
|
||||
"writeUpdateInfo": false
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue