Skip to content

Commit

Permalink
Windows: explicit define type of installer
Browse files Browse the repository at this point in the history
4 variants:
makensis -Dstatic=32 EiskaltDC++.nsi
makensis -Dstatic=64 EiskaltDC++.nsi
makensis -Dshared=32 EiskaltDC++.nsi
makensis -Dshared=64 EiskaltDC++.nsi
  • Loading branch information
pavelvat committed Oct 8, 2017
1 parent e1f5678 commit ee30335
Showing 1 changed file with 4 additions and 21 deletions.
25 changes: 4 additions & 21 deletions windows/EiskaltDC++.nsi
@@ -1,28 +1,11 @@
!include MUI2.nsh

; See http://nsis.sourceforge.net/Check_if_a_file_exists_at_compile_time for documentation
!macro !defineifexist _VAR_NAME _FILE_NAME
!tempfile _TEMPFILE
!ifdef NSIS_WIN32_MAKENSIS
; Windows - cmd.exe
!system 'if exist "${_FILE_NAME}" echo !define ${_VAR_NAME} > "${_TEMPFILE}"'
!else
; Posix - sh
!system 'if [ -e "${_FILE_NAME}" ]; then echo "!define ${_VAR_NAME}" > "${_TEMPFILE}"; fi'
!endif
!include '${_TEMPFILE}'
!delfile '${_TEMPFILE}'
!undef _TEMPFILE
!macroend
!define !defineifexist "!insertmacro !defineifexist"

!if ${static} == 32
!define arch_x86
!else
!if ${static} != 64
!define shared
${!defineifexist} arch_x86 "installer\libgcc_s_sjlj-1.dll"
!endif
!endif

!if ${shared} == 32
!define arch_x86
!endif

!define PRODUCT_DISPLAY_VERSION "2.4.0"
Expand Down

0 comments on commit ee30335

Please sign in to comment.