remove extraneous libusb0.dll

remove extraneous libusb0.dll

git-svn-id: 03a8048b5ee8463be5048a3801110fb50f378627@6735 d0ab736e-dc22-4aeb-8dc9-08def0aa14fd

; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

[Setup]
AppName=Micro-Manager-1.4
AppVerName=Micro-Manager-1.4
AppPublisher=UCSF
AppPublisherURL=http://www.micro-manager.org
AppSupportURL=http://www.micro-manager.org
AppUpdatesURL=http://www.micro-manager.org
DefaultDirName=C:/Program Files/Micro-Manager-1.4
DefaultGroupName=Micro-Manager-1.4
OutputBaseFilename=MMSetup_
Compression=lzma
SolidCompression=true
VersionInfoVersion=1.4
VersionInfoCompany=(c)University of California San Francisco
VersionInfoCopyright=(c)University of California San Francisco, (c)100XImaging Inc
AppCopyright=University of California San Francisco, 100XImaging Inc
ShowLanguageDialog=yes
AppVersion=1.4
AppID=31830087-F23D-4198-B67D-AD4A2A69147F
ArchitecturesAllowed=x64
; "ArchitecturesInstallIn64BitMode=x64" requests that the install be
; done in "64-bit mode" on x64, meaning it should use the native
; 64-bit Program Files directory and the 64-bit view of the registry.
ArchitecturesInstallIn64BitMode=x64

[Languages]
Name: eng; MessagesFile: compiler:Default.isl

[Tasks]
Name: desktopicon; Description: {cm:CreateDesktopIcon}; GroupDescription: {cm:AdditionalIcons}; Flags: unchecked

[Files]
; the entire redistributable set
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.ATL\atl90.dll ; DestDir: {app}\Microsoft.VC90.ATL; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.ATL\Microsoft.VC90.ATL.manifest ; DestDir: {app}\Microsoft.VC90.ATL; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.CRT\msvcm90.dll ; DestDir: {app}\Microsoft.VC90.CRT; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.CRT\msvcp90.dll ; DestDir: {app}\Microsoft.VC90.CRT; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.CRT\msvcr90.dll ; DestDir: {app}\Microsoft.VC90.CRT; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.CRT\Microsoft.VC90.CRT.manifest ; DestDir: {app}\Microsoft.VC90.CRT; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\mfc90.dll ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\mfc90u.dll ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\mfcm90.dll ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\mfcm90u.dll ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\Microsoft.VC90.MFC.manifest ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90CHS.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90CHT.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90DEU.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90ENU.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90ESN.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90ESP.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90FRA.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90ITA.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90JPN.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90KOR.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\Microsoft.VC90.MFCLOC.manifest ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.OPENMP\vcomp90.dll ; DestDir: {app}\Microsoft.VC90.OPENMP; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.OPENMP\Microsoft.VC90.OpenMP.manifest ; DestDir: {app}\Microsoft.VC90.OPENMP; Flags: ignoreversion

;
Source: ..\..\3rdparty\jre\* ; DestDir: {app}\jre; Flags: ignoreversion recursesubdirs createallsubdirs

; device libraries
Source: micro-manager\atmcd64d.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\inpoutx64.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\MMCoreJ_wrap.dll; DestDir: {app}; Flags: ignoreversion

Source: micro-manager\mmgr_dal_AAAOTF.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Andor.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_AndorLaserCombiner.dll; DestDir: {app}; Flags: ignoreversion
;Source: micro-manager\mmgr_dal_Apogee.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Arduino.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ASIFW1000.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ASIStage.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ASIwptr.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_CoherentCube.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Conix.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Corvus.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_CSUX.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_DemoCamera.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_DTOpenLayer.dll; DestDir: {app}; Flags: ignoreversion
;Source: micro-manager\mmgr_dal_XCite120PC_Exacte.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_GenericSLM.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_GigECamera.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_FreeSerialPort.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Hamamatsu.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_K8055.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_K8061.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_KDV.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_LeicaDMI.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_LeicaDMR.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Ludl.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_MaestroServo.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Marzhauser.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_MT20.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Neos.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Nikon.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_NikonAZ100.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_NikonTE2000.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_NikonTI.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_NNLC.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Olympus.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ParallelPort.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Pecon.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PI.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PI_GCS.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Piper.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PrecisExcite.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PrincetonInstruments.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Prior.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PVCAM.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_QCam.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Sapphire.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SerialManager.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SimpleAutofocus.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SpectralLMM5.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SpotCamera.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SutterLambda.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ThorlabsFilterWheel.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ThorlabsSC10.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_TIScam.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_TwainCamera.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_USBManager.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Utilities.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Vincent.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Yokogawa.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ZeissCAN.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ZeissCAN29.dll; DestDir: {app}; Flags: ignoreversion
; python wrapper
;Source: micro-manager\_MMCorePy.pyd; DestDir: {app}; Flags: ignoreversion skipifsourcedoesntexist
;Source: micro-manager\MMCorePy.py; DestDir: {app}; Flags: ignoreversion skipifsourcedoesntexist
;Source: micro-manager\MMCoreWrapDemo.py; DestDir: {app}; Flags: ignoreversion skipifsourcedoesntexist

; drivers
Source: ..\drivers\*; DestDir: {app}\drivers; Flags: ignoreversion recursesubdirs

; beanshell scripts
Source: ..\scripts\*; DestDir: {app}\scripts; Flags: ignoreversion

; configuration files
Source: micro-manager\MMConfig_demo.cfg; DestDir: {app}; Flags: ignoreversion
;Source: micro-manager\MMDeviceList.txt; DestDir: {app}; Flags: ignoreversion

; ImageJ files
Source: ..\..\3rdpartypublic\JavaLauncher\ImageJ.exe; DestDir: {app}; Flags: ignoreversion

;Source: micro-manager\ImageJ.cfg; DestDir: {app}; Flags: onlyifdoesntexist
Source: ..\..\3rdpartypublic\classext\ij.jar; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\IJ_Prefs.txt; DestDir: {app}; Flags: onlyifdoesntexist
Source: micro-manager\macros\*; DestDir: {app}\macros; Flags: ignoreversion recursesubdirs createallsubdirs
Source: micro-manager\plugins\*; DestDir: {app}\plugins; Flags: ignoreversion recursesubdirs createallsubdirs
;Source: micro-manager\mmplugins\*; DestDir: {app}\mmplugins; Flags: ignoreversion recursesubdirs createallsubdirs
;Source: micro-manager\mmautofocus\*; DestDir: {app}\mmautofocus; Flags: ignoreversion recursesubdirs createallsubdirs

; NOTE: Don't use "Flags: ignoreversion" on any shared system files

[Icons]
Name: {group}\Micro-Manager-1.4; Filename: {app}\ImageJ.exe; WorkingDir: {app}
Name: {group}\{cm:UninstallProgram,Micro-Manager-1.4}; Filename: {uninstallexe}
Name: {commondesktop}\Micro-Manager 1.4; Filename: {app}\ImageJ.exe; Tasks: desktopicon; WorkingDir: {app}; IconIndex: 0

[Run]
Filename: {app}\ImageJ.exe; Description: {cm:LaunchProgram,Micro-Manager-1.4}; Flags: nowait postinstall

; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

[Setup]
AppName=Micro-Manager-1.4
AppVerName=Micro-Manager-1.4
AppPublisher=UCSF
AppPublisherURL=http://www.micro-manager.org
AppSupportURL=http://www.micro-manager.org
AppUpdatesURL=http://www.micro-manager.org
DefaultDirName=C:/Program Files/Micro-Manager-1.4
DefaultGroupName=Micro-Manager-1.4
OutputBaseFilename=MMSetup_
Compression=lzma
SolidCompression=true
VersionInfoVersion=1.4
VersionInfoCompany=(c)University of California San Francisco
VersionInfoCopyright=(c)University of California San Francisco, (c)100XImaging Inc
AppCopyright=University of California San Francisco, 100XImaging Inc
ShowLanguageDialog=yes
AppVersion=1.4
AppID=31830087-F23D-4198-B67D-AD4A2A69147F
ArchitecturesAllowed=x64
; "ArchitecturesInstallIn64BitMode=x64" requests that the install be
; done in "64-bit mode" on x64, meaning it should use the native
; 64-bit Program Files directory and the 64-bit view of the registry.
ArchitecturesInstallIn64BitMode=x64

[Languages]
Name: eng; MessagesFile: compiler:Default.isl

[Tasks]
Name: desktopicon; Description: {cm:CreateDesktopIcon}; GroupDescription: {cm:AdditionalIcons}; Flags: unchecked

[Files]
; the entire redistributable set
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.ATL\atl90.dll ; DestDir: {app}\Microsoft.VC90.ATL; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.ATL\Microsoft.VC90.ATL.manifest ; DestDir: {app}\Microsoft.VC90.ATL; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.CRT\msvcm90.dll ; DestDir: {app}\Microsoft.VC90.CRT; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.CRT\msvcp90.dll ; DestDir: {app}\Microsoft.VC90.CRT; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.CRT\msvcr90.dll ; DestDir: {app}\Microsoft.VC90.CRT; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.CRT\Microsoft.VC90.CRT.manifest ; DestDir: {app}\Microsoft.VC90.CRT; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\mfc90.dll ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\mfc90u.dll ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\mfcm90.dll ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\mfcm90u.dll ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFC\Microsoft.VC90.MFC.manifest ; DestDir: {app}\Microsoft.VC90.MFC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90CHS.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90CHT.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90DEU.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90ENU.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90ESN.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90ESP.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90FRA.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90ITA.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90JPN.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\MFC90KOR.dll ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.MFCLOC\Microsoft.VC90.MFCLOC.manifest ; DestDir: {app}\Microsoft.VC90.MFCLOC; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.OPENMP\vcomp90.dll ; DestDir: {app}\Microsoft.VC90.OPENMP; Flags: ignoreversion
Source: ..\..\3rdparty\Microsoft\VisualC++\lib\amd64\Microsoft.VC90.OPENMP\Microsoft.VC90.OpenMP.manifest ; DestDir: {app}\Microsoft.VC90.OPENMP; Flags: ignoreversion

;
Source: ..\..\3rdparty\jre\* ; DestDir: {app}\jre; Flags: ignoreversion recursesubdirs createallsubdirs

; device libraries
Source: micro-manager\atmcd64d.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\inpoutx64.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\libusb0.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\MMCoreJ_wrap.dll; DestDir: {app}; Flags: ignoreversion

Source: micro-manager\mmgr_dal_AAAOTF.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Andor.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_AndorLaserCombiner.dll; DestDir: {app}; Flags: ignoreversion
;Source: micro-manager\mmgr_dal_Apogee.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Arduino.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ASIFW1000.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ASIStage.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ASIwptr.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_CoherentCube.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Conix.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Corvus.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_CSUX.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_DemoCamera.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_DTOpenLayer.dll; DestDir: {app}; Flags: ignoreversion
;Source: micro-manager\mmgr_dal_XCite120PC_Exacte.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_GenericSLM.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_GigECamera.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_FreeSerialPort.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Hamamatsu.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_K8055.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_K8061.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_KDV.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_LeicaDMI.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_LeicaDMR.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Ludl.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_MaestroServo.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Marzhauser.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_MT20.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Neos.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Nikon.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_NikonAZ100.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_NikonTE2000.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_NikonTI.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_NNLC.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Olympus.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ParallelPort.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Pecon.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PI.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PI_GCS.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Piper.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PrecisExcite.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PrincetonInstruments.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Prior.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_PVCAM.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_QCam.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Sapphire.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SerialManager.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SimpleAutofocus.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SpectralLMM5.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SpotCamera.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_SutterLambda.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ThorlabsFilterWheel.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ThorlabsSC10.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_TIScam.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_TwainCamera.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_USBManager.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Utilities.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Vincent.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_Yokogawa.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ZeissCAN.dll; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\mmgr_dal_ZeissCAN29.dll; DestDir: {app}; Flags: ignoreversion
; python wrapper
;Source: micro-manager\_MMCorePy.pyd; DestDir: {app}; Flags: ignoreversion skipifsourcedoesntexist
;Source: micro-manager\MMCorePy.py; DestDir: {app}; Flags: ignoreversion skipifsourcedoesntexist
;Source: micro-manager\MMCoreWrapDemo.py; DestDir: {app}; Flags: ignoreversion skipifsourcedoesntexist

