From 89bb53fe82c048fc322075b67b1bc7048d4fc53d Mon Sep 17 00:00:00 2001 From: Kali Kaneko Date: Wed, 4 Jul 2018 22:25:15 +0200 Subject: [pkg] move info.plist to template --- Makefile | 49 ++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 44 insertions(+), 5 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 7e9ec69..4d3b01d 100755 --- a/Makefile +++ b/Makefile @@ -1,5 +1,11 @@ -SYSTRAY := 0xacab.org/leap/bitmask-systray +SYSTRAY := 0xacab.org/leap/bitmask-systray.git STAGING := staging +SYSTRAY_BIN := bitmask-systray +HELPER_BIN := bitmask_helper + +# ----------------------------------------------------------------------------- +# Windows +# ----------------------------------------------------------------------------- deps_win: choco install -y golang python upx nssm nsis wget 7zip @@ -14,21 +20,54 @@ openvpn_win: copy .\staging\openvpn\openvpn.exe .\staging copy .\staging\openvpn\*.dll .\staging helper_win: - go build -ldflags "-s -w" -o $(STAGING)/bitmask_helper.exe .\helper - upx $(STAGING)/bitmask_helper.exe + go build -ldflags "-s -w" -o $(STAGING)/$(HELPER_BIN).exe .\helper + upx $(STAGING)/$(HELPER_BIN).exe systray_win: go get -tags "standalone" -u $(SYSTRAY) - go build -tags "standalone" -ldflags "-H windowsgui -s -w" -o $(STAGING)/bitmask-systray.exe $(SYSTRAY) + go build -tags "standalone" -ldflags "-H windowsgui -s -w" -o $(STAGING)/$(SYSTRAY_BIN).exe $(SYSTRAY) build_win: staging\nssm.exe helper_win systray_win # since it's tedious, I assume you did bootstrap openvpn_win manually already. echo "[+] building windows" if not exist dist mkdir dist make -C win "C:\Program Files (x86)\NSIS\makensis.exe" win/RiseupVPN-installer.nsi -build_osx: + +# ----------------------------------------------------------------------------- +# OSX +# ----------------------------------------------------------------------------- + +deps_osx: +# TODO - bootstrap homebrew if not there + brew install python golang make upx +openvpn_osx: +# TODO - the build script is in bitmask-dev/pkg/thirdparty. we can clone from there, or move that stuff here. +# TODO for now we can download it from downloads.leap.se + echo "[+] downloading openvpn..." +helper_osx: + go build -ldflags "-s -w" -o $(STAGING)/$(HELPER_BIN) ./helper + upx $(STAGING)/$(HELPER_BIN) +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..." + mkdir -p dist + make -C osx + +# ----------------------------------------------------------------------------- +# Linux +# ----------------------------------------------------------------------------- + build_snap: +# TODO migrate here the snap folder in bitmask-dev. +# We should transition pushing *this one* to edge (via launchpad) for some time, and when it's sufficiently tested +# we can pin this repo as the only source for the snap. echo "[+] building snap..." +# ----------------------------------------------------------------------------- +# Utils +# ----------------------------------------------------------------------------- + staging\nssm.exe: xcopy /y "C:\ProgramData\chocolatey\lib\NSSM\tools\nssm.exe" $(STAGING) -- cgit v1.2.3