added windows installer

moved config file location
This commit is contained in:
bancika
2017-04-19 13:26:00 +02:00
parent 32e273df6e
commit 781a8389d0
34 changed files with 1270 additions and 16 deletions
Binary file not shown.
Binary file not shown.
Binary file not shown.
+10 -2
View File
@@ -7,7 +7,7 @@
<property name="jar.dir" value="${build.dir}/jar" /> <property name="jar.dir" value="${build.dir}/jar" />
<property name="report.dir" value="${build.dir}/junitreport" /> <property name="report.dir" value="${build.dir}/junitreport" />
<property name="main.class" value="org.diylc.DIYLCStarter" /> <property name="main.class" value="org.diylc.DIYLCStarter" />
<property name="diylc.version" value="3.37.0" /> <property name="diylc.version" value="3.38.0" />
<property name="classes.dir" value="${build.dir}/temp/${ant.project.name}/classes" /> <property name="classes.dir" value="${build.dir}/temp/${ant.project.name}/classes" />
<property name="test.classes.dir" value="${build.dir}/temp/${ant.project.name}/test.classes" /> <property name="test.classes.dir" value="${build.dir}/temp/${ant.project.name}/test.classes" />
@@ -91,7 +91,15 @@
</jarbundler> </jarbundler>
</target> </target>
<target name="complete" depends="mac"> <target name="win" depends="jar">
<exec executable="innosetup\iscc.exe">
<arg value="/Ddiylcver=${diylc.version}"/>
<arg value="/Fdiylc-${diylc.version}"/>
<arg value="install.iss"/>
</exec>
</target>
<target name="complete" depends="mac, win">
<zip destfile="${build.dir}/diylc-${diylc.version}.zip"> <zip destfile="${build.dir}/diylc-${diylc.version}.zip">
<zipfileset dir="${jar.dir}" includes="diylc.jar" /> <zipfileset dir="${jar.dir}" includes="diylc.jar" />
<zipfileset dir="${jar.dir}/lib" prefix="lib" /> <zipfileset dir="${jar.dir}/lib" prefix="lib" />
Binary file not shown.
+336
View File
@@ -0,0 +1,336 @@
; *** Inno Setup version 5.5.3+ English messages ***
;
; To download user-contributed translations of this file, go to:
; http://www.jrsoftware.org/files/istrans/
;
; Note: When translating this text, do not add periods (.) to the end of
; messages that didn't have them already, because on those messages Inno
; Setup adds the periods automatically (appending a period would result in
; two periods being displayed).
[LangOptions]
; The following three entries are very important. Be sure to read and
; understand the '[LangOptions] section' topic in the help file.
LanguageName=English
LanguageID=$0409
LanguageCodePage=0
; If the language you are translating to requires special font faces or
; sizes, uncomment any of the following entries and change them accordingly.
;DialogFontName=
;DialogFontSize=8
;WelcomeFontName=Verdana
;WelcomeFontSize=12
;TitleFontName=Arial
;TitleFontSize=29
;CopyrightFontName=Arial
;CopyrightFontSize=8
[Messages]
; *** Application titles
SetupAppTitle=Setup
SetupWindowTitle=Setup - %1
UninstallAppTitle=Uninstall
UninstallAppFullTitle=%1 Uninstall
; *** Misc. common
InformationTitle=Information
ConfirmTitle=Confirm
ErrorTitle=Error
; *** SetupLdr messages
SetupLdrStartupMessage=This will install %1. Do you wish to continue?
LdrCannotCreateTemp=Unable to create a temporary file. Setup aborted
LdrCannotExecTemp=Unable to execute file in the temporary directory. Setup aborted
; *** Startup error messages
LastErrorMessage=%1.%n%nError %2: %3
SetupFileMissing=The file %1 is missing from the installation directory. Please correct the problem or obtain a new copy of the program.
SetupFileCorrupt=The setup files are corrupted. Please obtain a new copy of the program.
SetupFileCorruptOrWrongVer=The setup files are corrupted, or are incompatible with this version of Setup. Please correct the problem or obtain a new copy of the program.
InvalidParameter=An invalid parameter was passed on the command line:%n%n%1
SetupAlreadyRunning=Setup is already running.
WindowsVersionNotSupported=This program does not support the version of Windows your computer is running.
WindowsServicePackRequired=This program requires %1 Service Pack %2 or later.
NotOnThisPlatform=This program will not run on %1.
OnlyOnThisPlatform=This program must be run on %1.
OnlyOnTheseArchitectures=This program can only be installed on versions of Windows designed for the following processor architectures:%n%n%1
MissingWOW64APIs=The version of Windows you are running does not include functionality required by Setup to perform a 64-bit installation. To correct this problem, please install Service Pack %1.
WinVersionTooLowError=This program requires %1 version %2 or later.
WinVersionTooHighError=This program cannot be installed on %1 version %2 or later.
AdminPrivilegesRequired=You must be logged in as an administrator when installing this program.
PowerUserPrivilegesRequired=You must be logged in as an administrator or as a member of the Power Users group when installing this program.
SetupAppRunningError=Setup has detected that %1 is currently running.%n%nPlease close all instances of it now, then click OK to continue, or Cancel to exit.
UninstallAppRunningError=Uninstall has detected that %1 is currently running.%n%nPlease close all instances of it now, then click OK to continue, or Cancel to exit.
; *** Misc. errors
ErrorCreatingDir=Setup was unable to create the directory "%1"
ErrorTooManyFilesInDir=Unable to create a file in the directory "%1" because it contains too many files
; *** Setup common messages
ExitSetupTitle=Exit Setup
ExitSetupMessage=Setup is not complete. If you exit now, the program will not be installed.%n%nYou may run Setup again at another time to complete the installation.%n%nExit Setup?
AboutSetupMenuItem=&About Setup...
AboutSetupTitle=About Setup
AboutSetupMessage=%1 version %2%n%3%n%n%1 home page:%n%4
AboutSetupNote=
TranslatorNote=
; *** Buttons
ButtonBack=< &Back
ButtonNext=&Next >
ButtonInstall=&Install
ButtonOK=OK
ButtonCancel=Cancel
ButtonYes=&Yes
ButtonYesToAll=Yes to &All
ButtonNo=&No
ButtonNoToAll=N&o to All
ButtonFinish=&Finish
ButtonBrowse=&Browse...
ButtonWizardBrowse=B&rowse...
ButtonNewFolder=&Make New Folder
; *** "Select Language" dialog messages
SelectLanguageTitle=Select Setup Language
SelectLanguageLabel=Select the language to use during the installation:
; *** Common wizard text
ClickNext=Click Next to continue, or Cancel to exit Setup.
BeveledLabel=
BrowseDialogTitle=Browse For Folder
BrowseDialogLabel=Select a folder in the list below, then click OK.
NewFolderName=New Folder
; *** "Welcome" wizard page
WelcomeLabel1=Welcome to the [name] Setup Wizard
WelcomeLabel2=This will install [name/ver] on your computer.%n%nIt is recommended that you close all other applications before continuing.
; *** "Password" wizard page
WizardPassword=Password
PasswordLabel1=This installation is password protected.
PasswordLabel3=Please provide the password, then click Next to continue. Passwords are case-sensitive.
PasswordEditLabel=&Password:
IncorrectPassword=The password you entered is not correct. Please try again.
; *** "License Agreement" wizard page
WizardLicense=License Agreement
LicenseLabel=Please read the following important information before continuing.
LicenseLabel3=Please read the following License Agreement. You must accept the terms of this agreement before continuing with the installation.
LicenseAccepted=I &accept the agreement
LicenseNotAccepted=I &do not accept the agreement
; *** "Information" wizard pages
WizardInfoBefore=Information
InfoBeforeLabel=Please read the following important information before continuing.
InfoBeforeClickLabel=When you are ready to continue with Setup, click Next.
WizardInfoAfter=Information
InfoAfterLabel=Please read the following important information before continuing.
InfoAfterClickLabel=When you are ready to continue with Setup, click Next.
; *** "User Information" wizard page
WizardUserInfo=User Information
UserInfoDesc=Please enter your information.
UserInfoName=&User Name:
UserInfoOrg=&Organization:
UserInfoSerial=&Serial Number:
UserInfoNameRequired=You must enter a name.
; *** "Select Destination Location" wizard page
WizardSelectDir=Select Destination Location
SelectDirDesc=Where should [name] be installed?
SelectDirLabel3=Setup will install [name] into the following folder.
SelectDirBrowseLabel=To continue, click Next. If you would like to select a different folder, click Browse.
DiskSpaceMBLabel=At least [mb] MB of free disk space is required.
CannotInstallToNetworkDrive=Setup cannot install to a network drive.
CannotInstallToUNCPath=Setup cannot install to a UNC path.
InvalidPath=You must enter a full path with drive letter; for example:%n%nC:\APP%n%nor a UNC path in the form:%n%n\\server\share
InvalidDrive=The drive or UNC share you selected does not exist or is not accessible. Please select another.
DiskSpaceWarningTitle=Not Enough Disk Space
DiskSpaceWarning=Setup requires at least %1 KB of free space to install, but the selected drive only has %2 KB available.%n%nDo you want to continue anyway?
DirNameTooLong=The folder name or path is too long.
InvalidDirName=The folder name is not valid.
BadDirName32=Folder names cannot include any of the following characters:%n%n%1
DirExistsTitle=Folder Exists
DirExists=The folder:%n%n%1%n%nalready exists. Would you like to install to that folder anyway?
DirDoesntExistTitle=Folder Does Not Exist
DirDoesntExist=The folder:%n%n%1%n%ndoes not exist. Would you like the folder to be created?
; *** "Select Components" wizard page
WizardSelectComponents=Select Components
SelectComponentsDesc=Which components should be installed?
SelectComponentsLabel2=Select the components you want to install; clear the components you do not want to install. Click Next when you are ready to continue.
FullInstallation=Full installation
; if possible don't translate 'Compact' as 'Minimal' (I mean 'Minimal' in your language)
CompactInstallation=Compact installation
CustomInstallation=Custom installation
NoUninstallWarningTitle=Components Exist
NoUninstallWarning=Setup has detected that the following components are already installed on your computer:%n%n%1%n%nDeselecting these components will not uninstall them.%n%nWould you like to continue anyway?
ComponentSize1=%1 KB
ComponentSize2=%1 MB
ComponentsDiskSpaceMBLabel=Current selection requires at least [mb] MB of disk space.
; *** "Select Additional Tasks" wizard page
WizardSelectTasks=Select Additional Tasks
SelectTasksDesc=Which additional tasks should be performed?
SelectTasksLabel2=Select the additional tasks you would like Setup to perform while installing [name], then click Next.
; *** "Select Start Menu Folder" wizard page
WizardSelectProgramGroup=Select Start Menu Folder
SelectStartMenuFolderDesc=Where should Setup place the program's shortcuts?
SelectStartMenuFolderLabel3=Setup will create the program's shortcuts in the following Start Menu folder.
SelectStartMenuFolderBrowseLabel=To continue, click Next. If you would like to select a different folder, click Browse.
MustEnterGroupName=You must enter a folder name.
GroupNameTooLong=The folder name or path is too long.
InvalidGroupName=The folder name is not valid.
BadGroupName=The folder name cannot include any of the following characters:%n%n%1
NoProgramGroupCheck2=&Don't create a Start Menu folder
; *** "Ready to Install" wizard page
WizardReady=Ready to Install
ReadyLabel1=Setup is now ready to begin installing [name] on your computer.
ReadyLabel2a=Click Install to continue with the installation, or click Back if you want to review or change any settings.
ReadyLabel2b=Click Install to continue with the installation.
ReadyMemoUserInfo=User information:
ReadyMemoDir=Destination location:
ReadyMemoType=Setup type:
ReadyMemoComponents=Selected components:
ReadyMemoGroup=Start Menu folder:
ReadyMemoTasks=Additional tasks:
; *** "Preparing to Install" wizard page
WizardPreparing=Preparing to Install
PreparingDesc=Setup is preparing to install [name] on your computer.
PreviousInstallNotCompleted=The installation/removal of a previous program was not completed. You will need to restart your computer to complete that installation.%n%nAfter restarting your computer, run Setup again to complete the installation of [name].
CannotContinue=Setup cannot continue. Please click Cancel to exit.
ApplicationsFound=The following applications are using files that need to be updated by Setup. It is recommended that you allow Setup to automatically close these applications.
ApplicationsFound2=The following applications are using files that need to be updated by Setup. It is recommended that you allow Setup to automatically close these applications. After the installation has completed, Setup will attempt to restart the applications.
CloseApplications=&Automatically close the applications
DontCloseApplications=&Do not close the applications
ErrorCloseApplications=Setup was unable to automatically close all applications. It is recommended that you close all applications using files that need to be updated by Setup before continuing.
; *** "Installing" wizard page
WizardInstalling=Installing
InstallingLabel=Please wait while Setup installs [name] on your computer.
; *** "Setup Completed" wizard page
FinishedHeadingLabel=Completing the [name] Setup Wizard
FinishedLabelNoIcons=Setup has finished installing [name] on your computer.
FinishedLabel=Setup has finished installing [name] on your computer. The application may be launched by selecting the installed shortcuts.
ClickFinish=Click Finish to exit Setup.
FinishedRestartLabel=To complete the installation of [name], Setup must restart your computer. Would you like to restart now?
FinishedRestartMessage=To complete the installation of [name], Setup must restart your computer.%n%nWould you like to restart now?
ShowReadmeCheck=Yes, I would like to view the README file
YesRadio=&Yes, restart the computer now
NoRadio=&No, I will restart the computer later
; used for example as 'Run MyProg.exe'
RunEntryExec=Run %1
; used for example as 'View Readme.txt'
RunEntryShellExec=View %1
; *** "Setup Needs the Next Disk" stuff
ChangeDiskTitle=Setup Needs the Next Disk
SelectDiskLabel2=Please insert Disk %1 and click OK.%n%nIf the files on this disk can be found in a folder other than the one displayed below, enter the correct path or click Browse.
PathLabel=&Path:
FileNotInDir2=The file "%1" could not be located in "%2". Please insert the correct disk or select another folder.
SelectDirectoryLabel=Please specify the location of the next disk.
; *** Installation phase messages
SetupAborted=Setup was not completed.%n%nPlease correct the problem and run Setup again.
EntryAbortRetryIgnore=Click Retry to try again, Ignore to proceed anyway, or Abort to cancel installation.
; *** Installation status messages
StatusClosingApplications=Closing applications...
StatusCreateDirs=Creating directories...
StatusExtractFiles=Extracting files...
StatusCreateIcons=Creating shortcuts...
StatusCreateIniEntries=Creating INI entries...
StatusCreateRegistryEntries=Creating registry entries...
StatusRegisterFiles=Registering files...
StatusSavingUninstall=Saving uninstall information...
StatusRunProgram=Finishing installation...
StatusRestartingApplications=Restarting applications...
StatusRollback=Rolling back changes...
; *** Misc. errors
ErrorInternal2=Internal error: %1
ErrorFunctionFailedNoCode=%1 failed
ErrorFunctionFailed=%1 failed; code %2
ErrorFunctionFailedWithMessage=%1 failed; code %2.%n%3
ErrorExecutingProgram=Unable to execute file:%n%1
; *** Registry errors
ErrorRegOpenKey=Error opening registry key:%n%1\%2
ErrorRegCreateKey=Error creating registry key:%n%1\%2
ErrorRegWriteKey=Error writing to registry key:%n%1\%2
; *** INI errors
ErrorIniEntry=Error creating INI entry in file "%1".
; *** File copying errors
FileAbortRetryIgnore=Click Retry to try again, Ignore to skip this file (not recommended), or Abort to cancel installation.
FileAbortRetryIgnore2=Click Retry to try again, Ignore to proceed anyway (not recommended), or Abort to cancel installation.
SourceIsCorrupted=The source file is corrupted
SourceDoesntExist=The source file "%1" does not exist
ExistingFileReadOnly=The existing file is marked as read-only.%n%nClick Retry to remove the read-only attribute and try again, Ignore to skip this file, or Abort to cancel installation.
ErrorReadingExistingDest=An error occurred while trying to read the existing file:
FileExists=The file already exists.%n%nWould you like Setup to overwrite it?
ExistingFileNewer=The existing file is newer than the one Setup is trying to install. It is recommended that you keep the existing file.%n%nDo you want to keep the existing file?
ErrorChangingAttr=An error occurred while trying to change the attributes of the existing file:
ErrorCreatingTemp=An error occurred while trying to create a file in the destination directory:
ErrorReadingSource=An error occurred while trying to read the source file:
ErrorCopying=An error occurred while trying to copy a file:
ErrorReplacingExistingFile=An error occurred while trying to replace the existing file:
ErrorRestartReplace=RestartReplace failed:
ErrorRenamingTemp=An error occurred while trying to rename a file in the destination directory:
ErrorRegisterServer=Unable to register the DLL/OCX: %1
ErrorRegSvr32Failed=RegSvr32 failed with exit code %1
ErrorRegisterTypeLib=Unable to register the type library: %1
; *** Post-installation errors
ErrorOpeningReadme=An error occurred while trying to open the README file.
ErrorRestartingComputer=Setup was unable to restart the computer. Please do this manually.
; *** Uninstaller messages
UninstallNotFound=File "%1" does not exist. Cannot uninstall.
UninstallOpenError=File "%1" could not be opened. Cannot uninstall
UninstallUnsupportedVer=The uninstall log file "%1" is in a format not recognized by this version of the uninstaller. Cannot uninstall
UninstallUnknownEntry=An unknown entry (%1) was encountered in the uninstall log
ConfirmUninstall=Are you sure you want to completely remove %1 and all of its components?
UninstallOnlyOnWin64=This installation can only be uninstalled on 64-bit Windows.
OnlyAdminCanUninstall=This installation can only be uninstalled by a user with administrative privileges.
UninstallStatusLabel=Please wait while %1 is removed from your computer.
UninstalledAll=%1 was successfully removed from your computer.
UninstalledMost=%1 uninstall complete.%n%nSome elements could not be removed. These can be removed manually.
UninstalledAndNeedsRestart=To complete the uninstallation of %1, your computer must be restarted.%n%nWould you like to restart now?
UninstallDataCorrupted="%1" file is corrupted. Cannot uninstall
; *** Uninstallation phase messages
ConfirmDeleteSharedFileTitle=Remove Shared File?
ConfirmDeleteSharedFile2=The system indicates that the following shared file is no longer in use by any programs. Would you like for Uninstall to remove this shared file?%n%nIf any programs are still using this file and it is removed, those programs may not function properly. If you are unsure, choose No. Leaving the file on your system will not cause any harm.
SharedFileNameLabel=File name:
SharedFileLocationLabel=Location:
WizardUninstalling=Uninstall Status
StatusUninstalling=Uninstalling %1...
; *** Shutdown block reasons
ShutdownBlockReasonInstallingApp=Installing %1.
ShutdownBlockReasonUninstallingApp=Uninstalling %1.
; The custom messages below aren't used by Setup itself, but if you make
; use of them in your scripts, you'll want to translate them.
[CustomMessages]
NameAndVersion=%1 version %2
AdditionalIcons=Additional shortcuts:
CreateDesktopIcon=Create a &desktop shortcut
CreateQuickLaunchIcon=Create a &Quick Launch shortcut
ProgramOnTheWeb=%1 on the Web
UninstallProgram=Uninstall %1
LaunchProgram=Launch %1
AssocFileExtension=&Associate %1 with the %2 file extension
AssocingFileExtension=Associating %1 with the %2 file extension...
AutoStartProgramGroupDescription=Startup:
AutoStartProgram=Automatically start %1
AddonHostProgramNotFound=%1 could not be located in the folder you selected.%n%nDo you want to continue anyway?
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,366 @@
; BEGIN ISPPBUILTINS.ISS
//
// Inno Setup Preprocessor 5
//
// Copyright (C) 2001-2004 Alex Yackimoff. All Rights Reserved.
// Portions by Martijn Laan.
// http://ispp.sourceforge.net
//
// Inno Setup (C) 1997-2009 Jordan Russell. All Rights Reserved.
// Portions by Martijn Laan.
//
// $Id: ISPPBuiltins.iss,v 1.3 2010/12/29 15:20:26 mlaan Exp $
//
#if defined(ISPP_INVOKED) && !defined(_BUILTINS_ISS_)
//
#if PREPROCVER < 0x01000000
# error Inno Setup Preprocessor version is outdated
#endif
//
#define _BUILTINS_ISS_
//
// ===========================================================================
//
// Default states for options.
//
//#pragma parseroption -b+ ; short circuit boolean evaluation: on
//#pragma parseroption -m- ; short circuit multiplication evaluation (0 * A will not eval A): off
//#pragma parseroption -p+ ; string literals without escape sequences: on
//#pragma parseroption -u- ; allow undeclared identifiers: off
//#pragma option -c+ ; pass script to the compiler: on
//#pragma option -e- ; emit empty lines to translation: off
//#pragma option -v- ; verbose mode: off
//
// ---------------------------------------------------------------------------
//
// Verbose levels:
// 0 - #include and #file acknowledgements
// 1 - information about any temp files created by #file
// 2 - #insert and #append acknowledgements
// 3 - reserved
// 4 - #dim, #define and #undef acknowledgements
// 5 - reserved
// 6 - conditional inclusion acknowledgements
// 7 - reserved
// 8 - show strings emitted with #emit directive
// 9 - macro and functions successfull call acknowledgements
//10 - Local macro array allocation acknowledgements
//
//#pragma verboselevel 0
//
#ifndef __POPT_P__
# define private CStrings
# pragma parseroption -p+
#endif
//
#pragma spansymbol "\"
//
#define True 1
#define False 0
#define Yes True
#define No False
//
#define MaxInt 0x7FFFFFFFL
#define MinInt 0x80000000L
//
#define NULL
#define void
//
// TypeOf constants
//
#define TYPE_ERROR 0
#define TYPE_NULL 1
#define TYPE_INTEGER 2
#define TYPE_STRING 3
#define TYPE_MACRO 4
#define TYPE_FUNC 5
#define TYPE_ARRAY 6
//
// Helper macro to find out the type of an array element or expression. TypeOf
// standard function only allows identifier as its parameter. Use this macro
// to convert an expression to identifier.
//
#define TypeOf2(any Expr) TypeOf(Expr)
//
// ReadReg constants
//
#define HKEY_CLASSES_ROOT 0x80000000UL
#define HKEY_CURRENT_USER 0x80000001UL
#define HKEY_LOCAL_MACHINE 0x80000002UL
#define HKEY_USERS 0x80000003UL
#define HKEY_CURRENT_CONFIG 0x80000005UL
#define HKEY_CLASSES_ROOT_64 0x82000000UL
#define HKEY_CURRENT_USER_64 0x82000001UL
#define HKEY_LOCAL_MACHINE_64 0x82000002UL
#define HKEY_USERS_64 0x82000003UL
#define HKEY_CURRENT_CONFIG_64 0x82000005UL
//
#define HKCR HKEY_CLASSES_ROOT
#define HKCU HKEY_CURRENT_USER
#define HKLM HKEY_LOCAL_MACHINE
#define HKU HKEY_USERS
#define HKCC HKEY_CURRENT_CONFIG
#define HKCR64 HKEY_CLASSES_ROOT_64
#define HKCU64 HKEY_CURRENT_USER_64
#define HKLM64 HKEY_LOCAL_MACHINE_64
#define HKU64 HKEY_USERS_64
#define HKCC64 HKEY_CURRENT_CONFIG_64
//
// Exec constants
//
#define SW_HIDE 0
#define SW_SHOWNORMAL 1
#define SW_NORMAL 1
#define SW_SHOWMINIMIZED 2
#define SW_SHOWMAXIMIZED 3
#define SW_MAXIMIZE 3
#define SW_SHOWNOACTIVATE 4
#define SW_SHOW 5
#define SW_MINIMIZE 6
#define SW_SHOWMINNOACTIVE 7
#define SW_SHOWNA 8
#define SW_RESTORE 9
#define SW_SHOWDEFAULT 10
#define SW_MAX 10
//
// Find constants
//
#define FIND_MATCH 0x00
#define FIND_BEGINS 0x01
#define FIND_ENDS 0x02
#define FIND_CONTAINS 0x03
#define FIND_CASESENSITIVE 0x04
#define FIND_SENSITIVE FIND_CASESENSITIVE
#define FIND_AND 0x00
#define FIND_OR 0x08
#define FIND_NOT 0x10
#define FIND_TRIM 0x20
//
// FindFirst constants
//
#define faReadOnly 0x00000001
#define faHidden 0x00000002
#define faSysFile 0x00000004
#define faVolumeID 0x00000008
#define faDirectory 0x00000010
#define faArchive 0x00000020
#define faSymLink 0x00000040
#define faAnyFile 0x0000003F
//
// GetStringFileInfo standard names
//
#define COMPANY_NAME "CompanyName"
#define FILE_DESCRIPTION "FileDescription"
#define FILE_VERSION "FileVersion"
#define INTERNAL_NAME "InternalName"
#define LEGAL_COPYRIGHT "LegalCopyright"
#define ORIGINAL_FILENAME "OriginalFilename"
#define PRODUCT_NAME "ProductName"
#define PRODUCT_VERSION "ProductVersion"
//
// GetStringFileInfo helpers
//
#define GetFileCompany(str FileName) GetStringFileInfo(FileName, COMPANY_NAME)
#define GetFileCopyright(str FileName) GetStringFileInfo(FileName, LEGAL_COPYRIGHT)
#define GetFileDescription(str FileName) GetStringFileInfo(FileName, FILE_DESCRIPTION)
#define GetFileProductVersion(str FileName) GetStringFileInfo(FileName, PRODUCT_VERSION)
#define GetFileVersionString(str FileName) GetStringFileInfo(FileName, FILE_VERSION)
//
// ParseVersion
//
// Macro internally calls GetFileVersion function and parses string returned
// by that function (in form "0.0.0.0"). All four version elements are stored
// in by-reference parameters Major, Minor, Rev, and Build. Macro returns
// string returned by GetFileVersion.
//
#define DeleteToFirstPeriod(str *S) \
Local[1] = Copy(S, 1, (Local[0] = Pos(".", S)) - 1), \
S = Copy(S, Local[0] + 1), \
Local[1]
//
#define ParseVersion(str FileName, *Major, *Minor, *Rev, *Build) \
Local[1] = Local[0] = GetFileVersion(FileName), \
Local[1] == "" ? "" : ( \
Major = Int(DeleteToFirstPeriod(Local[1])), \
Minor = Int(DeleteToFirstPeriod(Local[1])), \
Rev = Int(DeleteToFirstPeriod(Local[1])), \
Build = Int(Local[1]), \
Local[0])
//
// EncodeVer
//
// Encodes given four version elements to a 32 bit integer number (8 bits for
// each element, i.e. elements must be within 0...255 range).
//
#define EncodeVer(int Major, int Minor, int Revision = 0, int Build = -1) \
Major << 24 | (Minor & 0xFF) << 16 | (Revision & 0xFF) << 8 | (Build >= 0 ? Build & 0xFF : 0)
//
// DecodeVer
//
// Decodes given 32 bit integer encoded version to its string representation,
// Digits parameter indicates how many elements to show (if the fourth element
// is 0, it won't be shown anyway).
//
#define DecodeVer(int Ver, int Digits = 3) \
Str(Ver >> 0x18 & 0xFF) + (Digits > 1 ? "." : "") + \
(Digits > 1 ? \
Str(Ver >> 0x10 & 0xFF) + (Digits > 2 ? "." : "") : "") + \
(Digits > 2 ? \
Str(Ver >> 0x08 & 0xFF) + (Digits > 3 && (Local = Ver & 0xFF) ? "." : "") : "") + \
(Digits > 3 && Local ? \
Str(Ver & 0xFF) : "")
//
// FindSection
//
// Returns index of the line following the header of the section. This macro
// is intended to be used with #insert directive.
//
#define FindSection(str Section = "Files") \
Find(0, "[" + Section + "]", FIND_MATCH | FIND_TRIM) + 1
//
// FindSectionEnd
//
// Returns index of the line following last entry of the section. This macro
// is intended to be used with #insert directive.
//
#if VER >= 0x03000000
# define FindNextSection(int Line) \
Find(Line, "[", FIND_BEGINS | FIND_TRIM, "]", FIND_ENDS | FIND_AND)
# define FindSectionEnd(str Section = "Files") \
FindNextSection(FindSection(Section))
#else
# define FindSectionEnd(str Section = "Files") \
FindSection(Section) + EntryCount(Section)
#endif
//
// FindCode
//
// Returns index of the line (of translation) following either [Code] section
// header, or "program" keyword, if any.
//
#define FindCode() \
Local[1] = FindSection("Code"), \
Local[0] = Find(Local[1] - 1, "program", FIND_BEGINS, ";", FIND_ENDS | FIND_AND), \
(Local[0] < 0 ? Local[1] : Local[0] + 1)
//
// ExtractFilePath
//
// Returns directory portion of the given filename without backslash (unless
// it is a root directory). If PathName doesn't contain directory portion,
// the result is an empty string.
//
#define ExtractFilePath(str PathName) \
(Local[0] = \
!(Local[1] = RPos("\", PathName)) ? \
"" : \
Copy(PathName, 1, Local[1] - 1)), \
Local[0] + \
((Local[2] = Len(Local[0])) == 2 && Copy(Local[0], Local[2]) == ":" ? \
"\" : \
"")
#define ExtractFileDir(str PathName) \
RemoveBackslash(ExtractFilePath(PathName))
#define ExtractFileExt(str PathName) \
Local[0] = RPos(".", PathName), \
Copy(PathName, Local[0] + 1)
//
// ExtractFileName
//
// Returns name portion of the given filename. If PathName ends with
// a backslash, the result is an empty string.
//
#define ExtractFileName(str PathName) \
!(Local[0] = RPos("\", PathName)) ? \
PathName : \
Copy(PathName, Local[0] + 1)
//
// ChangeFileExt
//
// Changes extension in FileName with NewExt. NewExt must not contain
// period.
//
#define ChangeFileExt(str FileName, str NewExt) \
!(Local[0] = RPos(".", FileName)) ? \
FileName + "." + NewExt : \
Copy(FileName, 1, Local[0]) + NewExt
//
// RemoveFileExt
//
// Removes extension in FileName.
//
#define RemoveFileExt(str FileName) \
!(Local[0] = RPos(".", FileName)) ? \
FileName : \
Copy(FileName, 1, Local[0] - 1)
//
// AddBackslash
//
// Adds a backslash to the string, if it's not already there.
//
#define AddBackslash(str S) \
Copy(S, Len(S)) == "\" ? S : S + "\"
//
// RemoveBackslash
//
// Removes trailing backslash from the string unless the string points to
// a root directory.
//
#define RemoveBackslash(str S) \
Local[0] = Len(S), \
Local[0] > 0 ? \
Copy(S, Local[0]) == "\" ? \
(Local[0] == 3 && Copy(S, 2, 1) == ":" ? \
S : \
Copy(S, 1, Local[0] - 1)) : \
S : \
""
//
// Delete
//
// Deletes specified number of characters beginning with Index from S. S is
// passed by reference (therefore is modified). Acts like Delete function in
// Delphi (from System unit).
//
#define Delete(str *S, int Index, int Count = MaxInt) \
S = Copy(S, 1, Index - 1) + Copy(S, Index + Count)
//
// Insert
//
// Inserts specified Substr at Index'th character into S. S is passed by
// reference (therefore is modified).
//
#define Insert(str *S, int Index, str Substr) \
Index > Len(S) + 1 ? \
S : \
S = Copy(S, 1, Index - 1) + SubStr + Copy(S, Index)
//
// YesNo, IsDirSet
//
// Returns nonzero value if given string is "yes", "true" or "1". Intended to
// be used with SetupSetting function. This macro replaces YesNo function
// available in previous releases.
//
#define YesNo(str S) \
(S = LowerCase(S)) == "yes" || S == "true" || S == "1"
//
#define IsDirSet(str SetupDirective) \
YesNo(SetupSetting(SetupDirective))
//
//
#define Power(int X, int P = 2) \
!P ? 1 : X * Power(X, P - 1)
//
#define Min(int A, int B, int C = MaxInt) \
A < B ? A < C ? Int(A) : Int(C) : Int(B)
//
#define Max(int A, int B, int C = MinInt) \
A > B ? A > C ? Int(A) : Int(C) : Int(B)
//
#ifdef CStrings
# pragma parseroption -p-
#endif
#endif
; END ISPPBUILTINS.ISS
Binary file not shown.
Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.
Binary file not shown.
+474
View File
@@ -0,0 +1,474 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Inno Setup FAQ</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<style type="text/css"><!--
BODY {
background: #ffffff;
color: #000000;
font: small verdana, arial, sans-serif;
}
H1, .xxbig {
font: bold xx-large verdana, arial, sans-serif;
}
H2, .xbig {
font: bold x-large verdana, arial, sans-serif;
}
H3, .big {
font: bold large verdana, arial, sans-serif;
}
H4, .medium {
font: bold medium verdana, arial, sans-serif;
}
PRE, TT {
font: small "courier new", monospace;
}
LI {
margin-top: 0.25em;
margin-bottom: 0.25em;
}
P, UL {
/* for paragraph spacing consistency between IE (6) and Mozilla (1.4) */
margin-top: 1em;
margin-bottom: 1em;
}
A:link {
color: #274d99;
}
A:visited, A:active {
color: #5a83d7;
}
--></style>
</head>
<body>
<table width="100%" border="0" cellpadding="5" cellspacing="0">
<tr>
<td align="center" bgcolor="#264b99"><span class="xxbig"><font color="#FFFFFF">Inno Setup</font></span><br />
<span class="big"><font color="#FFFFFF">Frequently Asked Questions</font></span></td>
</tr>
</table>
<p>The <b>Inno Setup Frequently Asked Questions</b> contains supplemental information not found in the <a href="ishelp/" target="blank">documentation</a> or the <a href="iskb.php">Knowledge Base</a>.</p>
<h3>Functionality</h3>
<ul>
<li><a href="#lang">Translating Inno Setup's Text</a></li>
<li><a href="#mbcs">Does it support MBCS (multi-byte character sets)?</a></li>
<li><a href="#msi">Will it support Windows Installer in the future?</a></li>
<li><a href="#setupicon">How do I change the icon of Setup.exe?</a></li>
<li><a href="#conditional">Can Inno Setup do a conditional installation - for example, proceed only if a certain registry key or file exists?</a></li>
<li><a href="#silent">Is it possible to do a silent install without using the /SILENT or /VERYSILENT command-line parameters?</a></li>
<li><a href="#dirnamereg">Can Setup use the value of a registry entry as the default directory name?</a></li>
</ul>
<h3>Problems</h3>
<ul>
<li><a href="#errorquotes">Compiler says "Mismatched or misplaced quotes on parameter"</a></li>
<li><a href="#workingdir">My application can't find any of its files when it is started from the shortcut created by Setup. It works fine when I double-click the application's EXE in Explorer.</a></li>
<li><a href="#appid">When I install a new version of my application without uninstalling the old version first, I get a second entry in Control Panel's <i>Add/Remove Programs</i>.</a></li>
<li><a href="#corrupt">Why is the error message "The setup files are corrupted" displayed on some systems?</a></li>
<li><a href="#noregserver">Setup gives the message "Unable to register the DLL/OCX: DllRegisterServer export not found"</a></li>
<li><a href="#emptydirs">After uninstalling, the directories created during installation still exist.</a></li>
<li><a href="#batchfile">I run a batch file in the [Run] section, but the window remains on the screen after it finishes executing. I'd like it to "close on exit."</a></li>
<li><a href="#olddir">I've changed DefaultDirName in my script, yet when I run Setup it defaults to the directory I had before.</a></li>
<li><a href="#twoicons">I have two [Icons] entries with the same Name, but only one of them gets installed.</a></li>
<li><a href="#runwait">Setup isn't waiting for programs executed by [Run] entries to finish.</a></li>
<li><a href="#missinglanguages">Some languages are missing on the <i>Select Setup Language</i> dialog, or it doesn't show up at all.</a></li>
</ul>
<h3>Installation Tasks</h3>
<ul>
<li><a href="#urls">Creating Internet (URL) Shortcuts</a></li>
<li><a href="#startin">Setting the "Start In" Field on a Shortcut</a></li>
<li><a href="#assoc">Creating File Associations</a></li>
<li><a href="#env">Setting Environment Variables</a></li>
<li><a href="#closeonexit">Setting the "Close on Exit" Box on a Shortcut to an MS-DOS Program</a></li>
<li><a href="#backup">Making Backups Before Replacing Files</a></li>
<li><a href="#difffiles">Installing Different Files Depending on Windows Version</a></li>
<li><a href="#perms">Settings Permissions on Files, Directories, or Registry Keys</a></li>
<li><a href="#custom">My installation needs to do something that Inno Setup apparently doesn't have a feature for.</a></li>
</ul>
<h3>How Do I Install...?</h3>
<ul>
<li><a href="#ocx">OCX Files</a></li>
<li><a href="#vb">Visual Basic System Files</a></li>
<li><a href="#vc">Visual C++ System Files (e.g. MFC)</a></li>
<li><a href="#comctl32">COMCTL32.DLL</a></li>
<li><a href="#bde">BDE (Borland Database Engine)</a></li>
<li><a href="#mdac">MDAC, ADO, Jet, etc.</a></li>
</ul>
<h3>Compatibility</h3>
<ul>
<li><a href="#oscompat">OS Compatibility</a></li>
<li><a href="#ntsecur">Administrative Privileges</a></li>
</ul>
<h3>Miscellaneous</h3>
<ul>
<li><a href="#limits">Are there any limits on how many files, etc. may be included in an installation?</a></li>
<li><a href="#cancel">What exactly happens when the user clicks Cancel during an installation?</a></li>
</ul>
<hr /><h2>Functionality</h2>
<h4><a name="lang">Translating Inno Setup's Text</a></h4>
<blockquote>
<p>Translating Inno Setup's text into another language does not require modifying the source code. Simply make a copy of the Default.isl file (included with Inno Setup) and start editing the text in it. (Do not directly edit the Default.isl file, otherwise your changes will be lost when you install a new Inno Setup version.) See the "[Messages] Section" topic in the Inno Setup help file for some important tips.</p>
<p>Once you have finished creating the new .isl file, create a [Languages] section to tell the compiler to use it:</p>
<p><tt>
<b>[Languages]</b><br />
<font color="blue">Name</font>: mytrans; <font color="blue">MessagesFile</font>: "compiler:MyTranslation.isl"
</tt></p>
<p>If you're using a version of Inno Setup prior to 4.0, use this instead:</p>
<p><tt>
<b>[Setup]</b><br />
<font color="blue">MessagesFile</font>=compiler:MyTranslation.isl
</tt></p>
<p>There are many contributed translations available for download on the <a href="http://www.jrsoftware.org/is3rdparty.php">Inno Setup Third-Party Files</a> page, as well as a program to assist in editing the .isl file.</p>
</blockquote>
<h4><a name="mbcs">Does it support MBCS (multi-byte character sets)?</a></h4>
<blockquote>
<p>Inno Setup 2.0.6 adds complete support for MBCS. It does lead byte checking on all filename and constant parsing, so it should no longer mistake trail bytes for backslashes ("\") or braces ("{").</p>
<p>Versions prior to 2.0.6 did not include any special support for MBCS.</p>
</blockquote>
<h4><a name="msi">Will it support Windows Installer in the future?</a></h4>
<blockquote>
<p>At the present time, there are no plans for a Windows Installer edition of Inno Setup. "Supporting" Windows Installer would likely involve a near-complete rewrite of the program.</p>
</blockquote>
<h4><a name="setupicon">How do I change the icon of Setup.exe?</a></h4>
<blockquote>
<p>The installer's icon may be changed by setting the <tt>SetupIconFile</tt> [Setup] section directive. To set the uninstaller's icon, set <tt>UninstallIconFile</tt>.</p>
</blockquote>
<h4><a name="conditional">Can Inno Setup do a conditional installation - for example, proceed only if a certain registry key or file exists?</a></h4>
<blockquote>
<p>Inno Setup 4 adds support for this through the new Pascal Scripting feature.</p>
<p>Note: with earlier Inno Setup versions it was already possible to <a href="#difffiles">install different files depending on the Windows version</a>.</p>
</blockquote>
<h4><a name="silent">Is it possible to do a silent install without using the /SILENT or /VERYSILENT command-line parameters?</a></h4>
<blockquote>
<p>No, nor is such a feature planned (it would be abused). If it is your intention to keep user interaction to a minimum, use the Disable* [Setup] section directives.</p>
</blockquote>
<h4><a name="dirnamereg">Can Setup use the value of a registry entry as the default directory name?</a></h4>
<blockquote>
<p>Yes. Use a {reg:...} constant in DefaultDirName. For example:</p>
<p><tt><b>[Setup]</b><br />
<font color="blue">DefaultDirName</font>={reg:HKLM\Software\My Program,Path|{pf}\My Program}<br />
</tt></p>
<p>See the "Constants" topic in the Inno Setup help file for more information on {reg:...} constants.</p>
</blockquote>
<hr /><h2>Problems</h2>
<h4><a name="errorquotes">Compiler says "Mismatched or misplaced quotes on parameter"</a></h4>
<blockquote>
<p>This message is typically displayed if you try to embed a quote (") character in a parameter's data, but do not double it as required. Read the "Parameters in Sections" topic in the Inno Setup help file for more information.</p>
</blockquote>
<h4><a name="workingdir">My application can't find any of its files when it is started from the shortcut created by Setup. It works fine when I double-click the application's EXE in Explorer.</a></h4>
<blockquote>
<p>Your application is most likely not specifying pathnames on the files it is trying to open, so it is expecting to find them in the current directory. Inno Setup by default does not set the "Start In" field on shortcuts its creates; this causes Windows to pick a directory itself, which usually won't be the directory containing your application.</p>
<p>In virtually all cases, this is something that should be corrected at the application level. Properly designed GUI applications should not expect to be started from a particular directory; they should always specify full pathnames on files they open. In Delphi or C++Builder, for example, it's possible to get the full pathname of the directory containing the application EXE by calling: <tt>ExtractFilePath(ParamStr(0))</tt>. To get the full path of a file named "File.txt" in the application directory, use: <tt>ExtractFilePath(ParamStr(0)) + 'File.txt'</tt>.</p>
<p>If for some reason you cannot fix this at the application level, you can tell Inno Setup to set the "Start In" field by adding "WorkingDir: {app}" to your [Icons] entries.</p>
</blockquote>
<h4><a name="corrupt">Why is the error message "The setup files are corrupted" displayed on some systems?</a></h4>
<blockquote>
<p>This error message is displayed when a file pertaining to the installation (e.g., setup.exe, setup.1) has the wrong size, or part of a file fails a CRC check. It is not displayed for any other reason.</p>
<p>If your installation is distributed over the internet and you're getting a lot of reports of this error, it could be that your web server is delivering partial files by dropping connections prematurely. Have the affected users check the size in the bytes of the file(s) they downloaded.</p>
<p>If your installation is distributed via CD-ROM or floppy disk, it could be that the CD-ROM or floppy disk is bad, or possibly the drive is defective.</p>
</blockquote>
<h4><a name="appid">When I install a new version of my application without uninstalling the old version first, I get a second entry in Control Panel's <i>Add/Remove Programs</i>.</a></h4>
<blockquote>
<p>This happens when you change AppId between versions, or if AppId is not specified, AppName. If you do that, Setup has no way of knowing that the two versions are of the same application, and thus will create a new entry in <i>Add/Remove Programs</i>. Additionally, a new uninstall log file (unins???.dat) will be created. The obvious solution for this is to not change AppId or AppName.</p>
<p>If you must change AppName in a new version, set AppId to the value of AppId or AppName from the previous version.</p>
</blockquote>
<h4><a name="noregserver">Setup gives the message "Unable to register the DLL/OCX: DllRegisterServer export not found"</a></h4>
<blockquote>
<p>This message normally means that you specified the "regserver" flag on a file that doesn't possess the ability to be registered. Remove the "regserver" flag from the [Files] entry and the message will go away.</p>
</blockquote>
<h4><a name="emptydirs">After uninstalling, the directories created during installation still exist.</a></h4>
<blockquote>
<p>There are several reasons why a directory may not be removed:</p>
<ul>
<li>It already existed prior to installation. By default, the uninstaller plays it safe and doesn't remove directories that the installer didn't create.</li>
<li>It contains files or subdirectories. Use [UninstallDelete] if you need the uninstaller to delete additional files/directories.</li>
<li>A running process has the directory as its current directory.</li>
</ul>
<p>Note: In Inno Setup versions prior to 2.0.1, directories must be specified in either the [Dirs] or [UninstallDelete] sections for them to be deleted by the uninstaller. In newer Inno Setup versions, directories created by [Files] section entries will be deleted automatically by the uninstaller if they didn't exist prior to installation.</p>
</blockquote>
<h4><a name="batchfile">I run a batch file in the [Run] section, but the window remains on the screen after it finishes executing. I'd like it to "close on exit."</a></h4>
<blockquote>
<p>From Tim Rude:<br />
The simplest way to get a batch file to automatically close on exit is to clear the screen at the end of it using the CLS command.</p>
<p><i>--- batch file 1 ---</i></p>
<p><tt>
@echo off<br />
echo Hello World<br />
echo This batch file does NOT close on exit
</tt></p>
<p><i>--- batch file 2 ---</i></p>
<p><tt>
@echo off<br />
echo Hello World<br />
echo This batch file DOES close on exit<br />
cls
</tt></p>
</blockquote>
<h4><a name="olddir">I've changed DefaultDirName in my script, yet when I run Setup it defaults to the directory I had before.</a></h4>
<blockquote>
<p>At startup Setup looks in the registry to see if the same application was already installed previously, and if so, it will use the directory of the previous installation as the default directory presented to the user in the wizard. If you uninstall the application and run Setup again, it will use the new DefaultDirName setting. If you wish to disable this feature, set UsePreviousAppDir to "no".</p>
</blockquote>
<h4><a name="twoicons">I have two [Icons] entries with the same Name, but only one of them gets installed.</a></h4>
<blockquote>
<p>Two files can't have the same name, and since shortcuts are files, two shortcuts therefore can't have the same name.</p>
</blockquote>
<h4><a name="runwait">Setup isn't waiting for a program executed by a [Run] entry to finish.</a></h4>
<blockquote>
<p>First, make sure that you are <i>not</i> using the "nowait" or "waituntilidle" flags on the [Run] entry. These flags prevent Setup from waiting until the process completely terminates.</p>
<p>If you aren't using those flags and it still doesn't seem to be waiting for the program to finish, then likely what is happening is that the EXE you're running is spawning some other process and then terminating itself immediately, causing Setup to think the program has finished. This is known to happen with older InstallShield-based installers (to work around it, try using the <a href="http://www.installshield.com/news/newsletter/0206-articles/LaunchIS5Setup.asp">/SMS switch</a>).</p>
<p>A simple way to check if a program does that is to run "START /WAIT ProgramName.exe" from the command line, and see if you are returned to the command prompt before the program exits.</p>
</blockquote>
<h4><a name="missinglanguages">Some languages are missing on the <i>Select Setup Language</i> dialog, or it doesn't show up at all.</a></h4>
<blockquote>
<p>You are using Non Unicode Inno Setup:</li>
<p>Beginning with Inno Setup 4.2.2, languages specified in the [Languages] section that cannot be displayed under the active Windows ANSI code page are not listed in the <i>Select Setup Language</i> dialog. For example, Russian text can only be displayed properly if the active code page is 1251; if the user isn't running code page 1251 they will not see Russian as an option.</p>
<p>On Windows XP, the active code page may be changed by going to <i>Regional and Language Options</i> in Control Panel, and setting <i>Language for non-Unicode programs</i> on the Advanced tab. On Windows 2000, the active code page may be changed by going to <i>Regional Options</i> in Control Panel, and clicking <i>Set default...</i>.</p>
<p>If you are sure you're running in the correct code page and a language still isn't being listed, then most likely <tt>LanguageCodePage</tt> is set incorrectly inside the language's .isl file.</p>
<p>If you would like to force all languages to be visible regardless of whether they can be displayed properly under the active code page, set the <tt>ShowUndisplayableLanguages</tt> [Setup] section directive (new in Inno Setup 5.1.7).</p>
</blockquote>
<hr /><h2>Installation Tasks</h2>
<h4><a name="urls">Creating Internet (URL) Shortcuts</a></h4>
<blockquote>
<p>First create a file named, for example, "website.url", and place these lines inside it:</p>
<p><tt>[InternetShortcut]<br />
URL=http://web.site.address/
</tt></p>
<p>Then add these lines to your script:</p>
<p><tt><b>[Files]</b><br />
<font color="blue">Source</font>: "website.url"; <font color="blue">DestDir</font>: "{app}"<br />
<br />
<b>[Icons]</b><br />
<font color="blue">Name</font>: "{group}\Visit My Web Site"; <font color="blue">Filename</font>: "{app}\website.url"<br />
</tt></p>
</blockquote>
<h4><a name="startin">Setting the "Start In" Field on a Shortcut</a></h4>
<blockquote>
<p>Use a WorkingDir parameter on the [Icons] section entry.</p>
</blockquote>
<h4><a name="assoc">Creating File Associations</a></h4>
<blockquote>
<p>First set the [Setup] section directive "ChangesAssociations" to "yes". Then create [Registry] entries as shown below. </p>
<p><tt>
<b>[Registry]</b><br />
<font color="blue">Root</font>: HKCR; <font color="blue">Subkey</font>: ".myp"; <font color="blue">ValueType</font>: string; <font color="blue">ValueName</font>: ""; ValueData: "MyProgramFile"; <font color="blue">Flags</font>: uninsdeletevalue
</tt></p>
<blockquote>
".myp" is the extension we're associating. "MyProgramFile" is the internal name for the file type as stored in the registry. Make sure you use a unique name for this so you don't inadvertently overwrite another application's registry key.
</blockquote>
<p><tt>
<font color="blue">Root</font>: HKCR; <font color="blue">Subkey</font>: "MyProgramFile"; <font color="blue">ValueType</font>: string; <font color="blue">ValueName</font>: ""; <font color="blue">ValueData</font>: "My Program File"; <font color="blue">Flags</font>: uninsdeletekey
</tt></p>
<blockquote>
"My Program File" above is the name for the file type as shown in Explorer.
</blockquote>
<p><tt>
<font color="blue">Root</font>: HKCR; <font color="blue">Subkey</font>: "MyProgramFile\DefaultIcon"; <font color="blue">ValueType</font>: string; <font color="blue">ValueName</font>: ""; <font color="blue">ValueData</font>: "{app}\MYPROG.EXE,0"
</tt></p>
<blockquote>
"DefaultIcon" is the registry key that specifies the filename containing the icon to associate with the file type. ",0" tells Explorer to use the first icon from MYPROG.EXE. (",1" would mean the second icon.)
</blockquote>
<p><tt>
<font color="blue">Root</font>: HKCR; <font color="blue">Subkey</font>: "MyProgramFile\shell\open\command"; <font color="blue">ValueType</font>: string; <font color="blue">ValueName</font>: ""; <font color="blue">ValueData</font>: """{app}\MYPROG.EXE"" ""%1"""
</tt></p>
<blockquote>
"shell\open\command" is the registry key that specifies the program to execute when a file of the type is double-clicked in Explorer. The surrounding quotes are in the command line so it handles long filenames correctly.
</blockquote>
</blockquote>
<h4><a name="env">Setting Environment Variables</a></h4>
<blockquote>
<p>Environment variables are stored as string values in the registry, so it is possible to manipulate them using the [Registry] section. System-wide environment variables are located at:</p>
<blockquote>HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment</blockquote>
<p>User-specific environment variables are located at:</p>
<blockquote>HKEY_CURRENT_USER\Environment</blockquote>
</blockquote>
<h4><a name="closeonexit">Setting the "Close on Exit" Box on a Shortcut to an MS-DOS Program</a></h4>
<blockquote>
<p>Inno Setup version 1.3.15 and later includes support for "closeonexit" and "dontcloseonexit" flags in the [Icons] section.</p>
</blockquote>
<h4><a name="backup">Making Backups Before Replacing Files</a></h4>
<blockquote>
<p>Inno Setup does not currently have a specific feature for doing that, but you can make a copy of a file before it is replaced by using a [Files] section entry similar to this:</p>
<p><tt><font color="blue">Source</font>: "{app}\MyProg.exe"; <font color="blue">DestDir</font>: "{app}\backup"; <font color="blue">Flags</font>: external skipifsourcedoesntexist uninsneveruninstall</tt></p>
</blockquote>
<h4><a name="difffiles">Installing Different Files Depending on Windows Version</a></h4>
<blockquote>
<p>That can be done via MinVersion and/or OnlyBelowVersion parameters on an entry. See the Common Parameters topic in the documentation for details.</p>
</blockquote>
<h4><a name="perms">Settings Permissions on Files, Directories, or Registry Keys</a></h4>
<blockquote>
<p>Beginning with Inno Setup 4.1.0, the [Dirs], [Files], and [Registry] sections support Permissions parameters for setting permissions on directories, files, and registry keys respectively.</p>
<p>If you have more advanced needs, take a look at <a href="http://setacl.sourceforge.net/">SetACL</a>.</p>
</blockquote>
<h4><a name="custom">My installation needs to do something that Inno Setup apparently doesn't have a feature for.</a></h4>
<blockquote>
<p>See the Knowledge Base article <a href="http://www.jrsoftware.org/iskb.php?custom">Implementing Custom Functionality</a>.</p>
</blockquote>
<hr /><h2>How Do I Install...?</h2>
<h4><a name="ocx">OCX Files</a></h4>
<blockquote>
<p>The recommended way to install an OCX file is as follows.</p>
<p><tt>
<b>[Files]</b><br />
<font color="blue">Source</font>: "ComCtl32.ocx";
<font color="blue">DestDir</font>: "{sys}";
<font color="blue">CopyMode</font>: alwaysskipifsameorolder;
<font color="blue">Flags</font>: restartreplace sharedfile regserver
</tt></p>
</blockquote>
<h4><a name="vb">Visual Basic System Files</a></h4>
<blockquote>
<p>See <a href="http://www.jrsoftware.org/iskb.php?vb">this Knowledge Base article</a>.</p>
</blockquote>
<h4><a name="vc">Visual C++ System Files (e.g. MFC)</a></h4>
<blockquote>
<p>See <a href="http://www.jrsoftware.org/iskb.php?vc">this Knowledge Base article</a>.</p>
</blockquote>
<h4><a name="comctl32">COMCTL32.DLL</a></h4>
<blockquote>
<p>If your application requires an updated version of COMCTL32.DLL, you can direct your users to
<a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=cb2cf3a2-8025-4e8f-8511-9b476a8d35d2&amp;DisplayLang=en">download</a>
the COMCTL32 update from Microsoft, or call the COMCTL32 update from your installation by using the following lines:</p>
<p><tt>
<b>[Files]</b><br />
<font color="blue">Source</font>: "50comupd.exe"; <font color="blue">DestDir</font>: "{tmp}"<br />
<br />
<b>[Code]</b><br />
function ShouldInstallComCtlUpdate: Boolean;<br />
var<br />
&nbsp;&nbsp;MS, LS: Cardinal;<br />
begin<br />
&nbsp;&nbsp;// Only install if the existing comctl32.dll is &lt; 5.80<br />
&nbsp;&nbsp;Result := False;<br />
&nbsp;&nbsp;if GetVersionNumbers(ExpandConstant('{sys}\comctl32.dll'), MS, LS) then<br />
&nbsp;&nbsp;&nbsp;&nbsp;if MS &lt; $00050050 then<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Result := True;<br />
end;<br />
<br />
<b>[Run]</b><br />
<font color="blue">Filename</font>: "{tmp}\50comupd.exe"; <font color="blue">Parameters</font>: "/r:n /q:1"; <font color="blue">Check</font>: ShouldInstallComCtlUpdate
</tt></p>
<p>Don't try to install COMCTL32.DLL directly using the [Files] section; Microsoft <a href="http://www.microsoft.com/permission/copyrgt/cop-soft.htm#COM">does not allow</a> this, and it's dangerous.</p>
</blockquote>
<h4><a name="bde">BDE (Borland Database Engine)</a></h4>
<blockquote>
<p>See the Knowledge Base article <a href="http://www.jrsoftware.org/iskb.php?bde">Installing BDE</a> for details on deploying the 32-bit version of BDE using Inno Setup.</p>
</blockquote>
<h4><a name="mdac">MDAC, ADO, Jet, etc.</a></h4>
<blockquote>
<p>See <a href="http://www.jrsoftware.org/iskb.php?dcommdac">this Knowledge Base article</a>.</p>
</blockquote>
<hr /><h2>Compatibility</h2>
<h4><a name="oscompat">OS Compatibility</a></h4>
<blockquote>
<p>Currently supported platforms include every Windows release since 2000. No service packs or other OS updates are required on any of the supported platforms.</p>
<p>The 16-bit version of Inno Setup was discontinued starting with version 1.3. Support for Windows NT 3.51 was discontinued starting with version 3.0. Support for Windows 95, 98, Me, and NT 4.0 was discontinued starting with version 5.5.</p>
</blockquote>
<h4><a name="ntsecur">Administrative Privileges</a></h4>
<blockquote>
<p>A typical Inno Setup installation does not require administrative or "power user" privileges. However, there are exceptions as noted below.</p>
<p>Things that require administrative privileges:</p>
<ul>
<li>Using "PrivilegesRequired=admin" in the script's [Setup] section. This causes Setup to abort with an error message if the user lacks administrative privileges.</li>
<li>Using the "restartreplace" flag in the [Files] section. This flag causes Inno Setup to call the MoveFileEx function, which attempts to write to "HKEY_LOCAL_MACHINE\ SYSTEM\ CurrentControlSet\ Control\ Session Manager". Write access to this key is restricted to Administrators.</li>
<li>Writing to any key under HKEY_USERS\.DEFAULT using the [Registry] section. Write access to this key is restricted to Administrators.</li>
</ul>
<p>Things that require <i>either</i> administrative or "power user" privileges:</p>
<ul>
<li>Using "PrivilegesRequired=poweruser" in the script's [Setup] section. This causes Setup to abort with an error message if the user lacks either administrative or "power user" privileges.</li>
<li>Using the "regserver" flag in the [Files] section. In most cases registering a DLL involves writing to HKEY_CLASSES_ROOT, a privilege not granted to ordinary users.</li>
<li>Using the "sharedfile" flag is the [Files] section. This flag causes Inno Setup to create/update a value in "HKEY_LOCAL_MACHINE\ SOFTWARE\ Microsoft\ Windows\ CurrentVersion\ SharedDLLs". Ordinary users are not allowed to write to that key.</li>
<li>Using the FontInstall parameter in the [Files] section.</li>
<li>Writing to any key under HKEY_LOCAL_MACHINE or HKEY_CLASSES_ROOT using the [Registry] section. Ordinary users are not allowed to write to those keys.</li>
</ul>
<p>Inno Setup itself does not require write access to the WINNT directory, or any other registry keys not mentioned above.</p>
<p>What is different when an installation is run by a user <i>without</i> administrative privileges?</p>
<ul>
<li>The registry key for the <i>Add/Remove Programs</i> Control Panel entry is created under HKEY_CURRENT_USER instead of HKEY_LOCAL_MACHINE. Thus, only the user who installed the program will see an <i>Add/Remove Programs</i> entry for it.</li>
<li>The "{group}" constant always points to the current user's profile, as opposed to the All Users profile.</li>
<li>All "{common...}" constants are equivalent to the "{user...}" constants.</li>
<li>The program may be uninstalled by any user. (When an administrator installs a program, only an administrator is allowed to uninstall it.)</li>
</ul>
</blockquote>
<hr /><h2>Miscellaneous</h2>
<h4><a name="limits">Are there any limits on how many files, etc. may be included in an installation?</a></h4>
<blockquote>
<p>Inno Setup places no arbitrary limits on how many files, shortcuts, registry entries, etc. that you may include in an installation. However, keep in mind that Setup does need memory for each entry in a script. For example, roughly 120 bytes of memory is needed for each [Files] entry.</p>
<p>In Inno Setup 3.x and earlier, installations and individual files cannot exceed 2 GB, because it does not use 64-bit arithmetic in most places. This has been addressed in Inno Setup 4.</p>
</blockquote>
<h4><a name="cancel">What exactly happens when the user clicks Cancel during an installation?</a></h4>
<blockquote>
<p>When Cancel is clicked, Setup will begin reverting changes it's made so far in the very same manner as the Uninstall program. Thus, a partially installed application isn't left over.</p>
</blockquote>
</body>
</html>
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+37
View File
@@ -0,0 +1,37 @@
Inno Setup License
==================
Except where otherwise noted, all of the documentation and software included
in the Inno Setup package is copyrighted by Jordan Russell.
Copyright (C) 1997-2016 Jordan Russell. All rights reserved.
Portions Copyright (C) 2000-2016 Martijn Laan. All rights reserved.
This software is provided "as-is," without any express or implied warranty.
In no event shall the author be held liable for any damages arising from the
use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter and redistribute it,
provided that the following conditions are met:
1. All redistributions of source code files must retain all copyright
notices that are currently in place, and this list of conditions without
modification.
2. All redistributions in binary form must retain all occurrences of the
above copyright notice and web site addresses that are currently in
place (for example, in the About boxes).
3. The origin of this software must not be misrepresented; you must not
claim that you wrote the original software. If you use this software to
distribute a product, an acknowledgment in the product documentation
would be appreciated but is not required.
4. Modified versions in source or binary form must be plainly marked as
such, and must not be misrepresented as being the original software.
Jordan Russell
jr-2010 AT jrsoftware.org
http://www.jrsoftware.org/
+33
View File
@@ -0,0 +1,33 @@
[Setup]
AppName=DIY Layout Creator
AppVersion={#diylcver}
DefaultDirName={pf}\DIYLC
DefaultGroupName=DIY Layout Creator
UninstallDisplayIcon={app}\diylc.exe
Compression=lzma2
SolidCompression=yes
OutputDir=build
OutputBaseFilename=diylc
ChangesAssociations=yes
[Files]
Source: "diylc.exe"; DestDir: "{app}"
Source: "diylc.l4j.ini"; DestDir: "{app}"
Source: "config.xml"; DestDir: "{app}"
Source: "update.xml"; DestDir: "{app}"
Source: "build\jar\diylc.jar"; DestDir: "{app}"
Source: "build\jar\lib\*"; DestDir: "{app}\lib"
Source: "build\jar\library\*"; DestDir: "{app}\library"
[Registry]
Root: HKCR; Subkey: ".diy"; ValueData: "DIYLC"; Flags: uninsdeletevalue; ValueType: string; ValueName: ""
Root: HKCR; Subkey: "DIYLC"; ValueData: "Program DIYLC"; Flags: uninsdeletekey; ValueType: string; ValueName: ""
Root: HKCR; Subkey: "DIYLC\DefaultIcon"; ValueData: "{app}\diylc.exe,0"; ValueType: string; ValueName: ""
Root: HKCR; Subkey: "DIYLC\shell\open\command"; ValueData: """{app}\diylc.exe"" ""%1"""; ValueType: string; ValueName: ""
[Icons]
Name: "{group}\DIY Layout Creator"; Filename: "{app}\diylc.exe"
[Run]
Filename: "{app}\diylc.exe"; Flags: postinstall skipifsilent
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -43,6 +43,8 @@ public class DIYLCStarter {
LOG.error("Could not initialize log4j configuration", e); LOG.error("Could not initialize log4j configuration", e);
} }
ConfigurationManager.initialize("diylc");
LOG.debug("Java version: " + System.getProperty("java.runtime.version") + " by " LOG.debug("Java version: " + System.getProperty("java.runtime.version") + " by "
+ System.getProperty("java.vm.vendor")); + System.getProperty("java.vm.vendor"));
LOG.debug("OS: " + System.getProperty("os.name") + " " + System.getProperty("os.version")); LOG.debug("OS: " + System.getProperty("os.name") + " " + System.getProperty("os.version"));
@@ -112,18 +112,7 @@ public class MainFrame extends JFrame implements ISwingUI {
presenter.installPlugin(new ComponentTree(this, canvasPlugin.getCanvasPanel())); presenter.installPlugin(new ComponentTree(this, canvasPlugin.getCanvasPanel()));
presenter.installPlugin(new FramePlugin()); presenter.installPlugin(new FramePlugin());
try { presenter.installPlugin(new AutoSavePlugin(this));
File testFile = new File("test.tmp");
Writer out = new OutputStreamWriter(new FileOutputStream(testFile));
out.write("This is a test");
out.close();
testFile.delete();
presenter.installPlugin(new AutoSavePlugin(this));
} catch (Exception e) {
showMessage("The current user does not have permissions to access folder " + new File(".").getAbsolutePath()
+ ".\nAuto-save feature will not be available, contact your system administrator.", "Warning",
IView.WARNING_MESSAGE);
}
presenter.createNewProject(); presenter.createNewProject();
@@ -8,6 +8,7 @@ import java.util.concurrent.Executors;
import javax.swing.SwingUtilities; import javax.swing.SwingUtilities;
import org.diylc.appframework.miscutils.ConfigurationManager; import org.diylc.appframework.miscutils.ConfigurationManager;
import org.diylc.appframework.miscutils.Utils;
import org.diylc.common.EventType; import org.diylc.common.EventType;
import org.diylc.common.IPlugIn; import org.diylc.common.IPlugIn;
import org.diylc.common.IPlugInPort; import org.diylc.common.IPlugInPort;
@@ -17,7 +18,7 @@ import org.diylc.swing.gui.DummyView;
public class AutoSavePlugin implements IPlugIn { public class AutoSavePlugin implements IPlugIn {
private static final String AUTO_SAVE_FILE_NAME = "autoSave.diy"; private static final String AUTO_SAVE_FILE_NAME = Utils.getUserDataDirectory("diylc") + "autoSave.diy";
protected static final long autoSaveFrequency = 60 * 1000; protected static final long autoSaveFrequency = 60 * 1000;
+8
View File
@@ -1654,6 +1654,14 @@
<changeType>NEW_FEATURE</changeType> <changeType>NEW_FEATURE</changeType>
<description>Ability to set project-wide default font through 'Edit Project Settings' dialog.</description> <description>Ability to set project-wide default font through 'Edit Project Settings' dialog.</description>
</org.diylc.appframework.update.Change> </org.diylc.appframework.update.Change>
<org.diylc.appframework.update.Change>
<changeType>NEW_FEATURE</changeType>
<description>Added Windows installer.</description>
</org.diylc.appframework.update.Change>
<org.diylc.appframework.update.Change>
<changeType>IMPROVEMENT</changeType>
<description>Moved config and auto-save file locations to standard user directory instead of using the app directory.</description>
</org.diylc.appframework.update.Change>
<org.diylc.appframework.update.Change> <org.diylc.appframework.update.Change>
<changeType>IMPROVEMENT</changeType> <changeType>IMPROVEMENT</changeType>
<description>Do not allow creating zero-length components (i.e. traces, lines, etc)</description> <description>Do not allow creating zero-length components (i.e. traces, lines, etc)</description>