Building a Signed Mac Application
In this page I will be showing you how to build a signed mac application for Scilab.
Pre-requisites
- Compiled Scilab files.
- A Developer ID issued by Apple
Major Changes at a glance
- All the compiled code is moved to Resources folder.(the script manages the work of moving files to correct places you don't need to worry.)
- A new Info.plist file which is created according to the version number, I created a new Info.plist because the one available as a thirdparty was not in accordance with Apple Guidelines.
It can be found here: https://github.com/dvkcool/scilabAppCreator/blob/master/etc/Info.plist - Removal of checkmacosx.applescript, this file was an outdated apple script which creates error while codesigning. I did incorporate the applescript part in the scilab starter script using osascript - a modernly to use AppleScript features through shell script.:
Old method:
New method:
The complete new starter script can be found here: https://github.com/dvkcool/scilabAppCreator/blob/master/etc/bin/scilab
Procedure
- Download my project from github using following command.
git clone https://github.com/dvkcool/scilabAppCreator.git - Paste the scilab compiled files in the src folder of my project.
- Run the main shell script, using sudo sh createApp.sh
- Answer the questions like build version and signing key.
You don't need to worry about anythig including the folder structure, the script takes care of everything and creates a nice Ready to Distribute dmg.
Video demo of the process
Here is a video which shows exactly how to do these steps.Important points to be Noted
- Be sure to backup your Developer ID certificate(because once it gets lost, it gets really troublesome to get a new one)
- Keep in mind to export your private keys (related to the certificate too).
A compiled dmg for Scilab 6.0 can be found here: https://drive.google.com/open?id=1Gl4dRngHxGvSTOHOg_U8GX4yJlSu4LZU
In case of any queries/doubts feel free to drop me a mail at divyanshukumarg@gmail.com
Hoping for Best.
Happily Coding
Divyanshu Kumar