summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile17
1 files changed, 14 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 2ea9458..f867fcd 100644
--- a/Makefile
+++ b/Makefile
@@ -3,7 +3,7 @@
# (c) LEAP Encryption Access Project, 2019-2020
#########################################################################
-.PHONY: all get build icon locales generate_locales clean
+.PHONY: all get build icon locales generate_locales clean check_qtifw HAS-qtifw
XBUILD ?= no
SKIP_CACHECK ?= no
@@ -28,6 +28,8 @@ SCRIPTS = branding/scripts
all: icon locales helper build
+HAS_QTIFW := $(shell PATH=$(PATH) which binarycreator)
+
#########################################################################
# go build
@@ -79,12 +81,18 @@ else
@gui/build.sh
endif
-build_installer: build
- # TODO check for binarycreator in path
+build_installer: check_qtifw build
cp -r qtbuild/release/${PROVIDER}-vpn.app installer/packages/${PROVIDER}vpn/data/
cp build/bin/${PLATFORM}/bitmask-helper installer/packages/${PROVIDER}vpn/data/
cd installer && qmake && make
+check_qtifw:
+ifdef HAS_QTIFW
+ @echo "[+] Found QTIFW"
+else
+ $(error "[!] Cannot find QTIFW. Please install it and add it to your PATH")
+endif
+
# ----------- FIXME ------- old build, reuse or delete -----------------------------
CROSS_WIN_FLAGS = CGO_ENABLED=1 GOARCH=386 GOOS=windows CC="/usr/bin/i686-w64-mingw32-gcc" CGO_LDFLAGS="-lssp" CXX="i686-w64-mingw32-c++"
@@ -113,6 +121,9 @@ _build_xbuild_done:
# --------- FIXME -----------------------------------------------------------------------
clean:
+ @rm -rf installer/*.app
+ @rm -rf installer/packages/${PROVIDER}vpn/data/*.app
+ @rm -rf installer/packages/${PROVIDER}vpn/data/bitmask-helper
@rm -rf build/
@unlink branding/assets/default