Remove remaining Innosetup installer files.

Innosetup installer was removed earlier but some files related to it
were not removed.
This commit is contained in:
Kimmo Varis 2010-06-28 15:51:03 +03:00
parent f82895c1f2
commit 357e76484d
4 changed files with 0 additions and 226 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 KiB

View File

@ -1,157 +0,0 @@
// ----------------------------------------------------------------------------
//
// Inno Setup Ver: 5.2.1
// Script Version: 1.3.1
// Author: Jared Breland <jbreland@legroom.net>
// Homepage: http://www.legroom.net/software
//
// Script Function:
// Enable modification of system path directly from Inno Setup installers
//
// Instructions:
// Copy modpath.iss to the same directory as your setup script
//
// Add this statement to your [Setup] section
// ChangesEnvironment=yes
//
// Add this statement to your [Tasks] section
// You can change the Description or Flags, but the Name must be modifypath
// Name: modifypath; Description: &Add application directory to your system path; Flags: unchecked
//
// Add the following to the end of your [Code] section
// setArrayLength must specify the total number of dirs to be added
// Dir[0] contains first directory, Dir[1] contains second, etc.
// function ModPathDir(): TArrayOfString;
// var
// Dir: TArrayOfString;
// begin
// setArrayLength(Dir, 1)
// Dir[0] := ExpandConstant('{app}');
// Result := Dir;
// end;
// #include "modpath.iss"
// ----------------------------------------------------------------------------
procedure ModPath();
var
oldpath: String;
newpath: String;
pathArr: TArrayOfString;
aExecFile: String;
aExecArr: TArrayOfString;
i, d: Integer;
pathdir: TArrayOfString;
begin
// Get array of new directories and act on each individually
pathdir := ModPathDir();
for d := 0 to GetArrayLength(pathdir)-1 do begin
// Modify WinNT path
if UsingWinNT() = true then begin
// Get current path, split into an array
RegQueryStringValue(HKEY_LOCAL_MACHINE, 'SYSTEM\CurrentControlSet\Control\Session Manager\Environment', 'Path', oldpath);
oldpath := oldpath + ';';
i := 0;
while (Pos(';', oldpath) > 0) do begin
SetArrayLength(pathArr, i+1);
pathArr[i] := Copy(oldpath, 0, Pos(';', oldpath)-1);
oldpath := Copy(oldpath, Pos(';', oldpath)+1, Length(oldpath));
i := i + 1;
// Check if current directory matches app dir
if pathdir[d] = pathArr[i-1] then begin
// if uninstalling, remove dir from path
if IsUninstaller() = true then begin
continue;
// if installing, abort because dir was already in path
end else begin
abort;
end;
end;
// Add current directory to new path
if i = 1 then begin
newpath := pathArr[i-1];
end else begin
newpath := newpath + ';' + pathArr[i-1];
end;
end;
// Append app dir to path if not already included
if IsUninstaller() = false then
newpath := newpath + ';' + pathdir[d];
// Write new path
RegWriteStringValue(HKEY_LOCAL_MACHINE, 'SYSTEM\CurrentControlSet\Control\Session Manager\Environment', 'Path', newpath);
// Modify Win9x path
end else begin
// Convert to shortened dirname
pathdir[d] := GetShortName(pathdir[d]);
// If autoexec.bat exists, check if app dir already exists in path
aExecFile := 'C:\AUTOEXEC.BAT';
if FileExists(aExecFile) then begin
LoadStringsFromFile(aExecFile, aExecArr);
for i := 0 to GetArrayLength(aExecArr)-1 do begin
if IsUninstaller() = false then begin
// If app dir already exists while installing, abort add
if (Pos(pathdir[d], aExecArr[i]) > 0) then
abort;
end else begin
// If app dir exists and = what we originally set, then delete at uninstall
if aExecArr[i] = 'SET PATH=%PATH%;' + pathdir[d] then
aExecArr[i] := '';
end;
end;
end;
// If app dir not found, or autoexec.bat didn't exist, then (create and) append to current path
if IsUninstaller() = false then begin
SaveStringToFile(aExecFile, #13#10 + 'SET PATH=%PATH%;' + pathdir[d], True);
// If uninstalling, write the full autoexec out
end else begin
SaveStringsToFile(aExecFile, aExecArr, False);
end;
end;
// Write file to flag modifypath was selected
// Workaround since IsTaskSelected() cannot be called at uninstall and AppName and AppId cannot be "read" in Code section
if IsUninstaller() = false then
SaveStringToFile(ExpandConstant('{app}') + '\uninsTasks.txt', WizardSelectedTasks(False), False);
end;
end;
procedure CurStepChanged(CurStep: TSetupStep);
begin
if CurStep = ssPostInstall then
if IsTaskSelected('modifypath') then
ModPath();
end;
procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
var
appdir: String;
selectedTasks: String;
begin
appdir := ExpandConstant('{app}')
if CurUninstallStep = usUninstall then begin
if LoadStringFromFile(appdir + '\uninsTasks.txt', selectedTasks) then
if Pos('modifypath', selectedTasks) > 0 then
ModPath();
DeleteFile(appdir + '\uninsTasks.txt')
end;
end;
function NeedRestart(): Boolean;
begin
if IsTaskSelected('modifypath') and not UsingWinNT() then begin
Result := True;
end else begin
Result := False;
end;
end;

View File

@ -1,69 +0,0 @@
InnoSetup Windows installer for the cppcheck
--------------------------------------------
NOTE: This installer is OLD and not maintained anymore. See readme.txt for
information about new WiX installer!
Windows installer for both command line cppcheck and for QT-based GUI. All
needed runtimes and libraries are installed.
Command line cppccheck shortcuts are created to start cmd.exe in installation
folder. So when the user selects start menu/desktop icon he gets command prompt
in cppcheck folder.
Get the InnoSetup from:
http://www.innosetup.com/
Be sure to download the 'QuickStart Pack' as it installs some nice tools
like ISTool and preprocessor support.
Files the installer needs:
/COPYING
/readme.txt
/AUTHORS
/src/Release/cppcheck.exe
/win_installer/icon.bmp
/win_installer/LargeLogo.bmp
/win_installer/
/gui/release/gui.exe
/gui/cppcheck_de.qm
/gui/cppcheck_en.qm
/gui/cppcheck_fi.qm
/gui/cppcheck_pl.qm
/gui/cppcheck_ru.qm
/gui/cppcheck_se.qm
NOTE: Remember to convert COPYING and AUTHORS to Windows EOL format! Otherwise
Windows Notepad (default viewer) can't show then properly.
VS Runtime files:
Copy following files to same folder:
- Microsoft.VC90.CRT.manifest
- msvcp90.dll
- msvcr90.dll
and modify RuntimesFolder -macro in begin of cppcheck.iss to point to the
folder where files are. You can find runtime files from VS installation or from
net.
NOTE: To make local installation of runtimes to work you must remove the
publicKeyToken="blahblah" -attribute from the manifest file.
QT Libraries:
Visual Studio is used to build the GUI executable. And QT must be build with VS
also. When building QT make sure you build release targets!
Copy following files to same RuntimesFolder than VS runtime files:
- QtCore4.dll
- QtGui4.dll
- QtXml4.dll
Creating the installer executable:
#1 Open the ISTool and load cppcheck.iss
#2 Update the release version number:
- look for line "#define AppVersion"
#3 Check all files are present:
- from menu: Project / Verify files...
#4 Compile the installer
- from menu: Project / Compile Setup
If compilation succeeds, the installer executable is created into /Build
-folder. The filename is cppcheck-[version]-setup.exe.