Hi,
I have an app bundled with Electron 6.1.12, if I zip the app and upload it for notarization the notarization works flawless, but I have a makefile that take that app in order to create a .pkg, when I upload the .pkg for notarization, it fails:
{
"logFormatVersion": 1,
"jobId": "7927bcb8-fed3-4d52-bdad-1fa80ae3e56a",
"status": "Invalid",
"statusSummary": "Archive contains critical validation errors",
"statusCode": 4000,
"archiveFilename": "MyApp-2.1.2.pkg",
"uploadDate": "2020-06-03T12:42:48Z",
"sha256": "993601e0aa1df69cde348533c4db17ccccada8adca82f6989775f512ec08119b",
"ticketContents": null,
"issues": [
{
"severity": "error",
"code": null,
"path": "MyApp-2.1.2.pkg/cl.myapp.myapp.pkg Contents/Payload/Applications/MyApp.app/Contents/MacOS/MyApp",
"message": "The signature of the binary is invalid.",
"docUrl": null,
"architecture": "x86_64"
},
{
"severity": "error",
"code": null,
"path": "MyApp-2.1.2.pkg/cl.myapp.myapp.pkg Contents/Payload/Applications/MyApp.app/Contents/Frameworks/Mantle.framework/Versions/A/Mantle",
"message": "The signature of the binary is invalid.",
"docUrl": null,
"architecture": "x86_64"
}
]
}
I works in Catalina 10.15.4
Xcode 11.5
Build version 11E608c
this is my process
----------------------------
Packaging app for platform darwin x64 using electron v6.1.12
Bundles created:
/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64
> pkgbuild --analyze --root build/MyApp-darwin-x64 build/MyApp-darwin-x64.tmp/Info.plist
pkgbuild: Inferring bundle components from contents of build/MyApp-darwin-x64
pkgbuild: Writing new component property list to build/MyApp-darwin-x64.tmp/Info.plist
> plutil -replace BundleIsRelocatable -bool NO build/MyApp-darwin-x64.tmp/Info.plist
> pkgbuild \
--root build/MyApp-darwin-x64 \
--scripts scripts/pkg-scripts \
--filter "version" \
--filter "LICENSE" \
--filter "LICENSES.chromium.html" \
--identifier cl.myapp.myapp \
--version 2.1.2 \
--install-location /Applications \
--component-plist build/MyApp-darwin-x64.tmp/Info.plist \
build/MyApp-darwin-x64.tmp/cl.myapp.myapp.pkg
pkgbuild: Reading components from build/MyApp-darwin-x64.tmp/Info.plist
pkgbuild: Adding component at MyApp.app/Contents/Frameworks/Electron Framework.framework
pkgbuild: Adding component at MyApp.app/Contents/Frameworks/Mantle.framework
pkgbuild: Adding component at MyApp.app/Contents/Frameworks/MyApp Helper (Plugin).app
pkgbuild: Adding component at MyApp.app/Contents/Frameworks/MyApp Helper (Renderer).app
pkgbuild: Adding component at MyApp.app/Contents/Frameworks/MyApp Helper (GPU).app
pkgbuild: Adding component at MyApp.app/Contents/Frameworks/ReactiveCocoa.framework
pkgbuild: Adding component at MyApp.app/Contents/Frameworks/Squirrel.framework
pkgbuild: Adding component at MyApp.app
pkgbuild: Adding component at MyApp.app/Contents/Frameworks/MyApp Helper.app
pkgbuild: Adding top-level preinstall script
pkgbuild: Adding top-level postinstall script
pkgbuild: Wrote package to build/MyApp-darwin-x64.tmp/cl.myapp.myapp.pkg
> codesign -vvvv --force build/MyApp-darwin-x64/MyApp.app
--prepared:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/MyApp Helper (Renderer).app
--validated:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/MyApp Helper (Renderer).app
--prepared:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/Squirrel.framework/Versions/Current/.
--validated:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/Squirrel.framework/Versions/Current/.
--prepared:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/MyApp Helper.app
--validated:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/MyApp Helper.app
--prepared:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/MyApp Helper (Plugin).app
--validated:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/MyApp Helper (Plugin).app
--prepared:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/MyApp Helper (GPU).app
--validated:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/MyApp Helper (GPU).app
--prepared:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/Electron Framework.framework/Versions/Current/.
--validated:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/Electron Framework.framework/Versions/Current/.
--prepared:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/Mantle.framework/Versions/Current/.
--validated:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/Mantle.framework/Versions/Current/.
--prepared:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/ReactiveCocoa.framework/Versions/Current/.
--validated:/Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app/Contents/Frameworks/ReactiveCocoa.framework/Versions/Current/.
build/MyApp-darwin-x64/MyApp.app: valid on disk
build/MyApp-darwin-x64/MyApp.app: satisfies its Designated Requirement
> productbuild \
--synthesize \
--component build/MyApp-darwin-x64/MyApp.app \
build/MyApp-darwin-x64.tmp/distribution.xml
productbuild: Adding component at /Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64/MyApp.app
productbuild: Inferred install-location of /Users/alex/repo/work/myapprepo/build/MyApp-darwin-x64
productbuild: Wrote synthesized distribution to build/MyApp-darwin-x64.tmp/distribution.xml
> productbuild \
--package-path build/MyApp-darwin-x64.tmp \
--distribution build/MyApp-darwin-x64.tmp/distribution.xml \
dist/MyApp-darwin-x64/MyApp-2.1.2-unsigned.pkg
productbuild: Wrote product to dist/MyApp-darwin-x64/MyApp-2.1.2-unsigned.pkg
> productsign --sign "Developer ID Installer: MyApp Spa" dist/MyApp-darwin-x64/MyApp-2.1.2-unsigned.pkg dist/MyApp-darwin-x64/MyApp-2.1.2.pkg
productsign: using timestamp authority for signature
productsign: signing product with identity "Developer ID Installer: MyApp Spa (82MR2HB5GM)" from keychain /Library/Keychains/System.keychain
productsign: adding certificate "Developer ID Certification Authority"
productsign: adding certificate "Apple Root CA"
productsign: Wrote signed product archive to dist/MyApp-darwin-x64/MyApp-2.1.2.pkg
> ./notarize.sh dist/MyApp-darwin-x64/MyApp-2.1.2.pkg
the last line is my script for notarization
I would appreciate any help or tips.
Thanks