Skip to content
This repository has been archived by the owner on Apr 29, 2022. It is now read-only.

Commit

Permalink
Use universal binaries for macOS (#264)
Browse files Browse the repository at this point in the history
  • Loading branch information
quanglam2807 authored Dec 23, 2020
1 parent 6ebf5fe commit 6ea102f
Show file tree
Hide file tree
Showing 5 changed files with 142 additions and 114 deletions.
8 changes: 4 additions & 4 deletions dist.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@ const appVersion = fs.readJSONSync(path.join(__dirname, 'package.json')).version
let targets;
switch (process.platform) {
case 'darwin': {
targets = Platform.MAC.createTarget([process.env.CI ? 'mas' : 'mas-dev'], Arch.x64, Arch.arm64);
targets = Platform.MAC.createTarget(['mas'], Arch.universal);
// targets = Platform.MAC.createTarget(['mas-dev'], Arch.universal);
break;
}
case 'win32': {
Expand Down Expand Up @@ -108,9 +109,8 @@ const opts = {
},
mas: {
category: 'public.app-category.productivity',
provisioningProfile: targets.has(Platform.MAC) && targets.get(Platform.MAC).get(1).indexOf('mas-dev') > -1
? 'build-resources/embedded-development.provisionprofile'
: 'build-resources/embedded.provisionprofile',
provisioningProfile: 'build-resources/embedded.provisionprofile',
// provisioningProfile: 'build-resources/embedded-development.provisionprofile', # mas-dev
darkModeSupport: true,
},
linux: {
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@
"cross-env": "7.0.3",
"del": "6.0.0",
"dotenv": "8.2.0",
"electron": "11.1.0",
"electron-builder": "22.10.3",
"electron": "11.1.1",
"electron-builder": "22.10.4",
"electron-notarize": "1.0.0",
"eslint": "6.8.0",
"eslint-config-airbnb": "18.2.1",
Expand Down
61 changes: 0 additions & 61 deletions patches/app-builder-lib+22.10.3.patch

This file was deleted.

16 changes: 16 additions & 0 deletions patches/app-builder-lib+22.10.4.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
diff --git a/node_modules/app-builder-lib/out/platformPackager.js b/node_modules/app-builder-lib/out/platformPackager.js
index 675e461..e018994 100644
--- a/node_modules/app-builder-lib/out/platformPackager.js
+++ b/node_modules/app-builder-lib/out/platformPackager.js
@@ -409,9 +409,8 @@ class PlatformPackager {
await framework.beforeCopyExtraFiles({
packager: this,
appOutDir,
- asarIntegrity: asarOptions == null ? null : await (0, _integrity().computeData)(resourcesPath, asarOptions.externalAllowed ? {
- externalAllowed: true
- } : null),
+ // https://github.com/electron-userland/electron-builder/pull/5481#issuecomment-749875793
+ asarIntegrity: null,
platformName
});
}
Loading

0 comments on commit 6ea102f

Please sign in to comment.