installs spyder and all, need to correct scientific_startup

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

#define MyAppName "tellurium"
#define MyAppVersion "0.0.1"
#define MyAppPublisher "University of Washington, Seattle, WA, USA"
#define MyAppURL "http://tellurium.analogmachine.org/"
#define MyAppSetupIconFile "Te.ico"
#define ThisInstallerPostfix "win32-superpack-setup"

#define LibRoadRunnerInstaller "roadrunner-1.0.1-rc3-win32-minimal-setup.exe"
#define AntimonyInstaller "antimony-2.5.0-win32-minimal-setup.exe"
#define TelPluginsInstaller "telplugins-0127204-11.27-Python-2.7-win32-minimal-setup.exe"
#define PyInstaller "python-2.7.6.msi"
#define NumpyInstaller "numpy-1.8.0-win32-superpack-python2.7.exe"
#define MatplotlibInstaller "matplotlib-1.3.1.win32-py2.7.exe"
;#define DateutilInstaller "python-dateutil-2.2.win32-py2.7.exe"
;#define PyparsingInstaller "pyparsing-2.0.1.win32-py2.7.exe"
;#define SixInstaller "six-1.5.2.win32-py2.7.exe"

#define PyQtInstaller "PyQt4"
#define SipInstaller "sip.pyd"
#define PipInstaller "get-pip.py"
#define SpyderInstaller "spyder-2.2.5.win32.exe"

;add spyder source
;then do ":python setup.py install" to install

;downloads turned off, installers packaged
;#define LibRoadRunnerInstallerURL "http://sourceforge.net/projects/libroadrunner/files/roadrunner-1.0.1-rc1-win32-minimal-setup.exe"
;#define AntimonyInstallerURL "http://sourceforge.net/projects/antimony/files/Windows%20binaries/2.5/AntimonyPythonBindings-2.5.0-win32.exe"
;#define PyInstallerURL "http://python.org/ftp/python/2.7.6/python-2.7.6.msi"
;#define NumpyInstallerURL "http://downloads.sourceforge.net/project/numpy/NumPy/1.8.0/numpy-1.8.0-win32-superpack-python2.7.exe?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fnumpy%2Ffiles%2FNumPy%2F&ts=1390956336&use_mirror=softlayer-ams"
;#define MatplotlibInstallerURL "https://downloads.sourceforge.net/project/matplotlib/matplotlib/matplotlib-1.3.1/matplotlib-1.3.1.win32-py2.7.exe"
;#define DateutilInstallerURL "http://www.lfd.uci.edu/~gohlke/pythonlibs/#python-dateutil" ;there does not appear to be a direct URL to the file
;#define PyparsingInstallerURL "http://www.lfd.uci.edu/~gohlke/pythonlibs/#pyparsing" The one from "http://downloads.sourceforge.net/project/pyparsing/pyparsing/pyparsing-2.0.1/pyparsing-2.0.1.win32-py2.7.exe" did not work.
;#define SixInstallerURL "http://www.lfd.uci.edu/~gohlke/pythonlibs/#six"
;#define PyQtInstallerURL "http://sourceforge.net/projects/pyqt/files/PyQt4/PyQt-4.10.3/PyQt4-4.10.3-gpl-Py2.7-Qt4.8.5-x32.exe/download"
;#define SipInstallerURL "http://www.riverbankcomputing.com/software/sip/download" #using file from bin install
;#define PipInstallerURL "https://raw.github.com/pypa/pip/master/contrib/get-pip.py"
;#define SpyderInstaller "https://bitbucket.org/spyder-ide/spyderlib/downloads/spyder-2.2.5.win32.exe"

#define Py "Python"
#define PyVer "2.7"
#define Numpy "numpy"
;#define NumpyVer "1.0"
#define Matplotlib "matplotlib"
;#define MatplotlibVer "1.0"
#define AppDir "tellurium"
#define Pip "C:\Python27\Scripts\pip.exe"

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

[Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={{2EA1F666-39FE-4A26-BCC9-4D534219C9AE}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
;AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DisableWelcomePage=yes
DefaultDirName={code:SetDefaultAppDirName}
;DefaultDirName=C:\Python27\Lib\site-packages\{#AppDir}

;enable the next line for debug only
;DisableDirPage=yes

;DefaultGroupName=libRoadRunner
DisableProgramGroupPage=yes
;LicenseFile=..\..\LICENSE.txt
;InfoBeforeFile=..\..\NOTICE.txt
DisableReadyPage=yes
;DisableFinishedPage=yes   ;finished page is good feedback
OutputDir=.
OutputBaseFilename={#MyAppName}-{#MyAppVersion}-{#Py}-{#PyVer}-{#ThisInstallerPostfix}
SetupIconFile={#MyAppSetupIconFile}
Compression=lzma
SolidCompression=yes

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Files]
Source: "../../startTellurium.py"; DestDir: "{app}"; Flags: ignoreversion
Source: "../../__init__.py"; DestDir: "{app}"; Flags: ignoreversion
Source: "super_installer_dependencies\{#LibRoadRunnerInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion
Source: "super_installer_dependencies\{#AntimonyInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion
Source: "super_installer_dependencies\{#TelPluginsInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion
Source: "libRoadrunner-installer-dependencies\NOTICE.TXT"; DestDir: "{app}"; DestName:"NOTICE2.TXT"; Flags: ignoreversion
Source: "libRoadrunner-installer-dependencies\{#MatplotlibInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
;Source: "libRoadrunner-installer-dependencies\{#DateutilInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
;Source: "libRoadrunner-installer-dependencies\{#PyparsingInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
;Source: "libRoadrunner-installer-dependencies\{#SixInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
Source: "libRoadrunner-installer-dependencies\{#NumpyInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
Source: "libRoadrunner-installer-dependencies\{#PyInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
Source: "libRoadrunner-installer-dependencies\{#PipInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist

Source: "spyder_dependencies\{#PyQtInstaller}\*"; DestDir: "C:\Python27\Lib\site-packages\{#PyQtInstaller}"; Flags: ignoreversion onlyifdoesntexist recursesubdirs createallsubdirs
Source: "spyder_dependencies\{#SipInstaller}"; DestDir: "C:\Python27\Lib\site-packages"; Flags: ignoreversion onlyifdoesntexist
Source: "spyder_dependencies\{#SpyderInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
Source: "spyder_dependencies\scientific_startup.py"; DestDir: "{tmp}"; AfterInstall: MakeTelSpyder('C:\Python27\Lib\site-packages\spyderlib\scientific_startup.py'); Flags: ignoreversion

;from tellurium import *

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

[Run]
Filename: "{tmp}\{#PipInstaller}"; Verb: "open"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install python-dateutil"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install pyparsing"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install six"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

Filename: "{#Pip}"; Parameters: "install ipython[all]"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install sphinx"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install pyflakes"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install pylint"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install pep8"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install psutil"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#LibRoadRunnerInstaller}"; Parameters: "/SILENT"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#AntimonyInstaller}"; Parameters: "/SILENT"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#TelPluginsInstaller}"; Parameters: "/SILENT"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#SpyderInstaller}"; Parameters: "/SILENT"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

;SCIPY pip install has an error, may need a fortran compiler! mingw, but do we need Scipy?
;Filename: "{#Pip}"; Parameters: "install scipy"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

;MATPLOTLIB, on pip install, cannot find vcvarsall.bat, a symptom of missing the 2008 VS++ <-seriously you need to install a compiler
;Filename: "{#Pip}"; Parameters: "install matplotlib"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

;NUMPY, on pip install, cannot find vcvarsall.bat, a symptom of missing the 2008 VS++ <-seriously you need to install a compiler
;Filename: "{#Pip}"; Parameters: "install numpy"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

[Code]
//////////////////////////////////////////////////////////////////////////////
const
  appDir = '{#AppDir}';
  pyReg = 'SOFTWARE\{#Py}\PythonCore\{#PyVer}\InstallPath';
  pyRegWow6443Node = 'SOFTWARE\Wow6432Node\{#Py}\PythonCore\{#PyVer}\InstallPath';

var
  installPython, installMatplot, installNumpy: Boolean;
  DefaultAppDirName: String;

//////////////////////////////////////////////////////////////////////////////
procedure ExitProcess(exitCode:integer);
  external 'ExitProcess@kernel32.dll stdcall';

//////////////////////////////////////////////////////////////////////////////
function GetPathForPythonSitePackages(): string;
var
  InstallPath: string;
begin

  if RegQueryStringValue(HKEY_LOCAL_MACHINE, pyReg, '', InstallPath) then
    begin
    Log('HKLM pyReg: '+ InstallPath);
    Result := InstallPath + 'Lib\site-packages\';
    end
  else
  if RegQueryStringValue(HKEY_CURRENT_USER, pyReg, '', InstallPath) then
    begin
    Log('HKCU pyReg: '+ InstallPath);
    Result := InstallPath + 'Lib\site-packages\';
    end
  else
  if RegQueryStringValue(HKEY_LOCAL_MACHINE, pyRegWow6443Node, '', InstallPath) then
    begin
    Log('HKLM pyRegWow6443Node: '+ InstallPath);
    Result := InstallPath + 'Lib\site-packages\';
    end
  else
    begin
    MsgBox('Our installer did not find your Python installation. You need '
    + 'Python to run {#MyAppName}. In the next step use [Your Python installation'
    + ' location]\Lib\site-packages\{#AppDir} directory.',mbError,MB_OK);
    //ExitProcess(1);
    end
end;

//////////////////////////////////////////////////////////////////////////////
function IsPythonInstalled(): Boolean;
var
  InstallPath: string; //not really used here
begin

  if RegQueryStringValue(HKEY_LOCAL_MACHINE, pyReg, '', InstallPath) then
    begin
    Result := True;
    end
  else
  if RegQueryStringValue(HKEY_CURRENT_USER, pyReg, '', InstallPath) then
    begin
    Result := True;
    end
  else
  if RegQueryStringValue(HKEY_LOCAL_MACHINE, pyRegWow6443Node, '', InstallPath) then
    begin
    Result := True;
    end
  else
    begin
    Result := False;
    end
end;

//////////////////////////////////////////////////////////////////////////////
function SetDefaultAppDirName(Value: String): String;
begin
  Result := DefaultAppDirName;
end;

//////////////////////////////////////////////////////////////////////////////
function IsInstalled(name: String): Boolean;
//function IsInstalled(name: string; version: string): boolean;  //ver not neeeded
var
  InstallPath: string;
  reg : string;
begin
  //reg := 'Software\' + name + '\' + version
  // + '\InstallPath'
  // Log('reg Python: ' + reg)

  //if Numpy/ matplotlib installed - direct check for file
  InstallPath := GetPathForPythonSitePackages() + name + '/__init__.py'
  Log('install dir: ' + InstallPath)
  if FileExists(InstallPath) then
  //if RegQueryStringValue(HKEY_CURRENT_USER, reg, 'InstallPath', InstallPath) then
   //numpy doesnt have a reg entry! (also gets its install path, not used here)
    begin
    Result := True;
    end
  else
    begin
    Result := False;
    end;
end;

//////////////////////////////////////////////////////////////////////////////
procedure RunMsiInstaller(execName: string);
var
  ResultCode: Integer;
  ExecPath: String;
  ExecCommand: String;
begin
  ExecPath := ExpandConstant('{tmp}\') + execName;
  ExecCommand := '/i ' + ExecPath + ''; //+ ' /qb'; //qb does it silently

  //Check that the msi installer file is present
  if FileExists(ExecPath) then
    begin
    Log('ExecPath exists : ' + ExecPath);
    end
  else
    begin
    Log('ExecPath doe not exist : ' + ExecPath);
    MsgBox('Could not find ' + execName + ' installer',mbError,MB_OK);
    ExitProcess(1);
    //something went wrong: hell or high water python installer must be there
    end;

  //execute msi installer, otherwie error and exit
  if not ShellExec('', 'msiexec.exe', ExecCommand, '', SW_SHOWNORMAL,
                   ewWaitUntilTerminated, ResultCode) then
      //msi exec not working
      MsgBox('Msi installer failed to run!' + #13#10 + ExecCommand + ' ' +
             SysErrorMessage(ResultCode), mbError, MB_OK);
end;

//////////////////////////////////////////////////////////////////////////////
function InitializeSetup(): Boolean;
var
tmpPy: String;
begin
  //if python installed get path for python site-packages
  //if isInstalled('{#Py}\PythonCore','{#PyVer}') then
  if IsPythonInstalled() then
  begin
    Log('Python: ' + 'True');
    installPython := False;
    //Python must be installed, get its path
    DefaultAppDirName := GetPathForPythonSitePackages() + AppDir;
    Log('SetDefaultAppDirName: ' + DefaultAppDirName);
  end
  else //Add Python to tmp folder [ // or download list.. ]
  begin
    Log('Python: ' + 'False');
    installPython := True;
    tmpPy := ExpandConstant('{tmp}\{#PyInstaller}');
    //FileCopy(ExpandConstant('{#PyInstaller}'), tmpPy, false);
    ExtractTemporaryFile('{#PyInstaller}')
    Log('tmpPy: '+ tmpPy);

    {//Check that the msi tmpPy installer file is present
    if FileExists(tmpPy) then
      begin
      Log('tmpPy exists : ' + tmpPy);
      end
    else
      begin
      Log('MSI tmpPy does not exist : ' + tmpPy);
      MsgBox('Could not find MSI' + tmpPy + ' installer',mbError,MB_OK);
      ExitProcess(1);
      //something went wrong: hell or high water python installer must be there
      end;
     }
    DefaultAppDirName := 'C:\Python27\Lib\site-packages\{#AppDir}' //pretend default path
                                                                   //will be used when python is installed
                                                                   //not seeing another way to prepopulate
                                                                   //the Dir Destination page.
                                                                   //installing Pyton earlier not an option
                                                                   //as {tmp} was not created yet, so cant
                                                                   //extract python installer yet
    //itd_addfile('{#PyInstallerURL}',ExpandConstant('{tmp}\{#PyInstaller}'));
    //itd_addfile('http://sbol.bhi.washington.edu/ppp/setup-dummyPython.exe',ExpandConstant('{tmp}\setup-dummyPython.exe'));
  end;

  Result := True; //Required for fwd progress, false would exist
end;

//////////////////////////////////////////////////////////////////////////////
procedure InitializeWizard();
begin
 //itd_init;  //turned off when packaging installers

  //Install Python now if needed, we want it in place before anything else is done
  if (installPython) then
     RunMsiInstaller('{#PyInstaller}');

  //Python must be installed, get its path
  DefaultAppDirName := GetPathForPythonSitePackages() + AppDir;
  Log('SetDefaultAppDirName: ' + DefaultAppDirName);

  //Check if Numpy is installed
  if IsInstalled('{#Numpy}') then
  //if IsInstalled('{#Numpy}','{#NumpyVer}') then  //ver not needed
    begin
    Log('Numpy: ' + 'True');
    installNumpy := False;
    end
  else
    //Add Numpy to d/l list
    begin
    Log('Numpy: ' + 'False');
    installNumpy := True;

    //filecopy(ExpandConstant('{#NumpyInstaller}'),ExpandConstant('{tmp}\{#NumpyInstaller}'),false);
    ExtractTemporaryFile('{#NumpyInstaller}');

    //The following were used to test downloader srategy
    //itd_addfile('http://sbol.bhi.washington.edu/ppp/setup-dummyNump.exe',
    //            ExpandConstant('{tmp}\setup-dummyNump.exe'));
    end;

  //Check if Matplotlib is installed
  if IsInstalled('{#Matplotlib}') then
  //if IsInstalled('{#Matplotlib}','{#MatplotlibVer}') then   //ver not needed
    begin
    Log('Matplotlib: ' + 'True');
    installMatplot := False;
    end
  else
    //Add Matplotlib to d/l list
    begin
    Log('Matplotlib: ' + 'False');
    installMatplot := True;

    //filecopy(ExpandConstant('{#MatplotlibInstaller}'),ExpandConstant('{tmp}\{#MatplotlibInstaller}'),false);
    ExtractTemporaryFile('{#MatplotlibInstaller}');
    //ExtractTemporaryFile('{#DateutilInstaller}');
    //ExtractTemporaryFile('{#PyparsingInstaller}');
    //ExtractTemporaryFile('{#SixInstaller}');

    //The following were used to test downloader srategy
    //td_addfile('http://sbol.bhi.washington.edu/ppp/setup-dummyMatplot.exe',
    //            ExpandConstant('{tmp}\setup-dummyMatplot.exe'));
    end;

  //Downloads turned off, packaging installers.
  //Start the download after the "Ready to install" screen is shown
  //itd_downloadafter(wpReady);
end;

//////////////////////////////////////////////////////////////////////////////
procedure RunOtherInstaller(execName: string);
var
  ResultCode: Integer;
begin
  if not Exec(ExpandConstant('{tmp}\' + execName), '', '', SW_SHOWNORMAL,
    ewWaitUntilTerminated, ResultCode)
  then
    MsgBox('Other installer failed to run!' + #13#10 + execName +
      SysErrorMessage(ResultCode), mbError, MB_OK);
end;

//////////////////////////////////////////////////////////////////////////////
// Install Numpy and Matplotlib if mising
procedure CurStepChanged(CurStep: TSetupStep);
var
   ResultCode: Integer;
begin
  if CurStep=ssInstall then //If on the installation step
  //Lets install those files that were downloaded for us
    begin
    if ForceDirectories(ExpandConstant('{app}')) then
      begin
      Log('app: ' + ExpandConstant('{app}'));
      if (installNumpy) then
        RunOtherInstaller('{#NumpyInstaller}');
      if (installMatplot) then
        begin
        RunOtherInstaller('{#MatplotlibInstaller}');
        //RunOtherInstaller('{#DateutilInstaller}');
        //RunOtherInstaller('{#PyparsingInstaller}');
        //RunOtherInstaller('{#SixInstaller}');
        end;
      end;
    end;
end;

//////////////////////////////////////////////////////////////////////////////
// Install tellurium mod in spyder
procedure MakeTelSpyder(FileName: String);
begin
    //tmpPy := ExpandConstant('{tmp}\{#PyInstaller}');
    FileCopy(ExpandConstant('{tmp}\scientific_startup.py'), FileName, false);
    Log(ExpandConstant('{tmp}\scientific_startup.py') + ' :to: ' + FileName)
end;

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

#define MyAppName "tellurium"
#define MyAppVersion "0.0.1"
#define MyAppPublisher "University of Washington, Seattle, WA, USA"
#define MyAppURL "http://tellurium.analogmachine.org/"
#define MyAppSetupIconFile "Te.ico"
#define ThisInstallerPostfix "win32-superpack-setup"

#define LibRoadRunnerInstaller "roadrunner-1.0.1-rc3-win32-minimal-setup.exe"
#define AntimonyInstaller "antimony-2.5.0-win32-minimal-setup.exe"
#define TelPluginsInstaller "telplugins-0127204-11.27-Python-2.7-win32-minimal-setup.exe"
#define PyInstaller "python-2.7.6.msi"
#define NumpyInstaller "numpy-1.8.0-win32-superpack-python2.7.exe"
#define MatplotlibInstaller "matplotlib-1.3.1.win32-py2.7.exe"
;#define DateutilInstaller "python-dateutil-2.2.win32-py2.7.exe"
;#define PyparsingInstaller "pyparsing-2.0.1.win32-py2.7.exe"
;#define SixInstaller "six-1.5.2.win32-py2.7.exe"

#define PyQtInstaller "PyQt4"
#define SipInstaller "sip.pyd"
#define PipInstaller "get-pip.py"
#define SpyderInstaller "spyder"

;add spyder source
;then do ":python setup.py install" to install

;downloads turned off, installers packaged
;#define LibRoadRunnerInstallerURL "http://sourceforge.net/projects/libroadrunner/files/roadrunner-1.0.1-rc1-win32-minimal-setup.exe"
;#define AntimonyInstallerURL "http://sourceforge.net/projects/antimony/files/Windows%20binaries/2.5/AntimonyPythonBindings-2.5.0-win32.exe"
;#define PyInstallerURL "http://python.org/ftp/python/2.7.6/python-2.7.6.msi"
;#define NumpyInstallerURL "http://downloads.sourceforge.net/project/numpy/NumPy/1.8.0/numpy-1.8.0-win32-superpack-python2.7.exe?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fnumpy%2Ffiles%2FNumPy%2F&ts=1390956336&use_mirror=softlayer-ams"
;#define MatplotlibInstallerURL "https://downloads.sourceforge.net/project/matplotlib/matplotlib/matplotlib-1.3.1/matplotlib-1.3.1.win32-py2.7.exe"
;#define DateutilInstallerURL "http://www.lfd.uci.edu/~gohlke/pythonlibs/#python-dateutil" ;there does not appear to be a direct URL to the file
;#define PyparsingInstallerURL "http://www.lfd.uci.edu/~gohlke/pythonlibs/#pyparsing" The one from "http://downloads.sourceforge.net/project/pyparsing/pyparsing/pyparsing-2.0.1/pyparsing-2.0.1.win32-py2.7.exe" did not work.
;#define SixInstallerURL "http://www.lfd.uci.edu/~gohlke/pythonlibs/#six"
;#define PyQtInstallerURL "http://sourceforge.net/projects/pyqt/files/PyQt4/PyQt-4.10.3/PyQt4-4.10.3-gpl-Py2.7-Qt4.8.5-x32.exe/download"
;#define SipInstallerURL "http://www.riverbankcomputing.com/software/sip/download" #using file from bin install
;#define PipInstallerURL "https://raw.github.com/pypa/pip/master/contrib/get-pip.py"

#define Py "Python"
#define PyVer "2.7"
#define Numpy "numpy"
;#define NumpyVer "1.0"
#define Matplotlib "matplotlib"
;#define MatplotlibVer "1.0"
#define AppDir "tellurium"
#define Pip "C:\Python27\Scripts\pip.exe"

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

[Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={{2EA1F666-39FE-4A26-BCC9-4D534219C9AE}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
;AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DisableWelcomePage=yes
DefaultDirName={code:SetDefaultAppDirName}
;DefaultDirName=C:\Python27\Lib\site-packages\{#AppDir}

;enable the next line for debug only
;DisableDirPage=yes

;DefaultGroupName=libRoadRunner
DisableProgramGroupPage=yes
;LicenseFile=..\..\LICENSE.txt
;InfoBeforeFile=..\..\NOTICE.txt
DisableReadyPage=yes
;DisableFinishedPage=yes   ;finished page is good feedback
OutputDir=.
OutputBaseFilename={#MyAppName}-{#MyAppVersion}-{#Py}-{#PyVer}-{#ThisInstallerPostfix}
SetupIconFile={#MyAppSetupIconFile}
Compression=lzma
SolidCompression=yes

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Files]
Source: "../../startTellurium.py"; DestDir: "{app}"; Flags: ignoreversion
Source: "../../__init__.py"; DestDir: "{app}"; Flags: ignoreversion
Source: "super_installer_dependencies\{#LibRoadRunnerInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion
Source: "super_installer_dependencies\{#AntimonyInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion
Source: "super_installer_dependencies\{#TelPluginsInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion
Source: "libRoadrunner-installer-dependencies\NOTICE.TXT"; DestDir: "{app}"; DestName:"NOTICE2.TXT"; Flags: ignoreversion
Source: "libRoadrunner-installer-dependencies\{#MatplotlibInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
;Source: "libRoadrunner-installer-dependencies\{#DateutilInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
;Source: "libRoadrunner-installer-dependencies\{#PyparsingInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
;Source: "libRoadrunner-installer-dependencies\{#SixInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
Source: "libRoadrunner-installer-dependencies\{#NumpyInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
Source: "libRoadrunner-installer-dependencies\{#PyInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist
Source: "libRoadrunner-installer-dependencies\{#PipInstaller}"; DestDir: "{tmp}"; Flags: ignoreversion onlyifdoesntexist

Source: "spyder_dependencies\{#PyQtInstaller}\*"; DestDir: "C:\Python27\Lib\site-packages\{#PyQtInstaller}"; Flags: ignoreversion onlyifdoesntexist recursesubdirs createallsubdirs
Source: "spyder_dependencies\{#SipInstaller}"; DestDir: "C:\Python27\Lib\site-packages"; Flags: ignoreversion onlyifdoesntexist

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

[Run]
Filename: "{tmp}\{#PipInstaller}"; Verb: "open"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install python-dateutil"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install pyparsing"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install six"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

Filename: "{#Pip}"; Parameters: "install ipython[all]"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install sphinx"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install pyflakes"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install pylint"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install pep8"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#Pip}"; Parameters: "install psutil"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#LibRoadRunnerInstaller}"; Parameters: "/SILENT"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#AntimonyInstaller}"; Parameters: "/SILENT"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized
Filename: "{#TelPluginsInstaller}"; Parameters: "/SILENT"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

;SCIPY pip install has an error, may need a fortran compiler! mingw, but do we need Scipy?
;Filename: "{#Pip}"; Parameters: "install scipy"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

;MATPLOTLIB, on pip install, cannot find vcvarsall.bat, a symptom of missing the 2008 VS++ <-seriously you need to install a compiler
;Filename: "{#Pip}"; Parameters: "install matplotlib"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

;NUMPY, on pip install, cannot find vcvarsall.bat, a symptom of missing the 2008 VS++ <-seriously you need to install a compiler
;Filename: "{#Pip}"; Parameters: "install numpy"; WorkingDir: "{tmp}"; Flags: shellexec waituntilterminated runmaximized

[Code]
//////////////////////////////////////////////////////////////////////////////
const
  appDir = '{#AppDir}';
  pyReg = 'SOFTWARE\{#Py}\PythonCore\{#PyVer}\InstallPath';
  pyRegWow6443Node = 'SOFTWARE\Wow6432Node\{#Py}\PythonCore\{#PyVer}\InstallPath';

var
  installPython, installMatplot, installNumpy: Boolean;
  DefaultAppDirName: String;

//////////////////////////////////////////////////////////////////////////////
procedure ExitProcess(exitCode:integer);
  external 'ExitProcess@kernel32.dll stdcall';

//////////////////////////////////////////////////////////////////////////////
function GetPathForPythonSitePackages(): string;
var
  InstallPath: string;
begin

  if RegQueryStringValue(HKEY_LOCAL_MACHINE, pyReg, '', InstallPath) then
    begin
    Log('HKLM pyReg: '+ InstallPath);
    Result := InstallPath + 'Lib\site-packages\';
    end
  else
  if RegQueryStringValue(HKEY_CURRENT_USER, pyReg, '', InstallPath) then
    begin
    Log('HKCU pyReg: '+ InstallPath);
    Result := InstallPath + 'Lib\site-packages\';
    end
  else
  if RegQueryStringValue(HKEY_LOCAL_MACHINE, pyRegWow6443Node, '', InstallPath) then
    begin
    Log('HKLM pyRegWow6443Node: '+ InstallPath);
    Result := InstallPath + 'Lib\site-packages\';
    end
  else
    begin
    MsgBox('Our installer did not find your Python installation. You need '
    + 'Python to run {#MyAppName}. In the next step use [Your Python installation'
    + ' location]\Lib\site-packages\{#AppDir} directory.',mbError,MB_OK);
    //ExitProcess(1);
    end
end;

//////////////////////////////////////////////////////////////////////////////
function IsPythonInstalled(): Boolean;
var
  InstallPath: string; //not really used here
begin

  if RegQueryStringValue(HKEY_LOCAL_MACHINE, pyReg, '', InstallPath) then
    begin
    Result := True;
    end
  else
  if RegQueryStringValue(HKEY_CURRENT_USER, pyReg, '', InstallPath) then
    begin
    Result := True;
    end
  else
  if RegQueryStringValue(HKEY_LOCAL_MACHINE, pyRegWow6443Node, '', InstallPath) then
    begin
    Result := True;
    end
  else
    begin
    Result := False;
    end
end;

//////////////////////////////////////////////////////////////////////////////
function SetDefaultAppDirName(Value: String): String;
begin
  Result := DefaultAppDirName;
end;

//////////////////////////////////////////////////////////////////////////////
function IsInstalled(name: String): Boolean;
//function IsInstalled(name: string; version: string): boolean;  //ver not neeeded
var
  InstallPath: string;
  reg : string;
begin
  //reg := 'Software\' + name + '\' + version
  // + '\InstallPath'
  // Log('reg Python: ' + reg)

  //if Numpy/ matplotlib installed - direct check for file
  InstallPath := GetPathForPythonSitePackages() + name + '/__init__.py'
  Log('install dir: ' + InstallPath)
  if FileExists(InstallPath) then
  //if RegQueryStringValue(HKEY_CURRENT_USER, reg, 'InstallPath', InstallPath) then
   //numpy doesnt have a reg entry! (also gets its install path, not used here)
    begin
    Result := True;
    end
  else
    begin
    Result := False;
    end;
end;

//////////////////////////////////////////////////////////////////////////////
procedure RunMsiInstaller(execName: string);
var
  ResultCode: Integer;
  ExecPath: String;
  ExecCommand: String;
begin
  ExecPath := ExpandConstant('{tmp}\') + execName;
  ExecCommand := '/i ' + ExecPath + ''; //+ ' /qb'; //qb does it silently

  //Check that the msi installer file is present
  if FileExists(ExecPath) then
    begin
    Log('ExecPath exists : ' + ExecPath);
    end
  else
    begin
    Log('ExecPath doe not exist : ' + ExecPath);
    MsgBox('Could not find ' + execName + ' installer',mbError,MB_OK);
    ExitProcess(1);
    //something went wrong: hell or high water python installer must be there
    end;

  //execute msi installer, otherwie error and exit
  if not ShellExec('', 'msiexec.exe', ExecCommand, '', SW_SHOWNORMAL,
                   ewWaitUntilTerminated, ResultCode) then
      //msi exec not working
      MsgBox('Msi installer failed to run!' + #13#10 + ExecCommand + ' ' +
             SysErrorMessage(ResultCode), mbError, MB_OK);
end;

//////////////////////////////////////////////////////////////////////////////
function InitializeSetup(): Boolean;
var
tmpPy: String;
begin
  //if python installed get path for python site-packages
  //if isInstalled('{#Py}\PythonCore','{#PyVer}') then
  if IsPythonInstalled() then
  begin
    Log('Python: ' + 'True');
    installPython := False;
    //Python must be installed, get its path
    DefaultAppDirName := GetPathForPythonSitePackages() + AppDir;
    Log('SetDefaultAppDirName: ' + DefaultAppDirName);
  end
  else //Add Python to tmp folder [ // or download list.. ]
  begin
    Log('Python: ' + 'False');
    installPython := True;
    tmpPy := ExpandConstant('{tmp}\{#PyInstaller}');
    //FileCopy(ExpandConstant('{#PyInstaller}'), tmpPy, false);
    ExtractTemporaryFile('{#PyInstaller}')
    Log('tmpPy: '+ tmpPy);

    {//Check that the msi tmpPy installer file is present
    if FileExists(tmpPy) then
      begin
      Log('tmpPy exists : ' + tmpPy);
      end
    else
      begin
      Log('MSI tmpPy does not exist : ' + tmpPy);
      MsgBox('Could not find MSI' + tmpPy + ' installer',mbError,MB_OK);
      ExitProcess(1);
      //something went wrong: hell or high water python installer must be there
      end;
     }
    DefaultAppDirName := 'C:\Python27\Lib\site-packages\{#AppDir}' //pretend default path
                                                                   //will be used when python is installed
                                                                   //not seeing another way to prepopulate
                                                                   //the Dir Destination page.
                                                                   //installing Pyton earlier not an option
                                                                   //as {tmp} was not created yet, so cant
                                                                   //extract python installer yet
    //itd_addfile('{#PyInstallerURL}',ExpandConstant('{tmp}\{#PyInstaller}'));
    //itd_addfile('http://sbol.bhi.washington.edu/ppp/setup-dummyPython.exe',ExpandConstant('{tmp}\setup-dummyPython.exe'));
  end;

  Result := True; //Required for fwd progress, false would exist
end;

//////////////////////////////////////////////////////////////////////////////
procedure InitializeWizard();
begin
 //itd_init;  //turned off when packaging installers

  //Install Python now if needed, we want it in place before anything else is done
  if (installPython) then
     RunMsiInstaller('{#PyInstaller}');

  //Python must be installed, get its path
  DefaultAppDirName := GetPathForPythonSitePackages() + AppDir;
  Log('SetDefaultAppDirName: ' + DefaultAppDirName);

  //Check if Numpy is installed
  if IsInstalled('{#Numpy}') then
  //if IsInstalled('{#Numpy}','{#NumpyVer}') then  //ver not needed
    begin
    Log('Numpy: ' + 'True');
    installNumpy := False;
    end
  else
    //Add Numpy to d/l list
    begin
    Log('Numpy: ' + 'False');
    installNumpy := True;

    //filecopy(ExpandConstant('{#NumpyInstaller}'),ExpandConstant('{tmp}\{#NumpyInstaller}'),false);
    ExtractTemporaryFile('{#NumpyInstaller}');

    //The following were used to test downloader srategy
    //itd_addfile('http://sbol.bhi.washington.edu/ppp/setup-dummyNump.exe',
    //            ExpandConstant('{tmp}\setup-dummyNump.exe'));
    end;

  //Check if Matplotlib is installed
  if IsInstalled('{#Matplotlib}') then
  //if IsInstalled('{#Matplotlib}','{#MatplotlibVer}') then   //ver not needed
    begin
    Log('Matplotlib: ' + 'True');
    installMatplot := False;
    end
  else
    //Add Matplotlib to d/l list
    begin
    Log('Matplotlib: ' + 'False');
    installMatplot := True;

    //filecopy(ExpandConstant('{#MatplotlibInstaller}'),ExpandConstant('{tmp}\{#MatplotlibInstaller}'),false);
    ExtractTemporaryFile('{#MatplotlibInstaller}');
    //ExtractTemporaryFile('{#DateutilInstaller}');
    //ExtractTemporaryFile('{#PyparsingInstaller}');
    //ExtractTemporaryFile('{#SixInstaller}');

    //The following were used to test downloader srategy
    //td_addfile('http://sbol.bhi.washington.edu/ppp/setup-dummyMatplot.exe',
    //            ExpandConstant('{tmp}\setup-dummyMatplot.exe'));
    end;

  //Downloads turned off, packaging installers.
  //Start the download after the "Ready to install" screen is shown
  //itd_downloadafter(wpReady);
end;

//////////////////////////////////////////////////////////////////////////////
procedure RunOtherInstaller(execName: string);
var
  ResultCode: Integer;
begin
  if not Exec(ExpandConstant('{tmp}\' + execName), '', '', SW_SHOWNORMAL,
    ewWaitUntilTerminated, ResultCode)
  then
    MsgBox('Other installer failed to run!' + #13#10 + execName +
      SysErrorMessage(ResultCode), mbError, MB_OK);
end;

//////////////////////////////////////////////////////////////////////////////
// Install Numpy and Matplotlib if mising
procedure CurStepChanged(CurStep: TSetupStep);
var
   ResultCode: Integer;
begin
  if CurStep=ssInstall then //If on the installation step
  //Lets install those files that were downloaded for us
    begin
    if ForceDirectories(ExpandConstant('{app}')) then
      begin
      Log('app: ' + ExpandConstant('{app}'));
      if (installNumpy) then
        RunOtherInstaller('{#NumpyInstaller}');
      if (installMatplot) then
        begin
        RunOtherInstaller('{#MatplotlibInstaller}');
        //RunOtherInstaller('{#DateutilInstaller}');
        //RunOtherInstaller('{#PyparsingInstaller}');
        //RunOtherInstaller('{#SixInstaller}');
        end;
      end;
    end;
end;


Exclude ".*" files from installation.

Exclude ".*" files from installation.

git-svn-id: 4c7b768bc2e2a56aa1c56b1b5a9454ba68342430@2828 ac9c905b-388a-4ddf-9b6a-4063a022bc57

; Script generated by the Inno Setup Script Wizard.

#define MyAppName "Logtalk"
#define MyAppVerName "Logtalk 2.28.0"
#define MyAppPublisher "Logtalk.org"
#define MyAppURL "http://logtalk.org"
#define MyAppUrlName "Logtalk Web Site.url"

#define LOGTALKHOME "{reg:HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment,LOGTALKHOME|{pf}\Logtalk}"
#define LOGTALKUSER "{reg:HKCU\Environment,LOGTALKUSER|{userdocs}\logtalk}"

[Setup]
AppName={#MyAppName}
AppVerName={#MyAppVerName}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
ChangesEnvironment=yes
DefaultDirName={#LOGTALKHOME}
DefaultGroupName={#MyAppName}
DisableProgramGroupPage=yes
LicenseFile=C:\logtalk\LICENSE
InfoBeforeFile=C:\logtalk\README
OutputBaseFilename=lgt2280
Compression=lzma
SolidCompression=yes

VersionInfoVersion=2.28.0
VersionInfoCopyright= Paulo Moura, 1998-2006

AllowRootDirectory=yes
UninstallFilesDir="{userdocs}\Logtalk uninstaller"

MinVersion=0,5.0

[Types]
Name: "full"; Description: "Full installation (recommended)"
Name: "base"; Description: "Base system installation"
Name: "user"; Description: "User-modifiable files installation (must be run by all end-users)"
Name: "prolog"; Description: "Prolog integration (see documentation for compatibility details)"
Name: "custom"; Description: "Custom installation"; Flags: iscustom

[Components]
Name: "base"; Description: "Base system"; Types: full base custom; Flags: disablenouninstallwarning
Name: "user"; Description: "User-modifiable files"; Types: full user custom; Flags: checkablealone
Name: "user\backup"; Description: "Backup current user-modifiable files"; Types: full user custom
Name: "prolog"; Description: "Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\ciao"; Description: "Ciao Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\eclipse"; Description: "ECLiPSe integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\gprolog"; Description: "GNU Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\plc"; Description: "K-Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\sicstus"; Description: "SICStus Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\swi"; Description: "SWI-Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\xsb"; Description: "XSB integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\yap"; Description: "YAP integration"; Types: full prolog custom; Flags: disablenouninstallwarning

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Messages]
BeveledLabel=      Logtalk 2.28.0  Paulo Moura, 1998-2006

[Dirs]
Name: {code:GetLgtUserDir}; Components: user; Flags: uninsneveruninstall
Name: "{userdocs}\Logtalk uninstaller"

[Files]
Source: "C:\logtalk\compiler\*"; Excludes: ".*,CVS"; DestDir: "{app}\compiler"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\configs\*"; Excludes: ".*,CVS"; DestDir: "{app}\configs"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\contributions\*"; Excludes: ".*,CVS"; DestDir: "{app}\contributions"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\examples\*"; Excludes: ".*,CVS"; DestDir: "{app}\examples"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\libpaths\*"; Excludes: ".*,CVS"; DestDir: "{app}\libpaths"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\library\*"; Excludes: ".*,CVS"; DestDir: "{app}\library"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\manuals\*"; Excludes: ".*,CVS"; DestDir: "{app}\manuals"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\scripts\*"; Excludes: ".*,CVS"; DestDir: "{app}\scripts"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\wenv\*"; Excludes: ".*,CVS"; DestDir: "{app}\wenv"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\xml\*"; Excludes: ".*,CVS"; DestDir: "{app}\xml"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\BIBLIOGRAPHY"; DestDir: "{app}"; DestName: "BIBLIOGRAPHY.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\INSTALL"; DestDir: "{app}"; DestName: "INSTALL.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\LICENSE"; DestDir: "{app}"; DestName: "LICENSE.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\QUICK_START"; DestDir: "{app}"; DestName: "QUICK_START.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\README"; DestDir: "{app}"; DestName: "README.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\RELEASE_NOTES"; DestDir: "{app}"; DestName: "RELEASE_NOTES.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\UPGRADING"; DestDir: "{app}"; DestName: "UPGRADING.txt"; Components: base; Flags: ignoreversion

Source: "C:\logtalk\configs\*"; Excludes: ".*,CVS"; DestDir: "{code:GetLgtUserDir}\configs"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\contributions\*"; Excludes: ".*,CVS"; DestDir: "{code:GetLgtUserDir}\contributions"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\examples\*"; Excludes: ".*,CVS"; DestDir: "{code:GetLgtUserDir}\examples"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\libpaths\*"; Excludes: ".*,CVS"; DestDir: "{code:GetLgtUserDir}\libpaths"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\library\*"; Excludes: ".*,CVS"; DestDir: "{code:GetLgtUserDir}\library"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\xml\*"; Excludes: ".*,CVS"; DestDir: "{code:GetLgtUserDir}\xml"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall

[INI]
Filename: "{app}\{#MyAppUrlName}"; Section: "InternetShortcut"; Key: "URL"; String: "{#MyAppURL}"; Components: base

[Icons]
Name: "{group}\{#MyAppName} Bibliography"; Filename: "{app}\BIBLIOGRAPHY.txt"; Components: base
Name: "{group}\{#MyAppName} Documentation"; Filename: "{app}\manuals\index.html"; Components: base
Name: "{group}\{#MyAppName} License"; Filename: "{app}\LICENSE.txt"; Components: base
Name: "{group}\{#MyAppName} Release Notes"; Filename: "{app}\RELEASE_NOTES.txt"; Components: base
Name: "{group}\{#MyAppName} Read Me"; Filename: "{app}\README.txt"; Components: base

Name: "{group}\{#MyAppName} Web Site"; Filename: "{app}\{#MyAppUrlName}"; Components: base
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"; Components: base

Name: "{code:GetLgtUserDir}\manuals"; Filename: "{app}\manuals"; Components: user; Flags: uninsneveruninstall
Name: "{code:GetLgtUserDir}\wenv"; Filename: "{app}\wenv"; Components: user; Flags: uninsneveruninstall

[Registry]
Root: HKLM; Subkey: "SYSTEM\CurrentControlSet\Control\Session Manager\Environment"; ValueType: expandsz; ValueName: "LOGTALKHOME"; ValueData: "{app}"; Components: base; Flags: deletevalue uninsdeletevalue
Root: HKCU; Subkey: "Environment"; ValueType: expandsz; ValueName: "LOGTALKUSER"; ValueData: "{code:GetLgtUserDir}"; Flags: createvalueifdoesntexist

[Run]
Filename: "{cmd}"; Parameters: "/C for /R ""{app}"" %D in (NOTES) do ren ""%D"" *.txt"; Components: base; Flags: runhidden
Filename: "{cmd}"; Parameters: "/C for /R ""{app}"" %D in (SCRIPT) do ren ""%D"" *.txt"; Components: base; Flags: runhidden

Filename: "{cmd}"; Parameters: "/C for /R ""{code:GetLgtUserDir}"" %D in (NOTES) do ren ""%D"" *.txt"; Components: user; Flags: runhidden
Filename: "{cmd}"; Parameters: "/C for /R ""{code:GetLgtUserDir}"" %D in (SCRIPT) do ren ""%D"" *.txt"; Components: user; Flags: runhidden

Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_ciaolgt.js"""; Description: "Ciao Prolog integration"; Components: prolog\ciao
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_eclipselgt.js"""; Description: "ECLiPSe integration"; Components: prolog\eclipse
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_gplgt.js"""; Description: "GNU Prolog integration"; Components: prolog\gprolog
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_plclgt.js"""; Description: "K-Prolog integration"; Components: prolog\plc
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_sicstuslgt.js"""; Description: "SICStus Prolog integration"; Components: prolog\sicstus
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_swilgt.js"""; Description: "SWI-Prolog integration"; Components: prolog\swi
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_xsblgt.js"""; Description: "XSB integration"; Components: prolog\xsb
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_yaplgt.js"""; Description: "YAP integration"; Components: prolog\yap

Filename: "{app}\RELEASE_NOTES.txt"; Description: "View the release notes"; Components: base; Flags: postinstall shellexec skipifsilent
Filename: "{app}\INSTALL.txt"; Description: "Review the install instructions for completing your setup"; Components: base; Flags: postinstall shellexec skipifsilent

[UninstallDelete]
Type: filesandordirs; Name: "{app}"; Components: base
Type: filesandordirs; Name: "{group}"; Components: base

[Code]
var
  LgtUserDirPage: TInputDirWizardPage;
  WarningPage: TOutputMsgWizardPage;
  Explanation, Warning: String;

procedure InitializeWizard;
begin
  Explanation := 'Select the folder in which Setup should install Logtalk user-modifiable files, then click Next.'
                 + Chr(13) + Chr(13)
                 + 'These files allows each user to independently customize Logtalk and to freely modify the provided programming examples.'
                 + Chr(13) + Chr(13)
                 + 'A copy of these files must exist in the user home folder in order to use the Logtalk-Prolog integration scripts available from the Start Menu.'
                 + Chr(13) + Chr(13)
                 + 'Addtional end-users may use this installer to make a copy of these files on their home folders after a full installation of Logtalk.';
  LgtUserDirPage := CreateInputDirPage(wpSelectDir,
    'Select Folder for Logtalk User-modifiable Files', 'Where should Logtalk user-modifiable files be installed?',
    Explanation,
    False, 'New Folder');
  LgtUserDirPage.Add('');
  LgtUserDirPage.Values[0] := ExpandConstant('{#LOGTALKUSER}');
  if not IsAdminLoggedOn then
  begin
    Warning := 'Full installation of Logtalk requires an administrative user.'
               + Chr(13) + Chr(13)
               + 'If the base Logtalk system is already installed, you may proceed in order to setup Logtalk for you as an end-user.'
               + Chr(13) + Chr(13)
               + 'If Logtalk is already set for you, this installer will make a backup copy of your current files (if you choose the same installation folder) and will restore all user-modifiable files to their initial, pristine state.';
    WarningPage := CreateOutputMsgPage(wpWelcome,
  'Information', 'Please read the following important information before continuing.', Warning);
  end
end;

function GetLgtUserDir(Param: String): String;
begin
  Result := LgtUserDirPage.Values[0]
end;

function GetCurrentDate(Param: String): String;
begin
  Result := GetDateTimeString('dddddd tt', '-', '-')
end;

function ShouldSkipPage(PageID: Integer): Boolean;
begin
  if (PageID = wpSelectDir) and not IsAdminLoggedOn then
    Result := True
  else if (PageID = wpSelectComponents) and not IsAdminLoggedOn then
  begin
    WizardForm.TypesCombo.ItemIndex := 2;
    WizardForm.TypesCombo.OnChange(nil);
    Result := True
  end
  else if (PageID = wpReady) and not IsAdminLoggedOn then
    Result := True
  else
    Result := False;
end;

procedure CurStepChanged(CurStep: TSetupStep);
begin
  if (CurStep = ssInstall) and DirExists(LgtUserDirPage.Values[0]) and (pos('backup', WizardSelectedComponents(False)) > 0) then
    RenameFile(LgtUserDirPage.Values[0], LgtUserDirPage.Values[0] + ' backup ' + GetDateTimeString('dddddd tt', '-', '-'))
end;

; Script generated by the Inno Setup Script Wizard.

#define MyAppName "Logtalk"
#define MyAppVerName "Logtalk 2.28.0"
#define MyAppPublisher "Logtalk.org"
#define MyAppURL "http://logtalk.org"
#define MyAppUrlName "Logtalk Web Site.url"

#define LOGTALKHOME "{reg:HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment,LOGTALKHOME|{pf}\Logtalk}"
#define LOGTALKUSER "{reg:HKCU\Environment,LOGTALKUSER|{userdocs}\logtalk}"

[Setup]
AppName={#MyAppName}
AppVerName={#MyAppVerName}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
ChangesEnvironment=yes
DefaultDirName={#LOGTALKHOME}
DefaultGroupName={#MyAppName}
DisableProgramGroupPage=yes
LicenseFile=C:\logtalk\LICENSE
InfoBeforeFile=C:\logtalk\README
OutputBaseFilename=lgt2280
Compression=lzma
SolidCompression=yes

VersionInfoVersion=2.28.0
VersionInfoCopyright= Paulo Moura, 1998-2006

AllowRootDirectory=yes
UninstallFilesDir="{userdocs}\Logtalk uninstaller"

MinVersion=0,5.0

[Types]
Name: "full"; Description: "Full installation (recommended)"
Name: "base"; Description: "Base system installation"
Name: "user"; Description: "User-modifiable files installation (must be run by all end-users)"
Name: "prolog"; Description: "Prolog integration (see documentation for compatibility details)"
Name: "custom"; Description: "Custom installation"; Flags: iscustom

[Components]
Name: "base"; Description: "Base system"; Types: full base custom; Flags: disablenouninstallwarning
Name: "user"; Description: "User-modifiable files"; Types: full user custom; Flags: checkablealone
Name: "user\backup"; Description: "Backup current user-modifiable files"; Types: full user custom
Name: "prolog"; Description: "Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\ciao"; Description: "Ciao Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\eclipse"; Description: "ECLiPSe integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\gprolog"; Description: "GNU Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\plc"; Description: "K-Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\sicstus"; Description: "SICStus Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\swi"; Description: "SWI-Prolog integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\xsb"; Description: "XSB integration"; Types: full prolog custom; Flags: disablenouninstallwarning
Name: "prolog\yap"; Description: "YAP integration"; Types: full prolog custom; Flags: disablenouninstallwarning

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Messages]
BeveledLabel=      Logtalk 2.28.0  Paulo Moura, 1998-2006

[Dirs]
Name: {code:GetLgtUserDir}; Components: user; Flags: uninsneveruninstall
Name: "{userdocs}\Logtalk uninstaller"

[Files]
Source: "C:\logtalk\compiler\*"; Excludes: "CVS"; DestDir: "{app}\compiler"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\configs\*"; Excludes: "CVS"; DestDir: "{app}\configs"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\contributions\*"; Excludes: "CVS"; DestDir: "{app}\contributions"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\examples\*"; Excludes: "CVS"; DestDir: "{app}\examples"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\libpaths\*"; Excludes: "CVS"; DestDir: "{app}\libpaths"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\library\*"; Excludes: "CVS"; DestDir: "{app}\library"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\manuals\*"; Excludes: "CVS"; DestDir: "{app}\manuals"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\scripts\*"; Excludes: "CVS"; DestDir: "{app}\scripts"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\wenv\*"; Excludes: "CVS"; DestDir: "{app}\wenv"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\xml\*"; Excludes: "CVS"; DestDir: "{app}\xml"; Components: base; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\logtalk\BIBLIOGRAPHY"; DestDir: "{app}"; DestName: "BIBLIOGRAPHY.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\INSTALL"; DestDir: "{app}"; DestName: "INSTALL.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\LICENSE"; DestDir: "{app}"; DestName: "LICENSE.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\QUICK_START"; DestDir: "{app}"; DestName: "QUICK_START.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\README"; DestDir: "{app}"; DestName: "README.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\RELEASE_NOTES"; DestDir: "{app}"; DestName: "RELEASE_NOTES.txt"; Components: base; Flags: ignoreversion
Source: "C:\logtalk\UPGRADING"; DestDir: "{app}"; DestName: "UPGRADING.txt"; Components: base; Flags: ignoreversion

Source: "C:\logtalk\configs\*"; Excludes: "CVS"; DestDir: "{code:GetLgtUserDir}\configs"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\contributions\*"; Excludes: "CVS"; DestDir: "{code:GetLgtUserDir}\contributions"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\examples\*"; Excludes: "CVS"; DestDir: "{code:GetLgtUserDir}\examples"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\libpaths\*"; Excludes: "CVS"; DestDir: "{code:GetLgtUserDir}\libpaths"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\library\*"; Excludes: "CVS"; DestDir: "{code:GetLgtUserDir}\library"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall
Source: "C:\logtalk\xml\*"; Excludes: "CVS"; DestDir: "{code:GetLgtUserDir}\xml"; Components: user; Flags: ignoreversion recursesubdirs createallsubdirs uninsneveruninstall

[INI]
Filename: "{app}\{#MyAppUrlName}"; Section: "InternetShortcut"; Key: "URL"; String: "{#MyAppURL}"; Components: base

[Icons]
Name: "{group}\{#MyAppName} Bibliography"; Filename: "{app}\BIBLIOGRAPHY.txt"; Components: base
Name: "{group}\{#MyAppName} Documentation"; Filename: "{app}\manuals\index.html"; Components: base
Name: "{group}\{#MyAppName} License"; Filename: "{app}\LICENSE.txt"; Components: base
Name: "{group}\{#MyAppName} Release Notes"; Filename: "{app}\RELEASE_NOTES.txt"; Components: base
Name: "{group}\{#MyAppName} Read Me"; Filename: "{app}\README.txt"; Components: base

Name: "{group}\{#MyAppName} Web Site"; Filename: "{app}\{#MyAppUrlName}"; Components: base
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"; Components: base

Name: "{code:GetLgtUserDir}\manuals"; Filename: "{app}\manuals"; Components: user; Flags: uninsneveruninstall
Name: "{code:GetLgtUserDir}\wenv"; Filename: "{app}\wenv"; Components: user; Flags: uninsneveruninstall

[Registry]
Root: HKLM; Subkey: "SYSTEM\CurrentControlSet\Control\Session Manager\Environment"; ValueType: expandsz; ValueName: "LOGTALKHOME"; ValueData: "{app}"; Components: base; Flags: deletevalue uninsdeletevalue
Root: HKCU; Subkey: "Environment"; ValueType: expandsz; ValueName: "LOGTALKUSER"; ValueData: "{code:GetLgtUserDir}"; Flags: createvalueifdoesntexist

[Run]
Filename: "{cmd}"; Parameters: "/C for /R ""{app}"" %D in (NOTES) do ren ""%D"" *.txt"; Components: base; Flags: runhidden
Filename: "{cmd}"; Parameters: "/C for /R ""{app}"" %D in (SCRIPT) do ren ""%D"" *.txt"; Components: base; Flags: runhidden

Filename: "{cmd}"; Parameters: "/C for /R ""{code:GetLgtUserDir}"" %D in (NOTES) do ren ""%D"" *.txt"; Components: user; Flags: runhidden
Filename: "{cmd}"; Parameters: "/C for /R ""{code:GetLgtUserDir}"" %D in (SCRIPT) do ren ""%D"" *.txt"; Components: user; Flags: runhidden

Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_ciaolgt.js"""; Description: "Ciao Prolog integration"; Components: prolog\ciao
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_eclipselgt.js"""; Description: "ECLiPSe integration"; Components: prolog\eclipse
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_gplgt.js"""; Description: "GNU Prolog integration"; Components: prolog\gprolog
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_plclgt.js"""; Description: "K-Prolog integration"; Components: prolog\plc
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_sicstuslgt.js"""; Description: "SICStus Prolog integration"; Components: prolog\sicstus
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_swilgt.js"""; Description: "SWI-Prolog integration"; Components: prolog\swi
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_xsblgt.js"""; Description: "XSB integration"; Components: prolog\xsb
Filename: "{cmd}"; Parameters: "/C cscript ""{app}\scripts\make_yaplgt.js"""; Description: "YAP integration"; Components: prolog\yap

Filename: "{app}\RELEASE_NOTES.txt"; Description: "View the release notes"; Components: base; Flags: postinstall shellexec skipifsilent
Filename: "{app}\INSTALL.txt"; Description: "Review the install instructions for completing your setup"; Components: base; Flags: postinstall shellexec skipifsilent

[UninstallDelete]
Type: filesandordirs; Name: "{app}"; Components: base
Type: filesandordirs; Name: "{group}"; Components: base

[Code]
var
  LgtUserDirPage: TInputDirWizardPage;
  WarningPage: TOutputMsgWizardPage;
  Explanation, Warning: String;

procedure InitializeWizard;
begin
  Explanation := 'Select the folder in which Setup should install Logtalk user-modifiable files, then click Next.'
                 + Chr(13) + Chr(13)
                 + 'These files allows each user to independently customize Logtalk and to freely modify the provided programming examples.'
                 + Chr(13) + Chr(13)
                 + 'A copy of these files must exist in the user home folder in order to use the Logtalk-Prolog integration scripts available from the Start Menu.'
                 + Chr(13) + Chr(13)
                 + 'Addtional end-users may use this installer to make a copy of these files on their home folders after a full installation of Logtalk.';
  LgtUserDirPage := CreateInputDirPage(wpSelectDir,
    'Select Folder for Logtalk User-modifiable Files', 'Where should Logtalk user-modifiable files be installed?',
    Explanation,
    False, 'New Folder');
  LgtUserDirPage.Add('');
  LgtUserDirPage.Values[0] := ExpandConstant('{#LOGTALKUSER}');
  if not IsAdminLoggedOn then
  begin
    Warning := 'Full installation of Logtalk requires an administrative user.'
               + Chr(13) + Chr(13)
               + 'If the base Logtalk system is already installed, you may proceed in order to setup Logtalk for you as an end-user.'
               + Chr(13) + Chr(13)
               + 'If Logtalk is already set for you, this installer will make a backup copy of your current files (if you choose the same installation folder) and will restore all user-modifiable files to their initial, pristine state.';
    WarningPage := CreateOutputMsgPage(wpWelcome,
  'Information', 'Please read the following important information before continuing.', Warning);
  end
end;

function GetLgtUserDir(Param: String): String;
begin
  Result := LgtUserDirPage.Values[0]
end;

function GetCurrentDate(Param: String): String;
begin
  Result := GetDateTimeString('dddddd tt', '-', '-')
end;

function ShouldSkipPage(PageID: Integer): Boolean;
begin
  if (PageID = wpSelectDir) and not IsAdminLoggedOn then
    Result := True
  else if (PageID = wpSelectComponents) and not IsAdminLoggedOn then
  begin
    WizardForm.TypesCombo.ItemIndex := 2;
    WizardForm.TypesCombo.OnChange(nil);
    Result := True
  end
  else if (PageID = wpReady) and not IsAdminLoggedOn then
    Result := True
  else
    Result := False;
end;

procedure CurStepChanged(CurStep: TSetupStep);
begin
  if (CurStep = ssInstall) and DirExists(LgtUserDirPage.Values[0]) and (pos('backup', WizardSelectedComponents(False)) > 0) then
    RenameFile(LgtUserDirPage.Values[0], LgtUserDirPage.Values[0] + ' backup ' + GetDateTimeString('dddddd tt', '-', '-'))
end;


removed no longer needed licenses folder and copying.txt which makes the installers actually build

git-svn-id: 5c3b06693d750a6aefbf1081b6b7d57c0165fdb2@490294 13f79535-47bb-0310-9956-ffa450edef68

#define MyAppName "${app}"
#define MyAppVerName "${app} ${app.version}"
#define MyAppVersion "${app.version}"
#define MyAppPublisher "${app.author}"
#define MyAppURL "${app.url}"
#define MyAppExeName "${app}w.exe"
#define MyAppCompanyName "${app.company.name}"
#define MyAppDescription "${app.description}"
#define MyAppCopyright "Copyright (c) ${app.copyright.year} ${app.company.name}"

; Set this constant to the path where your installation image resides
#define SourceBase "${image.basedir}"

[Setup]
AppName={#MyAppName}
AppVerName={#MyAppVerName}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\${app}-${app.version}
DefaultGroupName={#MyAppName}
LicenseFile={#SourceBase}\${app.license.name}
OutputDir="${installer.output.directory}"
OutputBaseFilename=${app.final.name}
SetupIconFile={#SourceBase}\${app.icon.name}
Compression=lzma
SolidCompression=true
VersionInfoCompany={#MyAppCompanyName}
VersionInfoDescription={#MyAppDescription}
AppCopyright={#MyAppCopyright}
ShowLanguageDialog=yes
AppVersion={#MyAppVersion}

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

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

[Files]
; bin directory targets
Source: {#SourceBase}\bin\${app}w.exe; DestDir: {app}\bin; Tasks: ; Languages:
Source: {#SourceBase}\bin\${app}.exe; DestDir: {app}\bin
Source: {#SourceBase}\bin\bootstrapper.jar; DestDir: {app}\bin; DestName: bootstrapper.jar
Source: {#SourceBase}\bin\logger.jar; DestDir: {app}\bin; DestName: logger.jar
Source: {#SourceBase}\bin\triplesec-tools.jar; DestDir: {app}\bin; DestName: triplesec-tools.jar
Source: {#SourceBase}\bin\triplesec-admin.jar; DestDir: {app}\bin; DestName: triplesec-admin.jar
Source: {#SourceBase}\bin\daemon.jar; DestDir: {app}\bin; DestName: daemon.jar
; conf directory targets
Source: {#SourceBase}\conf\log4j.properties; DestDir: {app}\conf; DestName: log4j.properties
Source: {#SourceBase}\conf\server.xml; DestDir: {app}\conf; DestName: server.xml
Source: {#SourceBase}\conf\bootstrapper.properties; DestDir: {app}\conf; DestName: bootstrapper.properties
Source: {#SourceBase}\conf\00server.ldif; DestDir: {app}\conf; DestName: 00server.ldif
; top level directory targets
Source: {#SourceBase}\${app.license.name}; DestDir: {app}; DestName: ${app.license.name}
Source: {#SourceBase}\${app.readme.name}; DestDir: {app}; DestName: ${app.readme.name}
Source: {#SourceBase}\${app.icon.name}; DestDir: {app}; DestName: ${app.icon.name}
Source: {#SourceBase}\admin-tool.ico; DestDir: {app}; DestName: admin-tool.ico
; empty var & lib\ext directory structure
Source: {#SourceBase}\var\*; DestDir: "{app}\var\"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: {#SourceBase}\webapps\*; DestDir: "{app}\webapps\"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: {#SourceBase}\guardian\*; DestDir: "{app}\guardian\"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: {#SourceBase}\lib\ext; DestDir: "{app}\lib"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: {#SourceBase}\lib\tools\*; DestDir: "{app}\lib\tools\"; Flags: ignoreversion recursesubdirs createallsubdirs
; lib directory targets
${app.lib.jars}
${docs.directive}
${sources.directive}
${notice.file}

[Icons]
Name: {group}\Service Settings; Filename: {app}\bin\${app}w.exe; Parameters: //ES//${app}; IconIndex: 0
Name: {userdesktop}\{#MyAppName}; Filename: {app}\bin\${app}w.exe; Tasks: desktopicon; Parameters: //ES//${app}; IconIndex: 0; Languages:
Name: {group}\Tray Monitor; Filename: {app}\bin\${app}w.exe; Parameters: //MS//${app}; IconIndex: 0
Name: {group}\Test Service; Filename: {app}\bin\${app}.exe; IconIndex: 0
Name: {group}\Admin; Filename: %JAVA_HOME%\bin\java.exe; Parameters: "-jar ""{app}\bin\triplesec-admin.jar"" ""{app}"""; IconFilename: {app}\admin-tool.ico; WorkingDir: "{app}"

[Run]
Filename: {app}\bin\${app}.exe; WorkingDir: {app}\bin; Tasks: ; Languages: ; Parameters: "//IS//${app.displayname} --Description=""${app.description} Service ${app.version} - ${app.url}"" --DisplayName=${app.displayname} --Install=""{app}\bin\${app}.exe"" --StartMode=jvm --StopMode=jvm --StartClass=org.apache.directory.daemon.ProcrunBootstrapper --StartMethod prunsrvStart --StartParams=""{app}"" --StopClass=org.apache.directory.daemon.ProcrunBootstrapper --StopMethod prunsrvStop --StopParams=""{app}"" --Startup=manual --JvmOptions=""-D${app}.home={app}"" --Classpath=""{app}\bin\bootstrapper.jar;{app}\conf;{app}\bin\logger.jar;{app}\bin\daemon.jar"" --LogPath=""{app}\var\log"" --LogPrefix=${app}.log --LogLevel=debug --StdOutput=""{app}\var\log\${app}-stdout.log"" --StdError=""{app}\var\log\${app}-stderr.log"""; Flags: runhidden
Filename: {app}\bin\${app}w.exe; Parameters: //ES//${app.displayname}; WorkingDir: {app}\bin; Flags: postinstall nowait; Description: Runs the configuration manager for the ${app} windows service

[Registry]

[UninstallRun]
Filename: {app}\bin\${app}.exe; WorkingDir: {app}\bin; Parameters: //DS//${app.displayname}

#define MyAppName "${app}"
#define MyAppVerName "${app} ${app.version}"
#define MyAppVersion "${app.version}"
#define MyAppPublisher "${app.author}"
#define MyAppURL "${app.url}"
#define MyAppExeName "${app}w.exe"
#define MyAppCompanyName "${app.company.name}"
#define MyAppDescription "${app.description}"
#define MyAppCopyright "Copyright (c) ${app.copyright.year} ${app.company.name}"

; Set this constant to the path where your installation image resides
#define SourceBase "${image.basedir}"

[Setup]
AppName={#MyAppName}
AppVerName={#MyAppVerName}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\${app}-${app.version}
DefaultGroupName={#MyAppName}
LicenseFile={#SourceBase}\${app.license.name}
OutputDir="${installer.output.directory}"
OutputBaseFilename=${app.final.name}
SetupIconFile={#SourceBase}\${app.icon.name}
Compression=lzma
SolidCompression=true
VersionInfoCompany={#MyAppCompanyName}
VersionInfoDescription={#MyAppDescription}
AppCopyright={#MyAppCopyright}
ShowLanguageDialog=yes
AppVersion={#MyAppVersion}

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

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

[Files]
; bin directory targets
Source: {#SourceBase}\bin\${app}w.exe; DestDir: {app}\bin; Tasks: ; Languages:
Source: {#SourceBase}\bin\${app}.exe; DestDir: {app}\bin
Source: {#SourceBase}\bin\bootstrapper.jar; DestDir: {app}\bin; DestName: bootstrapper.jar
Source: {#SourceBase}\bin\logger.jar; DestDir: {app}\bin; DestName: logger.jar
Source: {#SourceBase}\bin\triplesec-tools.jar; DestDir: {app}\bin; DestName: triplesec-tools.jar
Source: {#SourceBase}\bin\triplesec-admin.jar; DestDir: {app}\bin; DestName: triplesec-admin.jar
Source: {#SourceBase}\bin\daemon.jar; DestDir: {app}\bin; DestName: daemon.jar
; conf directory targets
Source: {#SourceBase}\conf\log4j.properties; DestDir: {app}\conf; DestName: log4j.properties
Source: {#SourceBase}\conf\server.xml; DestDir: {app}\conf; DestName: server.xml
Source: {#SourceBase}\conf\bootstrapper.properties; DestDir: {app}\conf; DestName: bootstrapper.properties
Source: {#SourceBase}\conf\00server.ldif; DestDir: {app}\conf; DestName: 00server.ldif
; top level directory targets
Source: {#SourceBase}\${app.license.name}; DestDir: {app}; DestName: ${app.license.name}
Source: {#SourceBase}\${app.readme.name}; DestDir: {app}; DestName: ${app.readme.name}
Source: {#SourceBase}\${app.icon.name}; DestDir: {app}; DestName: ${app.icon.name}
Source: {#SourceBase}\admin-tool.ico; DestDir: {app}; DestName: admin-tool.ico
Source: {#SourceBase}\COPYING.txt; DestDir: {app}; DestName: COPYING.txt
; empty var & lib\ext directory structure
Source: {#SourceBase}\var\*; DestDir: "{app}\var\"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: {#SourceBase}\licenses\*; DestDir: "{app}\licenses\"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: {#SourceBase}\webapps\*; DestDir: "{app}\webapps\"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: {#SourceBase}\guardian\*; DestDir: "{app}\guardian\"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: {#SourceBase}\lib\ext; DestDir: "{app}\lib"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: {#SourceBase}\lib\tools\*; DestDir: "{app}\lib\tools\"; Flags: ignoreversion recursesubdirs createallsubdirs
; lib directory targets
${app.lib.jars}
${docs.directive}
${sources.directive}
${notice.file}

[Icons]
Name: {group}\Service Settings; Filename: {app}\bin\${app}w.exe; Parameters: //ES//${app}; IconIndex: 0
Name: {userdesktop}\{#MyAppName}; Filename: {app}\bin\${app}w.exe; Tasks: desktopicon; Parameters: //ES//${app}; IconIndex: 0; Languages:
Name: {group}\Tray Monitor; Filename: {app}\bin\${app}w.exe; Parameters: //MS//${app}; IconIndex: 0
Name: {group}\Test Service; Filename: {app}\bin\${app}.exe; IconIndex: 0
Name: {group}\Admin; Filename: %JAVA_HOME%\bin\java.exe; Parameters: "-jar ""{app}\bin\triplesec-admin.jar"" ""{app}"""; IconFilename: {app}\admin-tool.ico; WorkingDir: "{app}"

[Run]
Filename: {app}\bin\${app}.exe; WorkingDir: {app}\bin; Tasks: ; Languages: ; Parameters: "//IS//${app.displayname} --Description=""${app.description} Service ${app.version} - ${app.url}"" --DisplayName=${app.displayname} --Install=""{app}\bin\${app}.exe"" --StartMode=jvm --StopMode=jvm --StartClass=org.apache.directory.daemon.ProcrunBootstrapper --StartMethod prunsrvStart --StartParams=""{app}"" --StopClass=org.apache.directory.daemon.ProcrunBootstrapper --StopMethod prunsrvStop --StopParams=""{app}"" --Startup=manual --JvmOptions=""-D${app}.home={app}"" --Classpath=""{app}\bin\bootstrapper.jar;{app}\conf;{app}\bin\logger.jar;{app}\bin\daemon.jar"" --LogPath=""{app}\var\log"" --LogPrefix=${app}.log --LogLevel=debug --StdOutput=""{app}\var\log\${app}-stdout.log"" --StdError=""{app}\var\log\${app}-stderr.log"""; Flags: runhidden
Filename: {app}\bin\${app}w.exe; Parameters: //ES//${app.displayname}; WorkingDir: {app}\bin; Flags: postinstall nowait; Description: Runs the configuration manager for the ${app} windows service

[Registry]

[UninstallRun]
Filename: {app}\bin\${app}.exe; WorkingDir: {app}\bin; Parameters: //DS//${app.displayname}


Version update to 2.9.1

Version update to 2.9.1

git-svn-id: 4a0daf30c0bbd291b3bc5fe8f058bf11ee523347@525 7d282ba1-3ae6-0310-8f9b-c9008a0864d2

#define ver "2.9.1-b525";

[Setup]
AppName=Tigase Server
AppVersion={#ver}
AppVerName=Tigase XMPP Server {#ver}
AppPublisher=tigase.org
AppPublisherURL=http://www.tigase.org/
AppSupportURL=http://www.tigase.org/
AppUpdatesURL=http://www.tigase.org/
DefaultDirName={pf}\Tigase
DefaultGroupName=Tigase Server
AllowNoIcons=true
LicenseFile=Licence.txt
OutputDir=..\packages
OutputBaseFilename=tigase-server-{#ver}
Compression=lzma
SolidCompression=true
UninstallDisplayIcon={app}\Tigase.ico
VersionInfoCopyright=Artur Hefczyc

[Languages]
Name: english; MessagesFile: compiler:Default.isl
Name: basque; MessagesFile: compiler:Languages\Basque.isl
Name: brazilianportuguese; MessagesFile: compiler:Languages\BrazilianPortuguese.isl
Name: catalan; MessagesFile: compiler:Languages\Catalan.isl
Name: czech; MessagesFile: compiler:Languages\Czech.isl
Name: danish; MessagesFile: compiler:Languages\Danish.isl
Name: dutch; MessagesFile: compiler:Languages\Dutch.isl
Name: finnish; MessagesFile: compiler:Languages\Finnish.isl
Name: french; MessagesFile: compiler:Languages\French.isl
Name: german; MessagesFile: compiler:Languages\German.isl
Name: hungarian; MessagesFile: compiler:Languages\Hungarian.isl
Name: italian; MessagesFile: compiler:Languages\Italian.isl
Name: norwegian; MessagesFile: compiler:Languages\Norwegian.isl
Name: polish; MessagesFile: compiler:Languages\Polish.isl
Name: portuguese; MessagesFile: compiler:Languages\Portuguese.isl
Name: russian; MessagesFile: compiler:Languages\Russian.isl
Name: slovak; MessagesFile: compiler:Languages\Slovak.isl
Name: slovenian; MessagesFile: compiler:Languages\Slovenian.isl
Name: spanish; MessagesFile: compiler:Languages\Spanish.isl

[Files]
Source: wrapper\wrapper.exe; DestDir: {app}; Flags: ignoreversion; Languages:
Source: ..\certs\*; DestDir: {app}\certs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\docs-tigase-server\*; DestDir: {app}\docs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\etc\*; DestDir: {app}\etc; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\jars\*; DestDir: {app}\jars; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\libs\*; DestDir: {app}\libs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\database\mysql-schema.sql; DestDir: {app}\database\mysql-schema.sql; Flags: ignoreversion
Source: ..\database\postgresql-schema.sql; DestDir: {app}\database\postgresql-schema.sql; Flags: ignoreversion
Source: wrapper\wrapper.conf; DestDir: {app}; Flags: ignoreversion
Source: scripts\InstallTigaseService.bat; DestDir: {app}; Flags: ignoreversion
Source: ..\README.html; DestDir: {app}; Flags: ignoreversion
Source: scripts\Run.bat; DestDir: {app}; Flags: ignoreversion
Source: scripts\Tigase.bat; DestDir: {app}; Flags: ignoreversion
Source: scripts\UninstallTigaseService.bat; DestDir: {app}; Flags: ignoreversion
Source: Tigase.ico; DestDir: {app}; Flags: ignoreversion
Source: scripts\Uninst.bat; DestDir: {app}; Flags: ignoreversion
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
Source: Licence.txt; DestDir: {app}; Flags: ignoreversion
Source: wrapper\wrapper.dll; DestDir: {app}\libs; Flags: ignoreversion
Source: wrapper\wrapper.jar; DestDir: {app}\libs; Flags: ignoreversion

[Dirs]
Name: {app}\logs

[Icons]
Name: {group}\Start Tigase Server; Filename: {app}\Run.bat; WorkingDir: {app}; IconFilename: {app}\Tigase.ico
Name: {group}\Install Tigase Service; Filename: {app}\InstallTigaseService.bat
Name: {group}\Uninstall Tigase Service; Filename: {app}\UninstallTigaseService.bat
Name: {group}\{cm:ProgramOnTheWeb,Tigase}; Filename: http://www.tigase.org/

[UninstallRun]
Filename: {app}\Uninst.bat

#define ver "2.9.0-b507";

[Setup]
AppName=Tigase Server
AppVersion={#ver}
AppVerName=Tigase XMPP Server {#ver}
AppPublisher=tigase.org
AppPublisherURL=http://www.tigase.org/
AppSupportURL=http://www.tigase.org/
AppUpdatesURL=http://www.tigase.org/
DefaultDirName={pf}\Tigase
DefaultGroupName=Tigase Server
AllowNoIcons=true
LicenseFile=Licence.txt
OutputDir=..\packages
OutputBaseFilename=tigase-server-{#ver}
Compression=lzma
SolidCompression=true
UninstallDisplayIcon={app}\Tigase.ico
VersionInfoCopyright=Artur Hefczyc

[Languages]
Name: english; MessagesFile: compiler:Default.isl
Name: basque; MessagesFile: compiler:Languages\Basque.isl
Name: brazilianportuguese; MessagesFile: compiler:Languages\BrazilianPortuguese.isl
Name: catalan; MessagesFile: compiler:Languages\Catalan.isl
Name: czech; MessagesFile: compiler:Languages\Czech.isl
Name: danish; MessagesFile: compiler:Languages\Danish.isl
Name: dutch; MessagesFile: compiler:Languages\Dutch.isl
Name: finnish; MessagesFile: compiler:Languages\Finnish.isl
Name: french; MessagesFile: compiler:Languages\French.isl
Name: german; MessagesFile: compiler:Languages\German.isl
Name: hungarian; MessagesFile: compiler:Languages\Hungarian.isl
Name: italian; MessagesFile: compiler:Languages\Italian.isl
Name: norwegian; MessagesFile: compiler:Languages\Norwegian.isl
Name: polish; MessagesFile: compiler:Languages\Polish.isl
Name: portuguese; MessagesFile: compiler:Languages\Portuguese.isl
Name: russian; MessagesFile: compiler:Languages\Russian.isl
Name: slovak; MessagesFile: compiler:Languages\Slovak.isl
Name: slovenian; MessagesFile: compiler:Languages\Slovenian.isl
Name: spanish; MessagesFile: compiler:Languages\Spanish.isl

[Files]
Source: wrapper\wrapper.exe; DestDir: {app}; Flags: ignoreversion; Languages:
Source: ..\certs\*; DestDir: {app}\certs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\docs-tigase-server\*; DestDir: {app}\docs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\etc\*; DestDir: {app}\etc; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\jars\*; DestDir: {app}\jars; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\libs\*; DestDir: {app}\libs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\database\mysql-schema.sql; DestDir: {app}\database\mysql-schema.sql; Flags: ignoreversion
Source: ..\database\postgresql-schema.sql; DestDir: {app}\database\postgresql-schema.sql; Flags: ignoreversion
Source: wrapper\wrapper.conf; DestDir: {app}; Flags: ignoreversion
Source: scripts\InstallTigaseService.bat; DestDir: {app}; Flags: ignoreversion
Source: ..\README.html; DestDir: {app}; Flags: ignoreversion
Source: scripts\Run.bat; DestDir: {app}; Flags: ignoreversion
Source: scripts\Tigase.bat; DestDir: {app}; Flags: ignoreversion
Source: scripts\UninstallTigaseService.bat; DestDir: {app}; Flags: ignoreversion
Source: Tigase.ico; DestDir: {app}; Flags: ignoreversion
Source: scripts\Uninst.bat; DestDir: {app}; Flags: ignoreversion
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
Source: Licence.txt; DestDir: {app}; Flags: ignoreversion
Source: wrapper\wrapper.dll; DestDir: {app}\libs; Flags: ignoreversion
Source: wrapper\wrapper.jar; DestDir: {app}\libs; Flags: ignoreversion

[Dirs]
Name: {app}\logs

[Icons]
Name: {group}\Start Tigase Server; Filename: {app}\Run.bat; WorkingDir: {app}; IconFilename: {app}\Tigase.ico
Name: {group}\Install Tigase Service; Filename: {app}\InstallTigaseService.bat
Name: {group}\Uninstall Tigase Service; Filename: {app}\UninstallTigaseService.bat
Name: {group}\{cm:ProgramOnTheWeb,Tigase}; Filename: http://www.tigase.org/

[UninstallRun]
Filename: {app}\Uninst.bat


Version change to 2.9.3

Version change to 2.9.3

git-svn-id: 4a0daf30c0bbd291b3bc5fe8f058bf11ee523347@549 7d282ba1-3ae6-0310-8f9b-c9008a0864d2

#define ver "2.9.3-b548";

[Setup]
AppName=Tigase Server
AppVersion={#ver}
AppVerName=Tigase XMPP Server {#ver}
AppPublisher=tigase.org
AppPublisherURL=http://www.tigase.org/
AppSupportURL=http://www.tigase.org/
AppUpdatesURL=http://www.tigase.org/
DefaultDirName={pf}\Tigase
DefaultGroupName=Tigase Server
AllowNoIcons=true
LicenseFile=Licence.txt
OutputDir=..\packages
OutputBaseFilename=tigase-server-{#ver}
Compression=lzma
SolidCompression=true
UninstallDisplayIcon={app}\Tigase.ico
VersionInfoCopyright=Artur Hefczyc

[Languages]
Name: english; MessagesFile: compiler:Default.isl
Name: basque; MessagesFile: compiler:Languages\Basque.isl
Name: brazilianportuguese; MessagesFile: compiler:Languages\BrazilianPortuguese.isl
Name: catalan; MessagesFile: compiler:Languages\Catalan.isl
Name: czech; MessagesFile: compiler:Languages\Czech.isl
Name: danish; MessagesFile: compiler:Languages\Danish.isl
Name: dutch; MessagesFile: compiler:Languages\Dutch.isl
Name: finnish; MessagesFile: compiler:Languages\Finnish.isl
Name: french; MessagesFile: compiler:Languages\French.isl
Name: german; MessagesFile: compiler:Languages\German.isl
Name: hungarian; MessagesFile: compiler:Languages\Hungarian.isl
Name: italian; MessagesFile: compiler:Languages\Italian.isl
Name: norwegian; MessagesFile: compiler:Languages\Norwegian.isl
Name: polish; MessagesFile: compiler:Languages\Polish.isl
Name: portuguese; MessagesFile: compiler:Languages\Portuguese.isl
Name: russian; MessagesFile: compiler:Languages\Russian.isl
Name: slovak; MessagesFile: compiler:Languages\Slovak.isl
Name: slovenian; MessagesFile: compiler:Languages\Slovenian.isl
Name: spanish; MessagesFile: compiler:Languages\Spanish.isl

[Files]
Source: wrapper\wrapper.exe; DestDir: {app}; Flags: ignoreversion; Languages:
Source: ..\certs\*; DestDir: {app}\certs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\docs-tigase-server\*; DestDir: {app}\docs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\etc\*; DestDir: {app}\etc; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\jars\*; DestDir: {app}\jars; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\libs\*; DestDir: {app}\libs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\database\mysql-schema.sql; DestDir: {app}\database\mysql-schema.sql; Flags: ignoreversion
Source: ..\database\postgresql-schema.sql; DestDir: {app}\database\postgresql-schema.sql; Flags: ignoreversion
Source: wrapper\wrapper.conf; DestDir: {app}; Flags: ignoreversion
Source: scripts\InstallTigaseService.bat; DestDir: {app}; Flags: ignoreversion
Source: ..\README.html; DestDir: {app}; Flags: ignoreversion
Source: scripts\Run.bat; DestDir: {app}; Flags: ignoreversion
Source: scripts\Tigase.bat; DestDir: {app}; Flags: ignoreversion
Source: scripts\UninstallTigaseService.bat; DestDir: {app}; Flags: ignoreversion
Source: Tigase.ico; DestDir: {app}; Flags: ignoreversion
Source: scripts\Uninst.bat; DestDir: {app}; Flags: ignoreversion
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
Source: Licence.txt; DestDir: {app}; Flags: ignoreversion
Source: wrapper\wrapper.dll; DestDir: {app}\libs; Flags: ignoreversion
Source: wrapper\wrapper.jar; DestDir: {app}\libs; Flags: ignoreversion

[Dirs]
Name: {app}\logs

[Icons]
Name: {group}\Start Tigase Server; Filename: {app}\Run.bat; WorkingDir: {app}; IconFilename: {app}\Tigase.ico
Name: {group}\Install Tigase Service; Filename: {app}\InstallTigaseService.bat
Name: {group}\Uninstall Tigase Service; Filename: {app}\UninstallTigaseService.bat
Name: {group}\{cm:ProgramOnTheWeb,Tigase}; Filename: http://www.tigase.org/

[UninstallRun]
Filename: {app}\Uninst.bat

#define ver "2.9.2-b537";

[Setup]
AppName=Tigase Server
AppVersion={#ver}
AppVerName=Tigase XMPP Server {#ver}
AppPublisher=tigase.org
AppPublisherURL=http://www.tigase.org/
AppSupportURL=http://www.tigase.org/
AppUpdatesURL=http://www.tigase.org/
DefaultDirName={pf}\Tigase
DefaultGroupName=Tigase Server
AllowNoIcons=true
LicenseFile=Licence.txt
OutputDir=..\packages
OutputBaseFilename=tigase-server-{#ver}
Compression=lzma
SolidCompression=true
UninstallDisplayIcon={app}\Tigase.ico
VersionInfoCopyright=Artur Hefczyc

[Languages]
Name: english; MessagesFile: compiler:Default.isl
Name: basque; MessagesFile: compiler:Languages\Basque.isl
Name: brazilianportuguese; MessagesFile: compiler:Languages\BrazilianPortuguese.isl
Name: catalan; MessagesFile: compiler:Languages\Catalan.isl
Name: czech; MessagesFile: compiler:Languages\Czech.isl
Name: danish; MessagesFile: compiler:Languages\Danish.isl
Name: dutch; MessagesFile: compiler:Languages\Dutch.isl
Name: finnish; MessagesFile: compiler:Languages\Finnish.isl
Name: french; MessagesFile: compiler:Languages\French.isl
Name: german; MessagesFile: compiler:Languages\German.isl
Name: hungarian; MessagesFile: compiler:Languages\Hungarian.isl
Name: italian; MessagesFile: compiler:Languages\Italian.isl
Name: norwegian; MessagesFile: compiler:Languages\Norwegian.isl
Name: polish; MessagesFile: compiler:Languages\Polish.isl
Name: portuguese; MessagesFile: compiler:Languages\Portuguese.isl
Name: russian; MessagesFile: compiler:Languages\Russian.isl
Name: slovak; MessagesFile: compiler:Languages\Slovak.isl
Name: slovenian; MessagesFile: compiler:Languages\Slovenian.isl
Name: spanish; MessagesFile: compiler:Languages\Spanish.isl

[Files]
Source: wrapper\wrapper.exe; DestDir: {app}; Flags: ignoreversion; Languages:
Source: ..\certs\*; DestDir: {app}\certs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\docs-tigase-server\*; DestDir: {app}\docs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\etc\*; DestDir: {app}\etc; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\jars\*; DestDir: {app}\jars; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\libs\*; DestDir: {app}\libs; Flags: ignoreversion recursesubdirs createallsubdirs
Source: ..\database\mysql-schema.sql; DestDir: {app}\database\mysql-schema.sql; Flags: ignoreversion
Source: ..\database\postgresql-schema.sql; DestDir: {app}\database\postgresql-schema.sql; Flags: ignoreversion
Source: wrapper\wrapper.conf; DestDir: {app}; Flags: ignoreversion
Source: scripts\InstallTigaseService.bat; DestDir: {app}; Flags: ignoreversion
Source: ..\README.html; DestDir: {app}; Flags: ignoreversion
Source: scripts\Run.bat; DestDir: {app}; Flags: ignoreversion
Source: scripts\Tigase.bat; DestDir: {app}; Flags: ignoreversion
Source: scripts\UninstallTigaseService.bat; DestDir: {app}; Flags: ignoreversion
Source: Tigase.ico; DestDir: {app}; Flags: ignoreversion
Source: scripts\Uninst.bat; DestDir: {app}; Flags: ignoreversion
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
Source: Licence.txt; DestDir: {app}; Flags: ignoreversion
Source: wrapper\wrapper.dll; DestDir: {app}\libs; Flags: ignoreversion
Source: wrapper\wrapper.jar; DestDir: {app}\libs; Flags: ignoreversion

[Dirs]
Name: {app}\logs

[Icons]
Name: {group}\Start Tigase Server; Filename: {app}\Run.bat; WorkingDir: {app}; IconFilename: {app}\Tigase.ico
Name: {group}\Install Tigase Service; Filename: {app}\InstallTigaseService.bat
Name: {group}\Uninstall Tigase Service; Filename: {app}\UninstallTigaseService.bat
Name: {group}\{cm:ProgramOnTheWeb,Tigase}; Filename: http://www.tigase.org/

[UninstallRun]
Filename: {app}\Uninst.bat