;This software is OSI Certified Open Source Software.
;OSI Certified is a certification mark of the Open Source Initiative.

;This program is free software; you can redistribute it and/or
;modify it under the terms of the GNU General Public License
;as published by the Free Software Foundation; either version 2
;of the License, or (at your option) any later version.

;This program is distributed in the hope that it will be useful,
;but WITHOUT ANY WARRANTY; without even the implied warranty of
;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;GNU General Public License for more details.

;You should have received a copy of the GNU General Public License
;along with this program; if not, write to the Free Software
;Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.

!define NAME                     "PWRISOVMPortable"
!define FULLNAME                 "PowerISO Virtual Drive Manager"
!define BUILD                    "0.0.0.0"
!define WEBSITE                  "http://www.poweriso.com/"
!define SWITCH                   "PowerISOPortable.exe -1"
;=== DETAiLS ====================
Name                             "${FULLNAME}"
OutFile                          "..\${NAME}.exe"
Caption                          "${FULLNAME}"
VIProductVersion                 "${BUILD}"
VIAddVersionKey ProductName      "${FULLNAME}"
VIAddVersionKey Comments         http://portablewares.blogspot.com/
VIAddVersionKey CompanyName      "Power Software Ltd"
VIAddVersionKey LegalCopyright   "Copyright (C) 2004-2015"
VIAddVersionKey FileDescription  "${FULLNAME}"
VIAddVersionKey FileVersion      "${BUILD}"
VIAddVersionKey ProductVersion   Portable
VIAddVersionKey InternalName     "${FULLNAME}"
VIAddVersionKey OriginalFilename "${NAME}.exe"

;=== RUNTiME
CRCCheck On
WindowIcon Off
SilentInstall Silent
AutoCloseWindow True
RequestExecutionLevel user

;=== COMPRESSiON
SetCompress Auto
SetCompressor /SOLID lzma
SetCompressorDictSize 32
SetDatablockOptimize On

;=== iNCLUDE
!include FileFunc.nsh
!insertmacro GetParameters

;=== iCON
Icon "..\App\AppInfo\appicon2.ico"

Section Main
	SetOutPath "$EXEDIR"
	${GetParameters} $0
	StrCmp "'$0'" "''" "" +3
	StrCpy $R0 "${SWITCH}"
	Goto +2
	StrCpy $R0 "${SWITCH} $0"
	Exec "$R0"
SectionEnd