From 5f66af8266eda3e8bc5d1b394e5fb81271b7733f Mon Sep 17 00:00:00 2001 From: Kali Kaneko Date: Wed, 4 Jul 2018 23:14:14 +0200 Subject: [pkg] generate install scripts for helper --- Makefile | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 4d3b01d..5aea1a2 100755 --- a/Makefile +++ b/Makefile @@ -2,6 +2,10 @@ SYSTRAY := 0xacab.org/leap/bitmask-systray.git STAGING := staging SYSTRAY_BIN := bitmask-systray HELPER_BIN := bitmask_helper +APP_NAME := RiseupVPN +BUILD_RELEASE?=no +OSX_CERT = "Developer ID Installer: LEAP Encryption Access Project" +VERSION = $(shell cat version) # ----------------------------------------------------------------------------- # Windows @@ -50,10 +54,19 @@ systray_osx: go get -tags "standalone" -u $(SYSTRAY) go build -tags "standalone" -o $(STAGING)/$(SYSTRAY_BIN) $(SYSTRAY) upx $(STAGING)/$(SYSTRAY_BIN) -build_osx: helper_osx systray_osx - echo "[+] building osx..." +bundle_osx: mkdir -p dist make -C osx +pkg_osx: + osx/quickpkg --output dist/$(APP_NAME)-$(VERSION)_unsigned.pkg --scripts osx/scripts/ dist/$(APP_NAME).app/ + @if [ $(BUILD_RELEASE) = no ]; then\ + echo "[!] BUILD_RELEASE=no, skipping signature";\ + else\ + echo "[+] Signing the bundle";\ + productsign --sign $(OSX_CERT) dist/$(APP_NAME)-$(VERSION)_unsigned.pkg dist/$(APP_NAME)-$(VERSION).pkg;\ + fi +build_osx: helper_osx systray_osx bundle_osx pkg_osx + echo "[+] building osx..." # ----------------------------------------------------------------------------- # Linux @@ -69,5 +82,8 @@ build_snap: # Utils # ----------------------------------------------------------------------------- +clean: + rm -rf dist/ + staging\nssm.exe: xcopy /y "C:\ProgramData\chocolatey\lib\NSSM\tools\nssm.exe" $(STAGING) -- cgit v1.2.3