; drivers
Source: ..\drivers\*; DestDir: {app}\drivers; Flags: ignoreversion recursesubdirs

; beanshell scripts
Source: ..\scripts\*; DestDir: {app}\scripts; Flags: ignoreversion

; configuration files
Source: micro-manager\MMConfig_demo.cfg; DestDir: {app}; Flags: ignoreversion
;Source: micro-manager\MMDeviceList.txt; DestDir: {app}; Flags: ignoreversion

; ImageJ files
Source: ..\..\3rdpartypublic\JavaLauncher\ImageJ.exe; DestDir: {app}; Flags: ignoreversion

;Source: micro-manager\ImageJ.cfg; DestDir: {app}; Flags: onlyifdoesntexist
Source: ..\..\3rdpartypublic\classext\ij.jar; DestDir: {app}; Flags: ignoreversion
Source: micro-manager\IJ_Prefs.txt; DestDir: {app}; Flags: onlyifdoesntexist
Source: micro-manager\macros\*; DestDir: {app}\macros; Flags: ignoreversion recursesubdirs createallsubdirs
Source: micro-manager\plugins\*; DestDir: {app}\plugins; Flags: ignoreversion recursesubdirs createallsubdirs
;Source: micro-manager\mmplugins\*; DestDir: {app}\mmplugins; Flags: ignoreversion recursesubdirs createallsubdirs
;Source: micro-manager\mmautofocus\*; DestDir: {app}\mmautofocus; Flags: ignoreversion recursesubdirs createallsubdirs

; NOTE: Don't use "Flags: ignoreversion" on any shared system files

[Icons]
Name: {group}\Micro-Manager-1.4; Filename: {app}\ImageJ.exe; WorkingDir: {app}
Name: {group}\{cm:UninstallProgram,Micro-Manager-1.4}; Filename: {uninstallexe}
Name: {commondesktop}\Micro-Manager 1.4; Filename: {app}\ImageJ.exe; Tasks: desktopicon; WorkingDir: {app}; IconIndex: 0

[Run]
Filename: {app}\ImageJ.exe; Description: {cm:LaunchProgram,Micro-Manager-1.4}; Flags: nowait postinstall


Wrong installer version

Wrong installer version

#define MyAppVer gemVersion+".0"
#define MyAppVerText gemVersion+".0"
#define MyAppCopyright "Udo Schneider <Udo_Schneider@trendmicro.de>"
#define MyAppCompany "Trend Micro"
#define MyAppName "dsc"

; #define gemVersion "0.0.16"
; #define gemFilename "deepsecurity-"+gemVersion+".gem"

; #define rubyVersion "1.9.3-p392"
#define rubyFilename "rubyinstaller-"+rubyVersion+".exe"
#define rubyUrl = "http://rubyforge.org/frs/download.php/76798/rubyinstaller-"+rubyVersion+".exe"

