Browse Source

mac build: let pyinstaller handle Info.plist

note: newer versions of pyinstaller (4.4+ ?) want to sign the bundle
themselves, in which case modifying the Info.plist file after
pyinstaller returns invalidates the sig.
master
SomberNight 3 years ago
parent
commit
859d43d0b2
No known key found for this signature in database
GPG Key ID: B33B5F232C6271E9
  1. 6
      contrib/osx/make_osx
  2. 7
      contrib/osx/osx.spec

6
contrib/osx/make_osx

@ -219,12 +219,6 @@ VERSION=`git describe --tags --dirty --always`
info "Building binary"
pyinstaller --noconfirm --ascii --clean --name $VERSION contrib/osx/osx.spec || fail "Could not build binary"
info "Adding bitcoin URI types to Info.plist"
plutil -insert 'CFBundleURLTypes' \
-xml '<array><dict> <key>CFBundleURLName</key> <string>bitcoin</string> <key>CFBundleURLSchemes</key> <array><string>bitcoin</string><string>lightning</string></array> </dict></array>' \
-- dist/$PACKAGE.app/Contents/Info.plist \
|| fail "Could not add keys to Info.plist. Make sure the program 'plutil' exists and is installed."
DoCodeSignMaybe "app bundle" "dist/${PACKAGE}.app"
if [ ! -z "$CODESIGN_CERT" ]; then

7
contrib/osx/osx.spec

@ -123,6 +123,11 @@ app = BUNDLE(
bundle_identifier=None,
info_plist={
'NSHighResolutionCapable': 'True',
'NSSupportsAutomaticGraphicsSwitching': 'True'
'NSSupportsAutomaticGraphicsSwitching': 'True',
'CFBundleURLTypes':
[{
'CFBundleURLName': 'bitcoin',
'CFBundleURLSchemes': ['bitcoin', 'lightning', ],
}],
},
)

Loading…
Cancel
Save