| 1 |
;Change this file to customize zip2exe generated installers |
| 2 |
|
| 3 |
Name "${ZIP2EXE_NAME}" |
| 4 |
OutFile "${ZIP2EXE_OUTFILE}" |
| 5 |
|
| 6 |
AllowRootDirInstall true |
| 7 |
|
| 8 |
|
| 9 |
!ifdef ZIP2EXE_COMPRESSOR_SOLID |
| 10 |
!define SETCOMPRESSOR_SWITCH /SOLID |
| 11 |
!else |
| 12 |
!define SETCOMPRESSOR_SWITCH |
| 13 |
!endif |
| 14 |
SetCompressor ${SETCOMPRESSOR_SWITCH} ${ZIP2EXE_COMPRESSOR} |
| 15 |
|
| 16 |
|
| 17 |
!ifdef ZIP2EXE_INSTALLDIR |
| 18 |
|
| 19 |
InstallDir "${ZIP2EXE_INSTALLDIR}" |
| 20 |
|
| 21 |
Function zip2exe.SetOutPath |
| 22 |
SetOutPath "$INSTDIR" |
| 23 |
FunctionEnd |
| 24 |
|
| 25 |
!else ifdef ZIP2EXE_INSTALLDIR_WINAMP |
| 26 |
|
| 27 |
InstallDir "$PROGRAMFILES\Winamp" |
| 28 |
InstallDirRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Winamp" "UninstallString" |
| 29 |
|
| 30 |
Function .onVerifyInstDir |
| 31 |
IfFileExists $INSTDIR\winamp.exe WinampInstalled |
| 32 |
Abort |
| 33 |
WinampInstalled: |
| 34 |
FunctionEnd |
| 35 |
|
| 36 |
!ifdef ZIP2EXE_INSTALLDIR_WINAMPMODE |
| 37 |
|
| 38 |
Var ZIP2EXE_TEMP1 |
| 39 |
Var ZIP2EXE_TEMP2 |
| 40 |
|
| 41 |
Function zip2exe.SetOutPath |
| 42 |
!ifdef ZIP2EXE_INSTALLDIR_SKINS |
| 43 |
StrCpy $ZIP2EXE_TEMP1 "$INSTDIR\Skins" |
| 44 |
!else |
| 45 |
StrCpy $ZIP2EXE_TEMP1 "$INSTDIR\Plugins" |
| 46 |
!endif |
| 47 |
ReadINIStr $ZIP2EXE_TEMP2 "$INSTDIR\winamp.ini" "Winamp" "${ZIP2EXE_INSTALLDIR_WINAMPMODE}" |
| 48 |
StrCmp $ZIP2EXE_TEMP2 "" End |
| 49 |
IfFileExists $ZIP2EXE_TEMP2 0 End |
| 50 |
StrCpy $ZIP2EXE_TEMP1 $ZIP2EXE_TEMP2 |
| 51 |
End: |
| 52 |
SetOutPath $ZIP2EXE_TEMP1 |
| 53 |
FunctionEnd |
| 54 |
|
| 55 |
!else |
| 56 |
|
| 57 |
Function zip2exe.SetOutPath |
| 58 |
!ifdef ZIP2EXE_INSTALLDIR_PLUGINS |
| 59 |
SetOutPath "$INSTDIR\Plugins" |
| 60 |
!else |
| 61 |
SetOutPath "$INSTDIR" |
| 62 |
!endif |
| 63 |
FunctionEnd |
| 64 |
|
| 65 |
!endif |
| 66 |
|
| 67 |
!endif |
| 68 |
|
| 69 |
!macro SECTION_BEGIN |
| 70 |
|
| 71 |
Section "" |
| 72 |
|
| 73 |
Call zip2exe.SetOutPath |
| 74 |
|
| 75 |
!macroend |
| 76 |
|
| 77 |
!macro SECTION_END |
| 78 |
|
| 79 |
SectionEnd |
| 80 |
|
| 81 |
!macroend |