[Setup]
DefaultDirName={pf}\{#MyAppCompany}\{#MyAppName}
InternalCompressLevel=ultra
; OutputDir={#BaseDir}
; SourceDir={#BaseDir}
SolidCompression=true
AppCopyright=Copyright � {#MyAppCopyright}
AppName={#MyAppName}
AppVerName={#MyAppName} {#MyAppVerText}
ShowLanguageDialog=yes
DefaultGroupName={#MyAppCompany}\{#MyAppName}
AppID=84EDC400-BEB5-446E-90F8-6A9FBF89C3CD
Uninstallable=false
OutputBaseFilename={#MyAppName}_setup_{#MyAppVerText}
;WizardImageFile=Sources\WizardBigImage.bmp
;WizardSmallImageFile=Sources\WizardSmallImage.bmp
WizardImageFile=compiler:wizmodernimage-IS.bmp
WizardSmallImageFile=compiler:wizmodernsmallimage-IS.bmp
VersionInfoVersion={#MyAppVer}
VersionInfoCompany={#MyAppCompany}
VersionInfoDescription={#MyAppName} Setup
VersionInfoTextVersion={#MyAppVerText}
VersionInfoCopyright={#MyAppCopyright}
AppPublisher={#MyAppCompany}
AppPublisherURL=http://www.trendmicro.de/
AppSupportURL=http://www.trendmicro.de/
AppVersion={#MyAppVerText}
UninstallDisplayName={#MyAppName}
AppContact={#MyAppCompany}
AppSupportPhone=+49 (811) 88 99 0 698
ChangesAssociations=true
RestartIfNeededByRun=false

[Types]
Name: full; Description: {cm:fullInstallation}
Name: custom; Description: {cm:customInstallation}; Flags: iscustom

[Components]
Name: deepsecurity_gem; Description: deepsecurity gem ({#gemVersion}); Types: custom full
Name: ruby; Description: Ruby ({#rubyVersion}); Types: custom full; ExtraDiskSpaceRequired: 72204063

[Files]
Source: "isxdl.dll"; Flags: dontcopy
Source: "WizModernImage.bmp"; DestDir: "{app}"; Flags: ignoreversion
Source: "WizModernImage-IS.bmp"; DestDir: "{app}"; Flags: ignoreversion
Source: "WizModernSmallImage.bmp"; DestDir: "{app}"; Flags: ignoreversion
Source: "WizModernSmallImage-IS.bmp"; DestDir: "{app}"; Flags: ignoreversion

[Icons]

[Languages]
Name: en; MessagesFile: compiler:Default.isl
Name: de; MessagesFile: compiler:Languages\German.isl

[Run]
Filename: "{tmp}\{#rubyFilename}"; Parameters: "/SILENT /TASKS=""MODPATH"""; StatusMsg: "{cm:installingRuby}"; Components: ruby
Filename: "{cmd}"; Parameters: "/C C:\Ruby193\bin\gem install --no-rdoc --no-ri deepsecurity -v {#gemVersion}"; StatusMsg: "{cm:installingGem}"; Components: deepsecurity_gem
; Flags: runhidden

[CustomMessages]
en.fullInstallation=Full Installation
en.customInstallation=Custom Installation
en.installingRuby=Installing Ruby
en.installingGem=Installing gem
de.fullInstallation=Komplette Installation
de.customInstallation=Angepasste Installation
de.installingRuby=Installiere Ruby
de.installingGem=Installiere gem

[ISSI]
; #define ISSI_UnZip1 gemZipFilename
#define ISSI_IncludePath "C:\ISSI"
#include ISSI_IncludePath+"\_issi.isi"
; include "C:\Program Files\Sherlock Software\InnoTools\Downloader\it_download.iss";

;#include ReadReg(HKEY_LOCAL_MACHINE,'Software\Sherlock Software\InnoTools\Downloader','ScriptPath','');

[Tasks]

[Code]
var
  FilesDownloaded: Boolean;

procedure isxdl_AddFile(URL, Filename: AnsiString);
external 'isxdl_AddFile@files:isxdl.dll stdcall';
function isxdl_DownloadFiles(hWnd: Integer): Integer;
external 'isxdl_DownloadFiles@files:isxdl.dll stdcall';
function isxdl_SetOption(Option, Value: AnsiString): Integer;
external 'isxdl_SetOption@files:isxdl.dll stdcall';

procedure DownloadFiles(Ruby: Boolean);
var
  hWnd: Integer;
  URL, FileName: String;
begin
  isxdl_SetOption('label', 'Downloading extra files');
  isxdl_SetOption('description', 'Please wait while Setup is downloading extra files to your computer.');

  try
    FileName := ExpandConstant('{tmp}\WizModernSmallImage-IS.bmp');
    if not FileExists(FileName) then
      ExtractTemporaryFile(ExtractFileName(FileName));
    isxdl_SetOption('smallwizardimage', FileName);
  except
  end;

  //turn off isxdl resume so it won't leave partially downloaded files behind
  //resuming wouldn't help anyway since we're going to download to {tmp}
  isxdl_SetOption('resume', 'false');

  hWnd := StrToInt(ExpandConstant('{wizardhwnd}'));

  if Ruby then begin
    URL := '{#rubyUrl}';
    FileName := ExpandConstant('{tmp}\{#rubyFilename}');
    isxdl_AddFile(URL, FileName);
  end;

  if isxdl_DownloadFiles(hWnd) <> 0 then
    FilesDownloaded := True
  else
    SuppressibleMsgBox('Setup could not download the extra files. Try again later or download and install the extra files manually.' + #13#13 + 'Setup will now continue installing normally.', mbError, mb_Ok, idOk);
end;

function PrepareToInstall(var NeedsRestart: Boolean): String;
var
  downloadRuby: Boolean;
begin
  downloadRuby := IsComponentSelected('ruby');
  DownloadFiles(downloadRuby);
  Result := '';
end;

#define MyAppVer "0.0.16.0" ; define variable
#define MyAppVerText "0.0.16.0" ; define variable
#define MyAppCopyright "Udo Schneider <Udo_Schneider@trendmicro.de>"
#define MyAppCompany "Trend Micro"
#define MyAppName "dsc"

; #define gemVersion "0.0.16"
; #define gemFilename "deepsecurity-"+gemVersion+".gem"

; #define rubyVersion "1.9.3-p392"
#define rubyFilename "rubyinstaller-"+rubyVersion+".exe"
#define rubyUrl = "http://rubyforge.org/frs/download.php/76798/rubyinstaller-"+rubyVersion+".exe"

[Setup]
DefaultDirName={pf}\{#MyAppCompany}\{#MyAppName}
InternalCompressLevel=ultra
; OutputDir={#BaseDir}
; SourceDir={#BaseDir}
SolidCompression=true
AppCopyright=Copyright  {#MyAppCopyright}
AppName={#MyAppName}
AppVerName={#MyAppName} {#MyAppVerText}
ShowLanguageDialog=yes
DefaultGroupName={#MyAppCompany}\{#MyAppName}
AppID=84EDC400-BEB5-446E-90F8-6A9FBF89C3CD
Uninstallable=false
OutputBaseFilename={#MyAppName}_setup_{#MyAppVerText}
;WizardImageFile=Sources\WizardBigImage.bmp
;WizardSmallImageFile=Sources\WizardSmallImage.bmp
WizardImageFile=compiler:wizmodernimage-IS.bmp
WizardSmallImageFile=compiler:wizmodernsmallimage-IS.bmp
VersionInfoVersion={#MyAppVer}
VersionInfoCompany={#MyAppCompany}
VersionInfoDescription={#MyAppName} Setup
VersionInfoTextVersion={#MyAppVerText}
VersionInfoCopyright={#MyAppCopyright}
AppPublisher={#MyAppCompany}
AppPublisherURL=http://www.trendmicro.de/
AppSupportURL=http://www.trendmicro.de/
AppVersion={#MyAppVerText}
UninstallDisplayName={#MyAppName}
AppContact={#MyAppCompany}
AppSupportPhone=+49 (811) 88 99 0 698
ChangesAssociations=true
RestartIfNeededByRun=false

[Types]
Name: full; Description: {cm:fullInstallation}
Name: custom; Description: {cm:customInstallation}; Flags: iscustom

[Components]
Name: deepsecurity_gem; Description: deepsecurity gem ({#gemVersion}); Types: custom full
Name: ruby; Description: Ruby ({#rubyVersion}); Types: custom full; ExtraDiskSpaceRequired: 72204063

[Files]
Source: "isxdl.dll"; Flags: dontcopy
Source: "WizModernImage.bmp"; DestDir: "{app}"; Flags: ignoreversion
Source: "WizModernImage-IS.bmp"; DestDir: "{app}"; Flags: ignoreversion
Source: "WizModernSmallImage.bmp"; DestDir: "{app}"; Flags: ignoreversion
Source: "WizModernSmallImage-IS.bmp"; DestDir: "{app}"; Flags: ignoreversion

[Icons]

[Languages]
Name: en; MessagesFile: compiler:Default.isl
Name: de; MessagesFile: compiler:Languages\German.isl

[Run]
Filename: "{tmp}\{#rubyFilename}"; Parameters: "/SILENT /TASKS=""MODPATH"""; StatusMsg: "{cm:installingRuby}"; Components: ruby
Filename: "{cmd}"; Parameters: "/C C:\Ruby193\bin\gem install --no-rdoc --no-ri deepsecurity -v {#gemVersion}"; StatusMsg: "{cm:installingGem}"; Components: deepsecurity_gem
; Flags: runhidden

[CustomMessages]
en.fullInstallation=Full Installation
en.customInstallation=Custom Installation
en.installingRuby=Installing Ruby
en.installingGem=Installing gem
de.fullInstallation=Komplette Installation
de.customInstallation=Angepasste Installation
de.installingRuby=Installiere Ruby
de.installingGem=Installiere gem

[ISSI]
; #define ISSI_UnZip1 gemZipFilename
#define ISSI_IncludePath "C:\ISSI"
#include ISSI_IncludePath+"\_issi.isi"
; include "C:\Program Files\Sherlock Software\InnoTools\Downloader\it_download.iss";

;#include ReadReg(HKEY_LOCAL_MACHINE,'Software\Sherlock Software\InnoTools\Downloader','ScriptPath','');

[Tasks]

[Code]
var
  FilesDownloaded: Boolean;

procedure isxdl_AddFile(URL, Filename: AnsiString);
external 'isxdl_AddFile@files:isxdl.dll stdcall';
function isxdl_DownloadFiles(hWnd: Integer): Integer;
external 'isxdl_DownloadFiles@files:isxdl.dll stdcall';
function isxdl_SetOption(Option, Value: AnsiString): Integer;
external 'isxdl_SetOption@files:isxdl.dll stdcall';

procedure DownloadFiles(Ruby: Boolean);
var
  hWnd: Integer;
  URL, FileName: String;
begin
  isxdl_SetOption('label', 'Downloading extra files');
  isxdl_SetOption('description', 'Please wait while Setup is downloading extra files to your computer.');

  try
    FileName := ExpandConstant('{tmp}\WizModernSmallImage-IS.bmp');
    if not FileExists(FileName) then
      ExtractTemporaryFile(ExtractFileName(FileName));
    isxdl_SetOption('smallwizardimage', FileName);
  except
  end;

  //turn off isxdl resume so it won't leave partially downloaded files behind
  //resuming wouldn't help anyway since we're going to download to {tmp}
  isxdl_SetOption('resume', 'false');

  hWnd := StrToInt(ExpandConstant('{wizardhwnd}'));

  if Ruby then begin
    URL := '{#rubyUrl}';
    FileName := ExpandConstant('{tmp}\{#rubyFilename}');
    isxdl_AddFile(URL, FileName);
  end;

  if isxdl_DownloadFiles(hWnd) <> 0 then
    FilesDownloaded := True
  else
    SuppressibleMsgBox('Setup could not download the extra files. Try again later or download and install the extra files manually.' + #13#13 + 'Setup will now continue installing normally.', mbError, mb_Ok, idOk);
end;

function PrepareToInstall(var NeedsRestart: Boolean): String;
var
  downloadRuby: Boolean;
begin
  downloadRuby := IsComponentSelected('ruby');
  DownloadFiles(downloadRuby);
  Result := '';
end;


Win32: Remove workaround for bug #906 (now fixed)

;For automation purposes it is highly recommended to copy the files from
;\tools\windows\ to the directory that contains the win32 distribution files!

;IsRelease = yes will create a setup file named after the current version of mGBA.
;IsRelease = no will create a setup fille named mGBA-setup-latest-win32.exe.
#define IsRelease = yes

#define VerMajor
#define VerMinor
#define VerRev
#define VerBuild
#define FullVersion=ParseVersion('mGBA.exe', VerMajor, VerMinor, VerRev, VerBuild)
#define AppVer = Str(VerMajor) + "." + Str(VerMinor) + "." + Str(VerRev)

[Setup]
SourceDir=.\
SetupIconFile=mgba-setupiconfile.ico
WizardImageFile=mgba-wizardimagefile.bmp

AppName=mGBA
AppVersion={#AppVer}
AppPublisher=Jeffrey Pfau
AppPublisherURL=https://mgba.io
AppSupportURL=https://mgba.io
AppUpdatesURL=https://mgba.io
AppReadmeFile=README.html
OutputDir=.\
DefaultDirName={pf}\mGBA
DefaultGroupName=mGBA
AllowNoIcons=yes
DirExistsWarning=no
ChangesAssociations=True
AppendDefaultDirName=False
UninstallDisplayIcon={app}\mGBA.exe
MinVersion=0,6.0
AlwaysShowDirOnReadyPage=True
UsePreviousSetupType=True
UsePreviousTasks=True
AlwaysShowGroupOnReadyPage=True
LicenseFile=LICENSE.txt
#if IsRelease==yes;
  AppVerName=mGBA {#AppVer}
  OutputBaseFilename=mGBA-{#AppVer}-win32
#elif IsRelease==no;
  AppVerName=mGBA (Development build)
  OutputBaseFilename=mGBA-setup-latest-win32
  #endif
UsePreviousLanguage=False
DisableWelcomePage=False
VersionInfoDescription=mGBA is an open-source Game Boy Advance emulator
VersionInfoCopyright= 20132017 Jeffrey Pfau
VersionInfoProductName=mGBA
VersionInfoVersion={#AppVer}
Compression=lzma2/ultra64
SolidCompression=True
VersionInfoTextVersion={#AppVer}
VersionInfoProductVersion={#AppVer}
VersionInfoProductTextVersion={#AppVer}

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
Name: "german"; MessagesFile: "compiler:Languages\German.isl"
Name: "italian"; MessagesFile: "compiler:Languages\Italian.isl"
Name: "spanish"; MessagesFile: "compiler:Languages\Spanish.isl"

[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"
Name: "gbfileassoc"; Description: "{cm:AssocFileExtension,mGBA,Game Boy}"; GroupDescription: "{cm:FileAssoc}"
Name: "gbcfileassoc"; Description: "{cm:AssocFileExtension,mGBA,Game Boy Color}"; GroupDescription: "{cm:FileAssoc}"
Name: "gbafileassoc"; Description: "{cm:AssocFileExtension,mGBA,Game Boy Advance}"; GroupDescription: "{cm:FileAssoc}"

[Files]
Source: "mGBA.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "CHANGES.txt"; DestDir: "{app}\"; Flags: ignoreversion
Source: "LICENSE.txt"; DestDir: "{app}\"; Flags: ignoreversion
Source: "mGBA.exe"; DestDir: "{app}\"; Flags: ignoreversion
Source: "nointro.dat"; DestDir: "{app}\"; Flags: ignoreversion
Source: "README.html"; DestDir: "{app}\"; Flags: ignoreversion
Source: "shaders\agb001.shader\agb001.fs"; DestDir: "{app}\shaders\agb001.shader\"; Flags: ignoreversion
Source: "shaders\agb001.shader\manifest.ini"; DestDir: "{app}\shaders\agb001.shader\"; Flags: ignoreversion
Source: "shaders\ags001.shader\ags001-light.fs"; DestDir: "{app}\shaders\ags001.shader\"; Flags: ignoreversion
Source: "shaders\ags001.shader\ags001.fs"; DestDir: "{app}\shaders\ags001.shader\"; Flags: ignoreversion
Source: "shaders\ags001.shader\manifest.ini"; DestDir: "{app}\shaders\ags001.shader\"; Flags: ignoreversion
Source: "shaders\fish.shader\fish.fs"; DestDir: "{app}\shaders\fish.shader\"; Flags: ignoreversion
Source: "shaders\fish.shader\manifest.ini"; DestDir: "{app}\shaders\fish.shader\"; Flags: ignoreversion
Source: "shaders\gba-color.shader\gba-color.fs"; DestDir: "{app}\shaders\gba-color.shader\"; Flags: ignoreversion
Source: "shaders\gba-color.shader\manifest.ini"; DestDir: "{app}\shaders\gba-color.shader\"; Flags: ignoreversion
Source: "shaders\lcd.shader\lcd.fs"; DestDir: "{app}\shaders\lcd.shader\"; Flags: ignoreversion
Source: "shaders\lcd.shader\manifest.ini"; DestDir: "{app}\shaders\lcd.shader\"; Flags: ignoreversion
Source: "shaders\motion_blur.shader\manifest.ini"; DestDir: "{app}\shaders\motion_blur.shader\"; Flags: ignoreversion
Source: "shaders\motion_blur.shader\motion_blur.fs"; DestDir: "{app}\shaders\motion_blur.shader\"; Flags: ignoreversion
Source: "shaders\pixelate.shader\manifest.ini"; DestDir: "{app}\shaders\pixelate.shader\"; Flags: ignoreversion
Source: "shaders\scanlines.shader\manifest.ini"; DestDir: "{app}\shaders\scanlines.shader\"; Flags: ignoreversion
Source: "shaders\scanlines.shader\scanlines.fs"; DestDir: "{app}\shaders\scanlines.shader\"; Flags: ignoreversion
Source: "shaders\soften.shader\manifest.ini"; DestDir: "{app}\shaders\soften.shader\"; Flags: ignoreversion
Source: "shaders\soften.shader\soften.fs"; DestDir: "{app}\shaders\soften.shader\"; Flags: ignoreversion
Source: "shaders\vba_pixelate.shader\manifest.ini"; DestDir: "{app}\shaders\vba_pixelate.shader\"; Flags: ignoreversion
Source: "shaders\vba_pixelate.shader\vba_pixelate.fs"; DestDir: "{app}\shaders\vba_pixelate.shader\"; Flags: ignoreversion
Source: "shaders\vignette.shader\manifest.ini"; DestDir: "{app}\shaders\vignette.shader\"; Flags: ignoreversion
Source: "shaders\vignette.shader\vignette.fs"; DestDir: "{app}\shaders\vignette.shader\"; Flags: ignoreversion
Source: "shaders\wiiu.shader\manifest.ini"; DestDir: "{app}\shaders\wiiu.shader\"; Flags: ignoreversion
Source: "shaders\wiiu.shader\wiiu.fs"; DestDir: "{app}\shaders\wiiu.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv2.shader\manifest.ini"; DestDir: "{app}\shaders\xbr-lv2.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv2.shader\xbr.fs"; DestDir: "{app}\shaders\xbr-lv2.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv2.shader\xbr.vs"; DestDir: "{app}\shaders\xbr-lv2.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv3.shader\manifest.ini"; DestDir: "{app}\shaders\xbr-lv3.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv3.shader\xbr.fs"; DestDir: "{app}\shaders\xbr-lv3.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv3.shader\xbr.vs"; DestDir: "{app}\shaders\xbr-lv3.shader\"; Flags: ignoreversion
Source: "third-party\LICENSE.blip-buf"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.ffmpeg"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.imagemagick"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.inih"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.lame"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.libvpx"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.opus"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.qt5"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.sdl2"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.x264"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.xvid"; DestDir: "{app}\third-party\"; Flags: ignoreversion

[Icons]
Name: "{commonstartmenu}\mGBA"; Filename: "{app}\mGBA.exe"
Name: "{commondesktop}\mGBA"; Filename: "{app}\mGBA.exe"; Tasks: desktopicon

[Run]
Filename: "{app}\mGBA.exe"; Description: "{cm:LaunchProgram,mGBA}"; Flags: nowait postinstall skipifsilent
Filename: "{app}\README.html"; Description: "View README"; Flags: nowait postinstall skipifsilent unchecked; Languages: english
Filename: "{app}\README.html"; Description: "View README"; Flags: nowait postinstall skipifsilent unchecked; Languages: italian
Filename: "{app}\README.html"; Description: "View README"; Flags: nowait postinstall skipifsilent unchecked; Languages: spanish
Filename: "{app}\README.html"; Description: "README anzeigen"; Flags: nowait postinstall skipifsilent unchecked; Languages: german
Filename: "{app}\CHANGES.txt"; Description: "View Changelog"; Flags: nowait postinstall skipifsilent unchecked; Languages: english
Filename: "{app}\CHANGES.txt"; Description: "View Changelog"; Flags: nowait postinstall skipifsilent unchecked; Languages: italian
Filename: "{app}\CHANGES.txt"; Description: "View Changelog"; Flags: nowait postinstall skipifsilent unchecked; Languages: spanish
Filename: "{app}\CHANGES.txt"; Description: "Changelog anzeigen"; Flags: nowait postinstall skipifsilent unchecked; Languages: german

[Dirs]
Name: "{app}\shaders\"
Name: "{app}\shaders\agb001.shader\"
Name: "{app}\shaders\ags001.shader\"
Name: "{app}\shaders\fish.shader\"
Name: "{app}\shaders\gba-color.shader\"
Name: "{app}\shaders\lcd.shader\"
Name: "{app}\shaders\motion_blur.shader\"
Name: "{app}\shaders\pixelate.shader\"
Name: "{app}\shaders\scanlines.shader\"
Name: "{app}\shaders\soften.shader\"
Name: "{app}\shaders\vba_pixelate.shader\"
Name: "{app}\shaders\vignette.shader\"
Name: "{app}\shaders\wiiu.shader\"
Name: "{app}\shaders\xbr-lv2.shader\"
Name: "{app}\shaders\xbr-lv3.shader\"
Name: "{app}\third-party\"

[CustomMessages]
english.FileAssoc=Register file associations
italian.FileAssoc=Register file associations
spanish.FileAssoc=Register file associations
german.FileAssoc=Dateierweiterungen registrieren

[Registry]
Root: HKCR; Subkey: ".gb"; ValueType: string; ValueName: ""; ValueData: "Game Boy ROM"; Flags: uninsdeletevalue; Tasks: gbfileassoc
Root: HKCR; Subkey: ".gb\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\mGBA.exe,0"; Tasks: gbfileassoc
Root: HKCR; Subkey: ".gb\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\mGBA.exe"" ""%1"""; Tasks: gbfileassoc
Root: HKCR; Subkey: ".gbc"; ValueType: string; ValueName: ""; ValueData: "Game Boy Color ROM"; Flags: uninsdeletevalue; Tasks: gbcfileassoc
Root: HKCR; Subkey: ".gbc\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\mGBA.exe,0"; Tasks: gbcfileassoc
Root: HKCR; Subkey: ".gbc\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\mGBA.exe"" ""%1"""; Tasks: gbcfileassoc
Root: HKCR; Subkey: ".gba"; ValueType: string; ValueName: ""; ValueData: "Game Boy Advance ROM"; Flags: uninsdeletevalue; Tasks: gbafileassoc
Root: HKCR; Subkey: ".gba\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\mGBA.exe,0"; Tasks: gbafileassoc
Root: HKCR; Subkey: ".gba\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\mGBA.exe"" ""%1"""; Tasks: gbafileassoc

;For automation purposes it is highly recommended to copy the files from
;\tools\windows\ to the directory that contains the win32 distribution files!

;IsRelease = yes will create a setup file named after the current version of mGBA.
;IsRelease = no will create a setup fille named mGBA-setup-latest-win32.exe.
#define IsRelease = yes

#define VerMajor
#define VerMinor
#define VerRev
#define VerBuild
#define FullVersion=ParseVersion('mGBA.exe', VerMajor, VerMinor, VerRev, VerBuild)
#define AppVer = Str(VerMajor) + "." + Str(VerMinor) + "." + Str(VerRev)

[Setup]
SourceDir=.\
SetupIconFile=mgba-setupiconfile.ico
WizardImageFile=mgba-wizardimagefile.bmp

AppName=mGBA
AppVersion={#AppVer}
AppPublisher=Jeffrey Pfau
AppPublisherURL=https://mgba.io
AppSupportURL=https://mgba.io
AppUpdatesURL=https://mgba.io
AppReadmeFile=README.html
OutputDir=.\
DefaultDirName={pf}\mGBA
DefaultGroupName=mGBA
AllowNoIcons=yes
DirExistsWarning=no
ChangesAssociations=True
AppendDefaultDirName=False
UninstallDisplayIcon={app}\mGBA.exe
MinVersion=0,6.0
AlwaysShowDirOnReadyPage=True
UsePreviousSetupType=True
UsePreviousTasks=True
AlwaysShowGroupOnReadyPage=True
LicenseFile=LICENSE.txt
#if IsRelease==yes;
  AppVerName=mGBA {#AppVer}
  OutputBaseFilename=mGBA-{#AppVer}-win32
#elif IsRelease==no;
  AppVerName=mGBA (Development build)
  OutputBaseFilename=mGBA-setup-latest-win32
  #endif
UsePreviousLanguage=False
DisableWelcomePage=False
VersionInfoDescription=mGBA is an open-source Game Boy Advance emulator
VersionInfoCopyright= 20132017 Jeffrey Pfau
VersionInfoProductName=mGBA
VersionInfoVersion={#AppVer}
Compression=lzma2/ultra64
SolidCompression=True
VersionInfoTextVersion={#AppVer}
VersionInfoProductVersion={#AppVer}
VersionInfoProductTextVersion={#AppVer}

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
Name: "german"; MessagesFile: "compiler:Languages\German.isl"
Name: "italian"; MessagesFile: "compiler:Languages\Italian.isl"
Name: "spanish"; MessagesFile: "compiler:Languages\Spanish.isl"

[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"
Name: "gbfileassoc"; Description: "{cm:AssocFileExtension,mGBA,Game Boy}"; GroupDescription: "{cm:FileAssoc}"
Name: "gbcfileassoc"; Description: "{cm:AssocFileExtension,mGBA,Game Boy Color}"; GroupDescription: "{cm:FileAssoc}"
Name: "gbafileassoc"; Description: "{cm:AssocFileExtension,mGBA,Game Boy Advance}"; GroupDescription: "{cm:FileAssoc}"

[Files]
Source: "mGBA.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "CHANGES.txt"; DestDir: "{app}\"; Flags: ignoreversion
Source: "LICENSE.txt"; DestDir: "{app}\"; Flags: ignoreversion
Source: "mGBA.exe"; DestDir: "{app}\"; Flags: ignoreversion
Source: "nointro.dat"; DestDir: "{app}\"; Flags: ignoreversion
Source: "README.html"; DestDir: "{app}\"; Flags: ignoreversion
Source: "shaders\agb001.shader\agb001.fs"; DestDir: "{app}\shaders\agb001.shader\"; Flags: ignoreversion
Source: "shaders\agb001.shader\manifest.ini"; DestDir: "{app}\shaders\agb001.shader\"; Flags: ignoreversion
Source: "shaders\ags001.shader\ags001-light.fs"; DestDir: "{app}\shaders\ags001.shader\"; Flags: ignoreversion
Source: "shaders\ags001.shader\ags001.fs"; DestDir: "{app}\shaders\ags001.shader\"; Flags: ignoreversion
Source: "shaders\ags001.shader\manifest.ini"; DestDir: "{app}\shaders\ags001.shader\"; Flags: ignoreversion
Source: "shaders\fish.shader\fish.fs"; DestDir: "{app}\shaders\fish.shader\"; Flags: ignoreversion
Source: "shaders\fish.shader\manifest.ini"; DestDir: "{app}\shaders\fish.shader\"; Flags: ignoreversion
Source: "shaders\gba-color.shader\gba-color.fs"; DestDir: "{app}\shaders\gba-color.shader\"; Flags: ignoreversion
Source: "shaders\gba-color.shader\manifest.ini"; DestDir: "{app}\shaders\gba-color.shader\"; Flags: ignoreversion
Source: "shaders\lcd.shader\lcd.fs"; DestDir: "{app}\shaders\lcd.shader\"; Flags: ignoreversion
Source: "shaders\lcd.shader\manifest.ini"; DestDir: "{app}\shaders\lcd.shader\"; Flags: ignoreversion
Source: "shaders\motion_blur.shader\manifest.ini"; DestDir: "{app}\shaders\motion_blur.shader\"; Flags: ignoreversion
Source: "shaders\motion_blur.shader\motion_blur.fs"; DestDir: "{app}\shaders\motion_blur.shader\"; Flags: ignoreversion
Source: "shaders\pixelate.shader\manifest.ini"; DestDir: "{app}\shaders\pixelate.shader\"; Flags: ignoreversion
Source: "shaders\scanlines.shader\manifest.ini"; DestDir: "{app}\shaders\scanlines.shader\"; Flags: ignoreversion
Source: "shaders\scanlines.shader\scanlines.fs"; DestDir: "{app}\shaders\scanlines.shader\"; Flags: ignoreversion
Source: "shaders\soften.shader\manifest.ini"; DestDir: "{app}\shaders\soften.shader\"; Flags: ignoreversion
Source: "shaders\soften.shader\soften.fs"; DestDir: "{app}\shaders\soften.shader\"; Flags: ignoreversion
Source: "shaders\vba_pixelate.shader\manifest.ini"; DestDir: "{app}\shaders\vba_pixelate.shader\"; Flags: ignoreversion
Source: "shaders\vba_pixelate.shader\vba_pixelate.fs"; DestDir: "{app}\shaders\vba_pixelate.shader\"; Flags: ignoreversion
Source: "shaders\vignette.shader\manifest.ini"; DestDir: "{app}\shaders\vignette.shader\"; Flags: ignoreversion
Source: "shaders\vignette.shader\vignette.fs"; DestDir: "{app}\shaders\vignette.shader\"; Flags: ignoreversion
Source: "shaders\wiiu.shader\manifest.ini"; DestDir: "{app}\shaders\wiiu.shader\"; Flags: ignoreversion
Source: "shaders\wiiu.shader\wiiu.fs"; DestDir: "{app}\shaders\wiiu.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv2.shader\manifest.ini"; DestDir: "{app}\shaders\xbr-lv2.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv2.shader\xbr.fs"; DestDir: "{app}\shaders\xbr-lv2.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv2.shader\xbr.vs"; DestDir: "{app}\shaders\xbr-lv2.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv3.shader\manifest.ini"; DestDir: "{app}\shaders\xbr-lv3.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv3.shader\xbr.fs"; DestDir: "{app}\shaders\xbr-lv3.shader\"; Flags: ignoreversion
Source: "shaders\xbr-lv3.shader\xbr.vs"; DestDir: "{app}\shaders\xbr-lv3.shader\"; Flags: ignoreversion
Source: "third-party\LICENSE.blip-buf"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.ffmpeg"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.imagemagick"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.inih"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.lame"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.libvpx"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.opus"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.qt5"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.sdl2"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.x264"; DestDir: "{app}\third-party\"; Flags: ignoreversion
Source: "third-party\LICENSE.xvid"; DestDir: "{app}\third-party\"; Flags: ignoreversion

[Icons]
Name: "{commonstartmenu}\mGBA"; Filename: "{app}\mGBA.exe"
Name: "{commondesktop}\mGBA"; Filename: "{app}\mGBA.exe"; Tasks: desktopicon

[Run]
Filename: "{app}\mGBA.exe"; Description: "{cm:LaunchProgram,mGBA}"; Flags: nowait postinstall skipifsilent
Filename: "{app}\README.html"; Description: "View README"; Flags: nowait postinstall skipifsilent unchecked; Languages: english
Filename: "{app}\README.html"; Description: "View README"; Flags: nowait postinstall skipifsilent unchecked; Languages: italian
Filename: "{app}\README.html"; Description: "View README"; Flags: nowait postinstall skipifsilent unchecked; Languages: spanish
Filename: "{app}\README.html"; Description: "README anzeigen"; Flags: nowait postinstall skipifsilent unchecked; Languages: german
Filename: "{app}\CHANGES.txt"; Description: "View Changelog"; Flags: nowait postinstall skipifsilent unchecked; Languages: english
Filename: "{app}\CHANGES.txt"; Description: "View Changelog"; Flags: nowait postinstall skipifsilent unchecked; Languages: italian
Filename: "{app}\CHANGES.txt"; Description: "View Changelog"; Flags: nowait postinstall skipifsilent unchecked; Languages: spanish
Filename: "{app}\CHANGES.txt"; Description: "Changelog anzeigen"; Flags: nowait postinstall skipifsilent unchecked; Languages: german

[Dirs]
Name: "{app}\shaders\"
Name: "{app}\shaders\agb001.shader\"
Name: "{app}\shaders\ags001.shader\"
Name: "{app}\shaders\fish.shader\"
Name: "{app}\shaders\gba-color.shader\"
Name: "{app}\shaders\lcd.shader\"
Name: "{app}\shaders\motion_blur.shader\"
Name: "{app}\shaders\pixelate.shader\"
Name: "{app}\shaders\scanlines.shader\"
Name: "{app}\shaders\soften.shader\"
Name: "{app}\shaders\vba_pixelate.shader\"
Name: "{app}\shaders\vignette.shader\"
Name: "{app}\shaders\wiiu.shader\"
Name: "{app}\shaders\xbr-lv2.shader\"
Name: "{app}\shaders\xbr-lv3.shader\"
Name: "{app}\third-party\"

[CustomMessages]
english.FileAssoc=Register file associations
italian.FileAssoc=Register file associations
spanish.FileAssoc=Register file associations
german.FileAssoc=Dateierweiterungen registrieren

[INI]
Filename: "{userappdata}\mGBA\qt.ini"; Section: "General"; Key: "language"; String: "en"; Languages: english
Filename: "{userappdata}\mGBA\qt.ini"; Section: "General"; Key: "language"; String: "de"; Languages: german
Filename: "{userappdata}\mGBA\qt.ini"; Section: "General"; Key: "language"; String: "es"; Languages: spanish
Filename: "{userappdata}\mGBA\qt.ini"; Section: "General"; Key: "language"; String: "it"; Languages: italian

[Registry]
Root: HKCR; Subkey: ".gb"; ValueType: string; ValueName: ""; ValueData: "Game Boy ROM"; Flags: uninsdeletevalue; Tasks: gbfileassoc
Root: HKCR; Subkey: ".gb\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\mGBA.exe,0"; Tasks: gbfileassoc
Root: HKCR; Subkey: ".gb\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\mGBA.exe"" ""%1"""; Tasks: gbfileassoc
Root: HKCR; Subkey: ".gbc"; ValueType: string; ValueName: ""; ValueData: "Game Boy Color ROM"; Flags: uninsdeletevalue; Tasks: gbcfileassoc
Root: HKCR; Subkey: ".gbc\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\mGBA.exe,0"; Tasks: gbcfileassoc
Root: HKCR; Subkey: ".gbc\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\mGBA.exe"" ""%1"""; Tasks: gbcfileassoc
Root: HKCR; Subkey: ".gba"; ValueType: string; ValueName: ""; ValueData: "Game Boy Advance ROM"; Flags: uninsdeletevalue; Tasks: gbafileassoc
Root: HKCR; Subkey: ".gba\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\mGBA.exe,0"; Tasks: gbafileassoc
Root: HKCR; Subkey: ".gba\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\mGBA.exe"" ""%1"""; Tasks: gbafileassoc


Update more version numbers.

Update more version numbers.

; Basic setup script for the Inno Setep installer builder.  For more
; information on the free installer builder, see www.jrsoftware.org.
;
; This script was contributed by Tim Peters.
; The current version is used with Inno Setup 2.0.19.

[Setup]
AppName=expat
AppId=expat
AppVersion=1.95.6
AppVerName=expat 1.95.6
AppCopyright=Copyright  1998-2002 Thai Open Source Software Center, Clark Cooper, and the Expat maintainers
DefaultDirName={sd}\Expat-1.95.6
AppPublisher=The Expat Developers
AppPublisherURL=http://www.libexpat.org/
AppSupportURL=http://www.libexpat.org/
AppUpdatesURL=http://www.libexpat.org/
UninstallDisplayName=Expat XML Parser (version 1.95.6)
UninstallFilesDir={app}\Uninstall

Compression=bzip/9
SourceDir=..
OutputDir=win32
DisableStartupPrompt=yes
AllowNoIcons=yes
DisableProgramGroupPage=yes
DisableReadyPage=yes

[Files]
CopyMode: alwaysoverwrite; Source: xmlwf\Release\*.exe;        DestDir: "{app}"
CopyMode: alwaysoverwrite; Source: win32\MANIFEST.txt;         DestDir: "{app}"
CopyMode: alwaysoverwrite; Source: Changes;                    DestDir: "{app}"; DestName: Changes.txt
CopyMode: alwaysoverwrite; Source: COPYING;                    DestDir: "{app}"; DestName: COPYING.txt
CopyMode: alwaysoverwrite; Source: README;                     DestDir: "{app}"; DestName: README.txt
CopyMode: alwaysoverwrite; Source: doc\*.html;                 DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: doc\*.css;                  DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: doc\*.png;                  DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: lib\Release\*.dll;          DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release\*.lib;          DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release-w\*.dll;        DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release-w\*.lib;        DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release_static\*.lib;   DestDir: "{app}\StaticLibs"
CopyMode: alwaysoverwrite; Source: lib\Release-w_static\*.lib; DestDir: "{app}\StaticLibs"
CopyMode: alwaysoverwrite; Source: expat.dsw;                  DestDir: "{app}\Source"
CopyMode: alwaysoverwrite; Source: bcb5\*.*;                   DestDir: "{app}\Source\bcb5"
CopyMode: alwaysoverwrite; Source: lib\*.c;                    DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: lib\*.h;                    DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: lib\*.dsp;                  DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: examples\*.c;               DestDir: "{app}\Source\examples"
CopyMode: alwaysoverwrite; Source: examples\*.dsp;             DestDir: "{app}\Source\examples"
CopyMode: alwaysoverwrite; Source: tests\*.c;                  DestDir: "{app}\Source\tests"
CopyMode: alwaysoverwrite; Source: tests\*.h;                  DestDir: "{app}\Source\tests"
CopyMode: alwaysoverwrite; Source: tests\README.txt;           DestDir: "{app}\Source\tests"
CopyMode: alwaysoverwrite; Source: xmlwf\*.c*;                 DestDir: "{app}\Source\xmlwf"
CopyMode: alwaysoverwrite; Source: xmlwf\*.h;                  DestDir: "{app}\Source\xmlwf"
CopyMode: alwaysoverwrite; Source: xmlwf\*.dsp;                DestDir: "{app}\Source\xmlwf"

[Messages]
WelcomeLabel1=Welcome to the Expat XML Parser Setup Wizard
WelcomeLabel2=This will install [name/ver] on your computer.%n%nExpat is an XML parser with a C-language API, and is primarily made available to allow developers to build applications which use XML using a portable API and fast implementation.%n%nIt is strongly recommended that you close all other applications you have running before continuing. This will help prevent any conflicts during the installation process.

; Basic setup script for the Inno Setep installer builder.  For more
; information on the free installer builder, see www.jrsoftware.org.
;
; This script was contributed by Tim Peters.
; The current version is used with Inno Setup 2.0.19.

[Setup]
AppName=expat
AppId=expat
AppVersion=1.95.5
AppVerName=expat 1.95.5
AppCopyright=Copyright  1998-2002 Thai Open Source Software Center, Clark Cooper, and the Expat maintainers
DefaultDirName={sd}\Expat-1.95.5
AppPublisher=The Expat Developers
AppPublisherURL=http://www.libexpat.org/
AppSupportURL=http://www.libexpat.org/
AppUpdatesURL=http://www.libexpat.org/
UninstallDisplayName=Expat XML Parser (version 1.95.5)
UninstallFilesDir={app}\Uninstall

Compression=bzip/9
SourceDir=..
OutputDir=win32
DisableStartupPrompt=yes
AllowNoIcons=yes
DisableProgramGroupPage=yes
DisableReadyPage=yes

[Files]
CopyMode: alwaysoverwrite; Source: xmlwf\Release\*.exe;        DestDir: "{app}"
CopyMode: alwaysoverwrite; Source: win32\MANIFEST.txt;         DestDir: "{app}"
CopyMode: alwaysoverwrite; Source: Changes;                    DestDir: "{app}"; DestName: Changes.txt
CopyMode: alwaysoverwrite; Source: COPYING;                    DestDir: "{app}"; DestName: COPYING.txt
CopyMode: alwaysoverwrite; Source: README;                     DestDir: "{app}"; DestName: README.txt
CopyMode: alwaysoverwrite; Source: doc\*.html;                 DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: doc\*.css;                  DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: doc\*.png;                  DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: lib\Release\*.dll;          DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release\*.lib;          DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release-w\*.dll;        DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release-w\*.lib;        DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release_static\*.lib;   DestDir: "{app}\StaticLibs"
CopyMode: alwaysoverwrite; Source: lib\Release-w_static\*.lib; DestDir: "{app}\StaticLibs"
CopyMode: alwaysoverwrite; Source: expat.dsw;                  DestDir: "{app}\Source"
CopyMode: alwaysoverwrite; Source: bcb5\*.*;                   DestDir: "{app}\Source\bcb5"
CopyMode: alwaysoverwrite; Source: lib\*.c;                    DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: lib\*.h;                    DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: lib\*.dsp;                  DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: examples\*.c;               DestDir: "{app}\Source\examples"
CopyMode: alwaysoverwrite; Source: examples\*.dsp;             DestDir: "{app}\Source\examples"
CopyMode: alwaysoverwrite; Source: tests\*.c;                  DestDir: "{app}\Source\tests"
CopyMode: alwaysoverwrite; Source: tests\*.h;                  DestDir: "{app}\Source\tests"
CopyMode: alwaysoverwrite; Source: tests\README.txt;           DestDir: "{app}\Source\tests"
CopyMode: alwaysoverwrite; Source: xmlwf\*.c*;                 DestDir: "{app}\Source\xmlwf"
CopyMode: alwaysoverwrite; Source: xmlwf\*.h;                  DestDir: "{app}\Source\xmlwf"
CopyMode: alwaysoverwrite; Source: xmlwf\*.dsp;                DestDir: "{app}\Source\xmlwf"

[Messages]
WelcomeLabel1=Welcome to the Expat XML Parser Setup Wizard
WelcomeLabel2=This will install [name/ver] on your computer.%n%nExpat is an XML parser with a C-language API, and is primarily made available to allow developers to build applications which use XML using a portable API and fast implementation.%n%nIt is strongly recommended that you close all other applications you have running before continuing. This will help prevent any conflicts during the installation process.


Changes so that we can actually build an installer, and fix the URLs.

; Basic setup script for the Inno Setep installer builder.  For more
; information on the free installer builder, see www.jrsoftware.org.
;
; This script was contributed by Tim Peters.

[Setup]
AppName=expat
AppId=expat
AppVersion=1.95.2
AppVerName=expat 1.95.2
AppCopyright=Copyright  1998-2001 Thai Open Source Software Center and Clark Cooper
DefaultDirName={sd}\Expat-1.95.2
AppPublisher=The Expat Developers
AppPublisherURL=http://expat.sourceforge.net/
AppSupportURL=http://expat.sourceforge.net/
AppUpdatesURL=http://expat.sourceforge.net/
SourceDir=..

DisableStartupPrompt=yes
AllowNoIcons=yes
DisableProgramGroupPage=yes
DisableReadyPage=yes

[Files]
Source: lib\*.c;             DestDir: "{app}\Source";  CopyMode: alwaysoverwrite
Source: lib\*.h;             DestDir: "{app}\Source";  CopyMode: alwaysoverwrite
Source: lib\*.dsp;           DestDir: "{app}\Source";  CopyMode: alwaysoverwrite
Source: lib\Release\*.dll;   DestDir: "{app}\Libs";    CopyMode: alwaysoverwrite
Source: lib\Release\*.lib;   DestDir: "{app}\Libs";    CopyMode: alwaysoverwrite
Source: doc\*.html;          DestDir: "{app}\Doc";     CopyMode: alwaysoverwrite
Source: doc\*.css;           DestDir: "{app}\Doc";     CopyMode: alwaysoverwrite
Source: xmlwf\Release\*.exe; DestDir: "{app}";         CopyMode: alwaysoverwrite
Source: win32\MANIFEST.txt;  DestDir: "{app}";         CopyMode: alwaysoverwrite
Source: COPYING;             DestDir: "{app}";         CopyMode: alwaysoverwrite; DestName: COPYING.txt
Source: README;              DestDir: "{app}";         CopyMode: alwaysoverwrite; DestName: README.txt

;  Basic setup script for the Inno Setep installer builder.  For more
;  information on the free installer builder, see www.jrsoftware.org.
;
;  This script was contributed by Tim Peters.

[Setup]
AppName=expat
AppId=expat
AppVersion=1.95.2
AppVerName=expat 1.95.2
AppCopyright=Copyright  1998-2001 Thai Open Source Software Center and Clark Cooper
DefaultDirName={sd}\Expat-1.95.2
AppPublisher=PythonLabs at Zope Corporation
AppPublisherURL=http://www.python.org
AppSupportURL=http://www.python.org
AppUpdatesURL=http://www.python.org

DisableStartupPrompt=yes
AllowNoIcons=yes
DisableProgramGroupPage=yes
DisableReadyPage=yes

[Files]
Source: *.h;     DestDir: "{app}";  CopyMode: alwaysoverwrite
Source: *.dll;   DestDir: "{app}";  CopyMode: alwaysoverwrite
Source: *.lib;   DestDir: "{app}";  CopyMode: alwaysoverwrite
Source: *.html;  DestDir: "{app}";  CopyMode: alwaysoverwrite
Source: *.css;   DestDir: "{app}";  CopyMode: alwaysoverwrite
Source: *.exe;   DestDir: "{app}";  CopyMode: alwaysoverwrite
Source: COPYING; DestDir: "{app}";  DestName: COPYING.txt;  CopyMode: alwaysoverwrite
Source: README;  DestDir: "{app}";  DestName: README.txt;   CopyMode: alwaysoverwrite


New installer for the stand-alone  Chrono::PyEngine. This new version installs all PYD and PY and DLL files in a separate directory, it is up to the user to set PYTHONPATH (as in the full CMake build) . Note, the installer prompts the user if he wants PYTHONPATH to be set automatically (to be tested)

//
// PROJECT CHRONO - http://projectchrono.org
//
// Copyright (c) 2012 Alessandro Tasora
// Copyright (c) 2013 Project Chrono
// All rights reserved.
//
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file at the top level of the distribution
// and at http://projectchrono.org/license-chrono.txt.
//

#include "ModifyPath.iss"

#define MyAppName "ChronoPyEngine"
#define MyAppVersion "v2.0.8"
#define MyAppPublisher "Alessandro Tasora"
#define MyAppURL "http://www.chronoengine.info"
#define MyWin64PythonDir  "D:\build\chrono\bin\Release"
#define MyPythonVers "3.3"
#define MyChronoEngineSDK "C:\tasora\code\projectchrono\chrono"

[Setup]
ShowLanguageDialog=yes
UserInfoPage=no
AppName={#MyAppName}
AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\{#MyAppName}
DefaultGroupName={#MyAppName}
WizardImageFile=SetupModern20.bmp
WizardSmallImageFile=SetupModernSmall26.bmp
PrivilegesRequired=admin
;Compression=none
OutputDir=c:\tasora\lavori\data_chrono
OutputBaseFilename=ChronoPyEngine_{#MyAppVersion}
ArchitecturesInstallIn64BitMode=x64
ChangesEnvironment=yes
DisableProgramGroupPage=yes

[Files]
Source: {#MyChronoEngineSDK}\data\*; Excludes: "*\.svn,\mpi,\vehicle,\cascade"; DestDir: "{app}\data"; Flags: recursesubdirs createallsubdirs
Source: {#MyChronoEngineSDK}\src\demos\python\*; DestDir: "{app}\src\demos\python\"; Flags: recursesubdirs createallsubdirs

Source: {#MyWin64PythonDir}\_ChronoEngine_python_core.pyd; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\_ChronoEngine_python_postprocess.pyd; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\_ChronoEngine_python_irrlicht.pyd; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\_ChronoEngine_python_fea.pyd; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\ChronoEngine.dll; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\ChronoEngine_postprocess.dll; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\ChronoEngine_irrlicht.dll; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\ChronoEngine_fea.dll; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\Irrlicht.dll; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\ChronoEngine_python_core.py; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\ChronoEngine_python_postprocess.py; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\ChronoEngine_python_irrlicht.py; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\ChronoEngine_python_fea.py; DestDir: {app};  Flags: ignoreversion;  Check: myFoundWin64Python;

[Icons]
Name: "{group}\ProjectChrono"; Filename: "http://www.projectchrono.org"
Name: "{group}\Getting started"; Filename: "http://api.chrono.projectchrono.org/introduction_chrono_pyengine.html"
Name: "{group}\Demos"; Filename: "{app}\src\demos\python\"
Name: "{group}\Uninstall"; Filename: "{uninstallexe}"

[Registry]
Root: "HKCU"; Subkey: "Environment"; ValueType: string; ValueName: "PYTHONPATH"; ValueData: "{olddata};{app}"; Check: NeedsAddPath(ExpandConstant('{app}'));

[Code]
var
  DataDirPage: TInputDirWizardPage;
  RegisterPathPage: TWizardPage;
  InstallHelpCheckBox: TNewCheckBox;
  InstallHelpLabel: TLabel;
  mFoundWin32Python: Integer;
  mPathWin32Python: String;
  mPathWin32PythonLib: String;
  mPathWin32PythonDLLs: String;
  mFoundWin64Python: Integer;
  mPathWin64Python: String;
  mPathWin64PythonLib: String;
  mPathWin64PythonDLLs: String;

function myFoundWin32Python: Boolean;
begin
  Result := mFoundWin32Python =1;
end;
function myGetPathWin32Python(Param: String): String;
begin
  Result := mPathWin32Python;
end;
function myGetPathWin32PythonLib(Param: String): String;
begin
  Result := mPathWin32PythonLib;
end;
function myGetPathWin32PythonDLLs(Param: String): String;
begin
  Result := mPathWin32PythonDLLs;
end;
function myFoundWin64Python: Boolean;
begin
  Result := mFoundWin64Python =1;
end;
function myGetPathWin64Python(Param: String): String;
begin
  Result := mPathWin64Python;
end;
function myGetPathWin64PythonLib(Param: String): String;
begin
  Result := mPathWin64PythonLib;
end;
function myGetPathWin64PythonDLLs(Param: String): String;
begin
  Result := mPathWin64PythonDLLs;
end;
function CheckAppendPath: Boolean;
begin
  Result := InstallHelpCheckBox.Checked=True;
end;

procedure InitializeWizard;
var
  mTitlePythondir: String;
  mallDirPython: String;
  mCut: Integer;
  myvers: String;
begin

  // CHECK PYTHON INSTALLATION
  mFoundWin32Python := 0;
  mFoundWin64Python := 0;

  myvers := '{#MyPythonVers}';

  if (IsWin64) then
  begin
    // CASE OF 64 BIT PLATFORM

        // find 64 bit python:
    if RegQueryStringValue(HKLM64,
                    'SOFTWARE\Python\PythonCore\' +  myvers+ '\InstallPath',
                    '',
                    mallDirPython) then
    begin
          //MsgBox('FOUND! 64bit !'#13#13 + mallDirPython, mbError, MB_OK);
          mPathWin64Python := mallDirPython;
          mFoundWin64Python := 1;
    end

        // find 32 bit python:
    if RegQueryStringValue(HKEY_LOCAL_MACHINE,
                    'SOFTWARE\Wow6432Node\Python\PythonCore\' +  myvers+ '\InstallPath',
                    '',
                    mallDirPython) then
    begin
          //MsgBox('Attention. Found a 32bit version of Python on your system. The Chrono::PyEngine provided with this installer will work only with the 64 bit version. !'#13#13 + mallDirPython, mbError, MB_OK);
          mPathWin32Python := mallDirPython;
          mFoundWin32Python := 1;
    end

  end
  else
  begin
    // CASE OF 32 BIT PLATFORM

    // find 32 bit python:
    if RegQueryStringValue(HKEY_LOCAL_MACHINE,
                    'SOFTWARE\Python\PythonCore\' +  myvers+ '\InstallPath',
                    '',
                    mallDirPython) then
    begin
          //MsgBox('Attention. Found a 32bit version of Python on your system. The Chrono::PyEngine provided with this installer will work only with the 64 bit version. !'#13#13 + mallDirPython, mbError, MB_OK);
          mPathWin32Python := mallDirPython;
          mFoundWin32Python := 1;
    end

  end

  mPathWin32PythonDLLs := mPathWin32Python;// AddBackslash(mPathWin32Python) + 'DLLs';
  mPathWin32PythonLib  := mPathWin32Python;// AddBackslash(mPathWin32Python) + 'Lib';
  mPathWin64PythonDLLs := mPathWin64Python;// AddBackslash(mPathWin64Python) + 'DLLs';
  mPathWin64PythonLib  := mPathWin64Python;// AddBackslash(mPathWin64Python) + 'Lib';

  { Create the pages }

  //
  // Select directory dialog for plugin
  //
  if mFoundWin64Python = 1 then begin mTitlePythondir := 'A copy of 64bit Python has been automatically detected, installed in this directory.'#13+
                                   '- you can install the Chrono::PyEngine libraries here (check that you have administrative previleges),'#13+
                                   '- or you can choose a different directory (preferred). If so, remember that you must '#13+
                                   '  set/append this directory to the PYTHONPATH environment variable.';
                    end else begin mTitlePythondir := 'A 64bit installation of Python has NOT been automatically found!. '#13+
                                   'Nevertheless, you can still go on with the installation, something went'#13+
                                   'wrong with your registry keys. Note: after the installation, in order for'#13+
                                   'the generated Python modules to be accessible, you must set/append this directory'#13+
                                   'to the PYTHONPATH environment variable.'; end

  DataDirPage := CreateInputDirPage(wpWelcome,
    'Choose directory for installation', 'Where do you want to install the Chrono::PyEngine libraries?',
    mTitlePythondir,
    False, '');
  DataDirPage.Add('');
  DataDirPage.Values[0] := Format('%s\', [mPathWin64Python] );

  RegisterPathPage := CreateCustomPage(wpSelectDir,
    'Set PYTHONPATH',
    'Automatically set the PYTHONPATH environment variable'#13 + 'with the installation path?');
  InstallHelpCheckBox := TNewCheckBox.Create(RegisterPathPage);
  InstallHelpCheckBox.Parent := RegisterPathPage.Surface;
  InstallHelpCheckBox.Checked := True;
  InstallHelpCheckBox.Width := 300;
  InstallHelpCheckBox.Caption := 'Set PYTHONPATH';

  InstallHelpLabel := TLabel.Create(RegisterPathPage);
  InstallHelpLabel.Parent := RegisterPathPage.Surface;
  InstallHelpLabel.Width := 300;
  InstallHelpLabel.Height := 300;
  InstallHelpLabel.Caption := ''#13#13#13#13 +
    'When Python is started, it looks for additional modules (.pyd files) in' + #13 +
    'its directory, in the global paths, or in the PYTHONPATH directories.' + #13 +
    'So, we need to make also Chrono modules accessible to Python via PYTHONPATH.' + #13 +
    '' + #13 +
    'This option will automatically append the install directory' + #13 +
    'to your PYTHONPATH environment variable. ' + #13 +
    '- If PYTHONPATH does not exist, it will create it.' + #13 +
    '- If PYTHONPATH already contains the install directory (for' + #13 +
    '  instance, because you installed Chrono::PyEngine in the past)' + #13 +
    '  this will not be appended.' + #13 +
    '' + #13 +
    'NOTE! If you do not select this, you must remember to append it manually!';

end;

// OBSOLETE
function NextButtonClick(CurPageID: Integer): Boolean;
var
  I: Integer;
  mfilesize: Integer;
begin

  //
  // After the user has entered data...
  //
  if CurPageID = DataDirPage.ID then begin

      mPathWin64Python     := DataDirPage.Values[0];
      mPathWin64PythonDLLs := mPathWin64Python; //:= AddBackslash(mPathWin64Python) + 'DLLs';
      mPathWin64PythonLib  := mPathWin64Python; //:= AddBackslash(mPathWin64Python) + 'Lib';

      if FileOrDirExists(mPathWin64Python) and FileOrDirExists(mPathWin64PythonDLLs) and FileOrDirExists(mPathWin64PythonLib) then begin
        Result := True;
        mFoundWin64Python :=1;
      end else begin
        MsgBox('Error. The directory '+ mPathWin64Python + ' does not exist', mbError, MB_OK);
        Result := False;
      end

  end else
      Result := True;
end;

// OBSOLETE - remove DataDirPage completely
function ShouldSkipPage(PageID: Integer): Boolean;
begin
  Result := False;

  { Skip pages that shouldn't be shown }

  //if (PageID = wpSelectDir) then
  //  Result := True

  if (PageId = DataDirPage.ID) then
      Result := True

  //if ((PageId = DataDirPage.ID) and ((mFoundWin64Python =1) or (mFoundWin32Python =1)))  then
  //  Result := True
end;

function UpdateReadyMemo(Space, NewLine, MemoUserInfoInfo, MemoDirInfo, MemoTypeInfo,
  MemoComponentsInfo, MemoGroupInfo, MemoTasksInfo: String): String;
var
  S: String;
begin
  { Fill the 'Ready Memo' with the normal settings and the custom settings }
  S := '';

  if (mFoundWin32Python = 1) then begin
    S := S + 'A Win32 Python has been detected in:' + NewLine;
    S := S + Space + mPathWin32Python + NewLine;
    S := S + 'but the Chrono::Engine 32 bit module is NOT INCLUDED in this installer AND CANNOT BE INSTALLED!' + NewLine;
  end

  if ((mFoundWin64Python = 1) and (mFoundWin32Python = 0)) then begin
    S := S + 'A Win64 Python has been detected in:' + NewLine;
    S := S + Space + mPathWin64Python + NewLine;
    S := S + NewLine;
    S := S + NewLine;
    S := S + 'The Chrono::Engine 64 bit module will be installed in:' + NewLine;
    S := S + space + ExpandConstant('{app}') + NewLine;

    if (CheckAppendPath = True) then begin
      S := S + NewLine;
      S := S + 'Your PYTHONPATH environment variable will be automatically' + NewLine;
      S := S + 'updated by appending the ' + NewLine;
      S := S + space + ExpandConstant('{app}') + NewLine;
      S := S + 'value, if not already existing.';
    end else begin
      S := S + NewLine;
      S := S + 'REMEMBER! you must manually add the directory' + NewLine;
      S := S + space + ExpandConstant('{app}') + NewLine;
      S := S + 'to your PYTHONPATH environment variable!' + NewLine;
      S := S + 'Otherwise, Python cannot find the installed Chrono modules.'
    end
  end

  if ((mFoundWin64Python = 0) and  (mFoundWin32Python = 0)) then begin
    S := S + 'Neither Win32 nor Win64 Python (version' +  '{#MyPythonVers}' + ') has been detected.' + NewLine;
    S := S + 'Chrono::Engine module CANNOT BE INSTALLED!' + NewLine;
  end

  //HKEY_CURRENT_USER\Environment

  Result := S;
end;

function NeedsAddPath(Param: string): boolean;
var
  OrigPath: string;
  ParamExpanded: string;
begin
  //MsgBox('NeedsAddPath. check if already set:'#13#13 + Param, mbInformation, MB_OK);
  ParamExpanded := ExpandConstant(Param);
  if not RegQueryStringValue(HKCU64,
    'Environment',
    'PYTHONPATH', OrigPath)
  then begin
    //MsgBox('Attention. Environment\PYTHONPATH not found!'#13#13, mbInformation, MB_OK);
    Result := True;
    exit;
  end;

  // look for the path with leading and trailing semicolon and with or without \ ending
  // Pos() returns 0 if not found
  Result := Pos(';' + UpperCase(ParamExpanded) + ';', ';' + UpperCase(OrigPath) + ';') = 0;
  if Result = True then
     Result := Pos(';' + UpperCase(ParamExpanded) + '\;', ';' + UpperCase(OrigPath) + ';') = 0;

  if (CheckAppendPath = False) then begin
     Result := False;
  end;

  MsgBox('NeedsAddPath returns:'#13#13 + IntToStr(Integer(Result)), mbInformation, MB_OK);
end;

//
// PROJECT CHRONO - http://projectchrono.org
//
// Copyright (c) 2012 Alessandro Tasora
// Copyright (c) 2013 Project Chrono
// All rights reserved.
//
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file at the top level of the distribution
// and at http://projectchrono.org/license-chrono.txt.
//

#include "ModifyPath.iss"

#define MyAppName "PyChronoEngine"
#define MyAppVersion "v2.0.7"
#define MyAppPublisher "Alessandro Tasora"
#define MyAppURL "http://www.chronoengine.info"
#define MyWin64PythonDir  "C:\Python33"
#define MyPythonVers "3.3"
#define MyChronoEngineSDK "C:\tasora\code\projectchrono\chrono"

[Setup]
ShowLanguageDialog=yes
UserInfoPage=no
AppName={#MyAppName}
AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\{#MyAppName}
DefaultGroupName={#MyAppName}
WizardImageFile=SetupModern20.bmp
WizardSmallImageFile=SetupModernSmall26.bmp
PrivilegesRequired=admin
;Compression=none
OutputDir=c:\tasora\lavori\data_chrono
OutputBaseFilename=PyChronoEngine_{#MyAppVersion}

[Files]
Source: {#MyChronoEngineSDK}\src\demos\data\*; Excludes: "*\.svn,\data\mpi"; DestDir: "{app}\data"; Flags: recursesubdirs createallsubdirs
Source: {#MyChronoEngineSDK}\src\demos\python\*; DestDir: "{app}\python"; Flags: recursesubdirs createallsubdirs

Source: {#MyWin64PythonDir}\DLLs\_ChronoEngine_PYTHON_core.pyd; DestDir: {code:myGetPathWin64PythonDLLs};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\DLLs\_ChronoEngine_PYTHON_postprocess.pyd; DestDir: {code:myGetPathWin64PythonDLLs};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\DLLs\_ChronoEngine_PYTHON_irrlicht.pyd; DestDir: {code:myGetPathWin64PythonDLLs};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\DLLs\_ChronoEngine_PYTHON_fea.pyd; DestDir: {code:myGetPathWin64PythonDLLs};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\DLLs\ChronoEngine.dll; DestDir: {code:myGetPathWin64PythonDLLs};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\DLLs\ChronoEngine_POSTPROCESS.dll; DestDir: {code:myGetPathWin64PythonDLLs};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\DLLs\ChronoEngine_IRRLICHT.dll; DestDir: {code:myGetPathWin64PythonDLLs};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\DLLs\ChronoEngine_FEA.dll; DestDir: {code:myGetPathWin64PythonDLLs};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\DLLs\Irrlicht.dll; DestDir: {code:myGetPathWin64PythonDLLs};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\lib\ChronoEngine_PYTHON_core.py; DestDir: {code:myGetPathWin64PythonLib};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\lib\ChronoEngine_PYTHON_postprocess.py; DestDir: {code:myGetPathWin64PythonLib};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\lib\ChronoEngine_PYTHON_irrlicht.py; DestDir: {code:myGetPathWin64PythonLib};  Flags: ignoreversion;  Check: myFoundWin64Python;
Source: {#MyWin64PythonDir}\lib\ChronoEngine_PYTHON_fea.py; DestDir: {code:myGetPathWin64PythonLib};  Flags: ignoreversion;  Check: myFoundWin64Python;

[Icons]
Name: "{group}\Getting started"; Filename: "http://www.chronoengine.info"
Name: "{group}\Demos"; Filename: "{app}\python"
Name: "{group}\Uninstall"; Filename: "{uninstallexe}"

[Code]
var
  DataDirPage: TInputDirWizardPage;
  mFoundWin32Python: Integer;
  mPathWin32Python: String;
  mPathWin32PythonLib: String;
  mPathWin32PythonDLLs: String;
  mFoundWin64Python: Integer;
  mPathWin64Python: String;
  mPathWin64PythonLib: String;
  mPathWin64PythonDLLs: String;

function myFoundWin32Python: Boolean;
begin
  Result := mFoundWin32Python =1;
end;
function myGetPathWin32Python(Param: String): String;
begin
  Result := mPathWin32Python;
end;
function myGetPathWin32PythonLib(Param: String): String;
begin
  Result := mPathWin32PythonLib;
end;
function myGetPathWin32PythonDLLs(Param: String): String;
begin
  Result := mPathWin32PythonDLLs;
end;
function myFoundWin64Python: Boolean;
begin
  Result := mFoundWin64Python =1;
end;
function myGetPathWin64Python(Param: String): String;
begin
  Result := mPathWin64Python;
end;
function myGetPathWin64PythonLib(Param: String): String;
begin
  Result := mPathWin64PythonLib;
end;
function myGetPathWin64PythonDLLs(Param: String): String;
begin
  Result := mPathWin64PythonDLLs;
end;

procedure InitializeWizard;
var
  mTitlePythondir: String;
  mallDirPython: String;
  mCut: Integer;
  myvers: String;
begin

  // CHECK PYTHON INSTALLATION
  mFoundWin32Python := 0;
  mFoundWin64Python := 0;

  myvers := '{#MyPythonVers}';

  if (IsWin64) then
  begin
    // CASE OF 64 BIT PLATFORM

        // find 64 bit python:
    if RegQueryStringValue(HKLM64,
                    'SOFTWARE\Python\PythonCore\' +  myvers+ '\InstallPath',
                    '',
                    mallDirPython) then
    begin
          MsgBox('FOUND! 64bit !'#13#13 + mallDirPython, mbError, MB_OK);
          mPathWin64Python := mallDirPython;
          mFoundWin64Python := 1;
    end

        // find 32 bit python:
    if RegQueryStringValue(HKEY_LOCAL_MACHINE,
                    'SOFTWARE\Wow6432Node\Python\PythonCore\' +  myvers+ '\InstallPath',
                    '',
                    mallDirPython) then
    begin
          mPathWin32Python := mallDirPython;
          mFoundWin32Python := 1;
    end

  end
  else
  begin
    // CASE OF 32 BIT PLATFORM

    // find 32 bit python:
    if RegQueryStringValue(HKEY_LOCAL_MACHINE,
                    'SOFTWARE\Python\PythonCore\' +  myvers+ '\InstallPath',
                    '',
                    mallDirPython) then
    begin
          mPathWin32Python := mallDirPython;
          mFoundWin32Python := 1;
    end

  end

  mPathWin32PythonDLLs := AddBackslash(mPathWin32Python) + 'DLLs';
  mPathWin32PythonLib  := AddBackslash(mPathWin32Python) + 'Lib';
  mPathWin64PythonDLLs := AddBackslash(mPathWin64Python) + 'DLLs';
  mPathWin64PythonLib  := AddBackslash(mPathWin64Python) + 'Lib';

  { Create the pages }

  //
  // Select directory dialog for plugin
  //
  if mFoundWin64Python = 1 then begin mTitlePythondir := 'A copy of 64bit Python has been automatically detected, installed in this directory.'#13+
                                   'Do NOT modify the installation path unless you know what you are doing:'#13+
                                   'the Chrono::Engine module works only if installed in the proper Python directory!';
                    end else begin mTitlePythondir := 'The installation directory of Python has NOT been automatically found!. '#13+
                                   'Nevertheless, you can still go on with the installation, something went'#13+
                                   'wrong with your registry keys. Note: set this directory so that it is the'#13+
                                   'directory where python.exe file is installed, for Win64 bit'#13+
                                   'for example  C:\Python33 '; end

  DataDirPage := CreateInputDirPage(wpWelcome,
    'Check Python directory', 'Where is your Python (version ' +  myvers + ' or following, 64bit) directory?',
    mTitlePythondir,
    False, '');
  DataDirPage.Add('');
  DataDirPage.Values[0] := Format('%s\', [mPathWin64Python] );

end;

function NextButtonClick(CurPageID: Integer): Boolean;
var
  I: Integer;
  mfilesize: Integer;
begin

  //
  // After the user has entered data...
  //
  if CurPageID = wpWelcome then begin

   //   if ((mFoundWin32Python = 0) and (mFoundWin64Python = 0) ) then begin
   //     mPathWin64Python := '{#MyWin64PythonDir}';
   //     MsgBox('WARNING!'#13#13+
   //            'The installer was not able to detect Python (version' +  '{#MyPythonVers}' + ') '+
   //            'on your system.'#13#13+
   //            'Maybe your Python (version' +  '{#MyPythonVers}' + ') is not yet installed, or not properly installed?'#13+
   //            '(If so,please install/reinstall Python 64 bit before installing this plug-in).', mbError, MB_OK);
   //  end;
   //
      Result := True;

  //
  // After the user has choosen python directory..
  //
  end else if CurPageID = DataDirPage.ID then begin

      mPathWin64Python     := DataDirPage.Values[0];
      mPathWin64PythonDLLs := AddBackslash(mPathWin64Python) + 'DLLs';
      mPathWin64PythonLib  := AddBackslash(mPathWin64Python) + 'Lib';

      if FileOrDirExists(mPathWin64Python) and FileOrDirExists(mPathWin64PythonDLLs) and FileOrDirExists(mPathWin64PythonLib) then begin
        Result := True;
        mFoundWin64Python :=1;
      end else begin
        MsgBox('Error. The directory '+ mPathWin64Python + ' does not exist', mbError, MB_OK);
        Result := False;
      end

  end else
      Result := True;
end;

function ShouldSkipPage(PageID: Integer): Boolean;
begin
  Result := False;

  { Skip pages that shouldn't be shown }

  if (PageID = wpSelectDir) then
    Result := True

  if ((PageId = DataDirPage.ID) and ((mFoundWin64Python =1) or (mFoundWin32Python =1)))  then
    Result := True
end;

function UpdateReadyMemo(Space, NewLine, MemoUserInfoInfo, MemoDirInfo, MemoTypeInfo,
  MemoComponentsInfo, MemoGroupInfo, MemoTasksInfo: String): String;
var
  S: String;
begin
  { Fill the 'Ready Memo' with the normal settings and the custom settings }
  S := '';

  if (mFoundWin32Python = 1) then begin
    S := S + 'A Win32 Python has been detected in:' + NewLine;
    S := S + Space + mPathWin32Python + NewLine;
    S := S + 'but the Chrono::Engine 32 bit module is NOT INCLUDED in this installer AND CANNOT BE INSTALLED!' + NewLine;
    //S := S + Space + mPathWin32PythonDLLs + NewLine;
    //S := S + Space + mPathWin32PythonLib + NewLine;
  end

  if ((mFoundWin64Python = 1) and (mFoundWin32Python = 0)) then begin
    S := S + 'A Win64 Python has been detected in:' + NewLine;
    S := S + Space + mPathWin64Python + NewLine;
    S := S + 'so the Chrono::Engine 64 bit module will be installed in:' + NewLine;
    //S := S + 'so the Chrono::Engine 64 bit module will be installed in:' + NewLine;
    S := S + Space + mPathWin64PythonDLLs + NewLine;
    S := S + Space + mPathWin64PythonLib + NewLine;
  end

  if ((mFoundWin64Python = 0) and  (mFoundWin32Python = 0)) then begin
    S := S + 'Neither Win32 nor Win64 Python (version' +  '{#MyPythonVers}' + ') has been detected.' + NewLine;
    S := S + 'Chrono::Engine module CANNOT BE INSTALLED!' + NewLine;
  end

  Result := S;
end;

//function CheckSerial(Serial: String): Boolean;
//begin
//   Result:=True;
//end;


Run at Windows startup option

Run at Windows startup option

Displays a checkbox in the setup to ask the user if he want to launch
the program at startup.

#define MyAppName "Gmail Notifier"
#define MyAppVersion "1.0.3.0"
#define MyAppPublisher "Xavier Foucrier"
#define MyAppURL "https://github.com/xavierfoucrier/gmail-notifier"
#define MyAppExeName "Gmail notifier.exe"

[Setup]
AppId={{7E60E047-C79B-49A4-8CF6-B33D5565B2E8}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
AppCopyright=Copyright 2016
AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\{#MyAppName}
DefaultGroupName={#MyAppName}
AllowNoIcons=yes
LicenseFile=..\LICENSE.md
OutputDir=..\setup
ArchitecturesInstallIn64BitMode=x64
OutputBaseFilename=Gmail Notifier setup
SetupIconFile=setup.ico
Compression=lzma
SolidCompression=yes

[Languages]
Name: "en"; MessagesFile: "compiler:Default.isl"
Name: "fr"; MessagesFile: "compiler:Languages\French.isl"
Name: "de"; MessagesFile: "compiler:Languages\German.isl"

[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
Name: "quicklaunchicon"; Description: "{cm:CreateQuickLaunchIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked; OnlyBelowVersion: 0,6.1
Name: "startup"; Description: "{cm:AutoStartProgram,{#MyAppName}}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: checkablealone;

[Files]
Source: "..\Gmail notifier\bin\Release 32 bits (x86)\Gmail notifier.exe"; DestDir: "{app}"; Flags: ignoreversion; Check: not Is64BitInstallMode
Source: "..\Gmail notifier\bin\Release 32 bits (x86)\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs; Check: not Is64BitInstallMode
Source: "..\Gmail notifier\bin\Release 64 bits (x64)\Gmail notifier.exe"; DestDir: "{app}"; Flags: ignoreversion; Check: Is64BitInstallMode
Source: "..\Gmail notifier\bin\Release 64 bits (x64)\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs; Check: Is64BitInstallMode

[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{group}\{cm:ProgramOnTheWeb,{#MyAppName}}"; Filename: "{#MyAppURL}"
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon
Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: quicklaunchicon

[Run]
Filename: "{app}\{#MyAppExeName}"; Parameters: "install {language}"
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent

[Registry]
Root: HKCU; Subkey: "Software\Microsoft\Windows\CurrentVersion\Run"; ValueType: string; ValueName: "Gmail notifier"; ValueData: "{app}\{#MyAppExeName}"; Tasks: startup; Flags: uninsdeletevalue;

#define MyAppName "Gmail Notifier"
#define MyAppVersion "1.0.3.0"
#define MyAppPublisher "Xavier Foucrier"
#define MyAppURL "https://github.com/xavierfoucrier/gmail-notifier"
#define MyAppExeName "Gmail notifier.exe"

[Setup]
AppId={{7E60E047-C79B-49A4-8CF6-B33D5565B2E8}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
AppCopyright=Copyright 2016
AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\{#MyAppName}
DefaultGroupName={#MyAppName}
AllowNoIcons=yes
LicenseFile=..\LICENSE.md
OutputDir=..\setup
ArchitecturesInstallIn64BitMode=x64
OutputBaseFilename=Gmail Notifier setup
SetupIconFile=setup.ico
Compression=lzma
SolidCompression=yes

[Languages]
Name: "en"; MessagesFile: "compiler:Default.isl"
Name: "fr"; MessagesFile: "compiler:Languages\French.isl"
Name: "de"; MessagesFile: "compiler:Languages\German.isl"

[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
Name: "quicklaunchicon"; Description: "{cm:CreateQuickLaunchIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked; OnlyBelowVersion: 0,6.1

[Files]
Source: "..\Gmail notifier\bin\Release 32 bits (x86)\Gmail notifier.exe"; DestDir: "{app}"; Flags: ignoreversion; Check: not Is64BitInstallMode
Source: "..\Gmail notifier\bin\Release 32 bits (x86)\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs; Check: not Is64BitInstallMode
Source: "..\Gmail notifier\bin\Release 64 bits (x64)\Gmail notifier.exe"; DestDir: "{app}"; Flags: ignoreversion; Check: Is64BitInstallMode
Source: "..\Gmail notifier\bin\Release 64 bits (x64)\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs; Check: Is64BitInstallMode

[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{group}\{cm:ProgramOnTheWeb,{#MyAppName}}"; Filename: "{#MyAppURL}"
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon
Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: quicklaunchicon

[Run]
Filename: "{app}\{#MyAppExeName}"; Parameters: "install {language}"
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent