From 950ae07df50abc723781c79153dcc53987c239aa Mon Sep 17 00:00:00 2001 From: Craig Raw Date: Tue, 14 Apr 2020 09:37:14 +0200 Subject: [PATCH] sign and notarise app for osx --- .gitignore | 3 ++- build.gradle | 6 ++++-- .../associations.properties | 0 .../deploy/package/macosx/Sparrow.entitlements | 16 ++++++++++++++++ .../package/macosx}/sparrow.icns | Bin .../sparrowwallet/sparrow/AppController.java | 3 --- 6 files changed, 22 insertions(+), 6 deletions(-) rename src/main/{resources => deploy}/associations.properties (100%) create mode 100644 src/main/deploy/package/macosx/Sparrow.entitlements rename src/main/{resources => deploy/package/macosx}/sparrow.icns (100%) diff --git a/.gitignore b/.gitignore index 0f93c9fd..fb51e346 100644 --- a/.gitignore +++ b/.gitignore @@ -4,4 +4,5 @@ build /*.properties out -*.log \ No newline at end of file +*.log +build-*.sh \ No newline at end of file diff --git a/build.gradle b/build.gradle index c1bc9c31..5fb3e52d 100644 --- a/build.gradle +++ b/build.gradle @@ -67,7 +67,8 @@ jlink { jpackage { imageName = "Sparrow" installerName = "Sparrow" - appVersion = "0.5" + appVersion = "0.51" + skipInstaller = true imageOptions = [] installerOptions = [ '--file-associations', 'src/main/resources/associations.properties', @@ -76,7 +77,8 @@ jlink { installerOptions += ['--win-per-user-install', '--win-dir-chooser', '--win-menu'] } if (org.gradle.internal.os.OperatingSystem.current().macOsX) { - imageOptions += ['--icon', 'src/main/resources/sparrow.icns'] + installerOptions += ['--mac-sign', '--mac-signing-key-user-name', 'Craig Raw (UPLVMSK9D7)'] + imageOptions += ['--icon', 'src/main/deploy/package/macosx/sparrow.icns'] installerType = "dmg" } } diff --git a/src/main/resources/associations.properties b/src/main/deploy/associations.properties similarity index 100% rename from src/main/resources/associations.properties rename to src/main/deploy/associations.properties diff --git a/src/main/deploy/package/macosx/Sparrow.entitlements b/src/main/deploy/package/macosx/Sparrow.entitlements new file mode 100644 index 00000000..b5f24c57 --- /dev/null +++ b/src/main/deploy/package/macosx/Sparrow.entitlements @@ -0,0 +1,16 @@ + + + + + com.apple.security.cs.allow-jit + + com.apple.security.cs.allow-unsigned-executable-memory + + com.apple.security.cs.disable-executable-page-protection + + com.apple.security.cs.disable-library-validation + + com.apple.security.cs.allow-dyld-environment-variables + + + \ No newline at end of file diff --git a/src/main/resources/sparrow.icns b/src/main/deploy/package/macosx/sparrow.icns similarity index 100% rename from src/main/resources/sparrow.icns rename to src/main/deploy/package/macosx/sparrow.icns diff --git a/src/main/java/com/sparrowwallet/sparrow/AppController.java b/src/main/java/com/sparrowwallet/sparrow/AppController.java index 69a108b4..c8a742da 100644 --- a/src/main/java/com/sparrowwallet/sparrow/AppController.java +++ b/src/main/java/com/sparrowwallet/sparrow/AppController.java @@ -12,10 +12,7 @@ import com.sparrowwallet.sparrow.event.TabEvent; import com.sparrowwallet.sparrow.event.TransactionTabChangedEvent; import com.sparrowwallet.sparrow.event.TransactionTabSelectedEvent; import com.sparrowwallet.sparrow.transaction.TransactionController; -import javafx.beans.value.ChangeListener; -import javafx.beans.value.ObservableValue; import javafx.event.ActionEvent; -import javafx.event.EventHandler; import javafx.fxml.FXML; import javafx.fxml.FXMLLoader; import javafx.fxml.Initializable;