summaryrefslogtreecommitdiff
path: root/branding/templates/windows
diff options
context:
space:
mode:
authorkali kaneko (leap communications) <kali@leap.se>2020-04-24 18:57:01 +0200
committerkali kaneko (leap communications) <kali@leap.se>2020-04-30 22:10:31 +0200
commita14b4ac6507b65d9b2d5e22ff89cf89c689cd936 (patch)
tree7eaecf9f82d703e3da30e9efe3a63a4d56b39368 /branding/templates/windows
parent3a9f65fb9ccb32e6ef0e3f3c471cc50f1c3ee505 (diff)
[bug] do not use cross-compiling for the helper in win
- add -H windowsgui to avoid console popping up
Diffstat (limited to 'branding/templates/windows')
-rwxr-xr-xbranding/templates/windows/payload/install2
-rwxr-xr-xbranding/templates/windows/payload/uninstall15
-rwxr-xr-xbranding/templates/windows/template.nsi23
3 files changed, 27 insertions, 13 deletions
diff --git a/branding/templates/windows/payload/install b/branding/templates/windows/payload/install
index da9a195..280703a 100755
--- a/branding/templates/windows/payload/install
+++ b/branding/templates/windows/payload/install
@@ -1,4 +1,4 @@
-..\staging\bitmask_helper.exe
+..\staging\helper.exe
..\staging\bitmask-vpn.exe
..\staging\libcrypto-1_1-x64.dll
..\staging\liblzo2-2.dll
diff --git a/branding/templates/windows/payload/uninstall b/branding/templates/windows/payload/uninstall
index f0a1687..bb6cf39 100755
--- a/branding/templates/windows/payload/uninstall
+++ b/branding/templates/windows/payload/uninstall
@@ -1,13 +1,14 @@
icon.ico
-openssl.exe
-openvpn.exe
-ssleay32.dll
-libeay32.dll
-liblzo2-2.dll
-libpkcs11-helper-1.dll
+openssl.exe
+openvpn.exe
+ssleay32.dll
+libeay32.dll
+liblzo2-2.dll
+libpkcs11-helper-1.dll
libcrypto-1_1-x64.dll
libssl-1_1-x64.dll
padlock.dll
-bitmask-helper.exe
+bitmask_helper.exe
bitmask-vpn.exe
tap-windows.exe
+helper.exe
diff --git a/branding/templates/windows/template.nsi b/branding/templates/windows/template.nsi
index f6a908d..9c319d0 100755
--- a/branding/templates/windows/template.nsi
+++ b/branding/templates/windows/template.nsi
@@ -61,6 +61,11 @@ Section "InstallFiles"
Delete 'C:\Program Files\$applicationName\bitmask_helper.exe'
IfErrors 0 noErrorHelper
+ DetailPrint "Trying to uninstall new helper..."
+ ClearErrors
+ Delete 'C:\Program Files\$applicationName\helper.exe'
+ IfErrors 0 noErrorHelper
+
; uninstalling old nssm helper - could fail if it isn't there, or if nssm is not there...
ClearErrors
DetailPrint "Trying to uninstall an old style helper..."
@@ -77,6 +82,12 @@ Section "InstallFiles"
IfErrors 0 noErrorHelper
DetailPrint "Failed to stop new-style helper, maybe it was not there"
+ ClearErrors
+ DetailPrint "Trying to uninstall a new style helper..."
+ ExecWait '"$INSTDIR\helper.exe" stop'
+ IfErrors 0 noErrorHelper
+ DetailPrint "Failed to stop new-style helper, maybe it was not there"
+
noErrorHelper:
; now we try to delete the systray, locked by the app - just to know if another instance of FoobarVPN is running.
@@ -120,14 +131,14 @@ SectionEnd
Section "InstallService"
DetailPrint "Trying to uninstall previous versions of the (new) helper..."
ClearErrors
- ExecWait '"$INSTDIR\bitmask_helper.exe" stop'
- ExecWait '"$INSTDIR\bitmask_helper.exe" remove'
+ ExecWait '"$INSTDIR\helper.exe" stop'
+ ExecWait '"$INSTDIR\helper.exe" remove'
IfErrors 0 noError
DetailPrint "Could not uninstall a previous version of the (new) helper!"
noError:
- ExecWait '"$INSTDIR\bitmask_helper.exe" install'
- ExecWait '"$INSTDIR\bitmask_helper.exe" start'
+ ExecWait '"$INSTDIR\helper.exe" install'
+ ExecWait '"$INSTDIR\helper.exe" start'
SectionEnd
Section /o "TAP Virtual Ethernet Adapter" SecTAP
@@ -147,9 +158,11 @@ Section "Uninstall"
ExecWait '"$INSTDIR\bitmask_helper.exe" stop'
ExecWait '"$INSTDIR\bitmask_helper.exe" remove'
+ ExecWait '"$INSTDIR\helper.exe" stop'
+ ExecWait '"$INSTDIR\helper.exe" remove'
+
; now we (try to) remove everything else. kill it with fire!
Delete $INSTDIR\nssm.exe ; probably does not exist anymore, but just in case
- Delete $INSTDIR\bitmask_helper.exe
Delete $INSTDIR\readme.txt
Delete $INSTDIR\helper.log
Delete $INSTDIR\openvpn.log