[gtk-mac-bundler] Sign bundles even when there isn't a launcher script.



commit f2c7635a5a4d740a0737f59e131ca181fafada28
Author: John Ralls <jralls ceridwen us>
Date:   Fri Apr 7 15:19:50 2017 -0700

    Sign bundles even when there isn't a launcher script.
    
    By fixing an indentation error. Move the codesigning comment to the
    right place while we're at it.

 bundler/bundler.py |   28 +++++++++++++---------------
 1 files changed, 13 insertions(+), 15 deletions(-)
---
diff --git a/bundler/bundler.py b/bundler/bundler.py
index 80c3ea2..2242d7b 100644
--- a/bundler/bundler.py
+++ b/bundler/bundler.py
@@ -380,14 +380,6 @@ class Bundler:
             self.binaries_to_copy.extend(new_libraries)
             paths = new_libraries
 
-
-#
-# If you want to sign your application, set $APPLICATION_CERT with the
-# appropriate certificate name in your default Keychain. This function
-# will sign every binary in the bundle with the certificate and the
-# bundle's id string.
-#
-
     def copy_icon_themes(self):
         all_icons = set()
 
@@ -494,13 +486,19 @@ class Bundler:
         launcher_script = self.project.get_launcher_script()
         if launcher_script:
             path = launcher_script.copy_target(self.project)
-            if "APPLICATION_CERT" in os.environ:
-                cert = os.environ["APPLICATION_CERT"]
-                ident = self.project.get_bundle_id()
-                cmdargs = ['codesign', '-s', cert, '-i', ident, "-f", path]
-                result = os.spawnvp(os.P_WAIT, 'codesign', cmdargs)
-                if result:
-                    raise OSError('"'+ " ".join(cmdargs) + '" failed %d' % result)
+
+# If you want to sign your application, set $APPLICATION_CERT with the
+# appropriate certificate name in your default Keychain. This function
+# will sign every binary in the bundle with the certificate and the
+# bundle's id string.
+#
+        if "APPLICATION_CERT" in os.environ:
+            cert = os.environ["APPLICATION_CERT"]
+            ident = self.project.get_bundle_id()
+            cmdargs = ['codesign', '-s', cert, '-i', ident, "-f", path]
+            result = os.spawnvp(os.P_WAIT, 'codesign', cmdargs)
+            if result:
+                raise OSError('"'+ " ".join(cmdargs) + '" failed %d' % result)
 
         if self.meta.overwrite:
             self.recursive_rm(final_path)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]