This shows you the differences between two versions of the page.
userspace:ghostscript_9 [2012/10/04 10:37] bhubal [Ghostscript 9] |
userspace:ghostscript_9 [2021/08/23 08:37] |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Ghostscript 9 ====== | ||
- | 2012-03-23\\ | ||
- | Script by uib GmbH \\ | ||
- | Comments and improvements welcome \\ | ||
- | |||
- | id: ghostscript\\ | ||
- | name: Ghostscript 9\\ | ||
- | description: | ||
- | version: 9.05\\ | ||
- | |||
- | Full package: http:// | ||
- | |||
- | ==== setup3264.ins ==== | ||
- | |||
- | <code winst> | ||
- | |||
- | ; This sourcecode is owned by uib | ||
- | ; and published under the Terms of the General Public License. | ||
- | ; credits: http:// | ||
- | |||
- | [Actions] | ||
- | requiredWinstVersion >= " | ||
- | |||
- | DefVar $MsiId32$ | ||
- | DefVar $UninstallProgram32$ | ||
- | DefVar $MsiId64$ | ||
- | DefVar $UninstallProgram64$ | ||
- | DefVar $LogDir$ | ||
- | DefVar $ProductId$ | ||
- | DefVar $MinimumSpace$ | ||
- | DefVar $InstallDir32$ | ||
- | DefVar $InstallDir64$ | ||
- | DefVar $ExitCode$ | ||
- | DefVar $LicenseRequired$ | ||
- | DefVar $LicenseKey$ | ||
- | DefVar $LicensePool$ | ||
- | DefVar $INST_SystemType$ | ||
- | DefVar $INST_architecture$ | ||
- | DefVar $Installtempdir$ | ||
- | |||
- | Set $Installtempdir$ = " | ||
- | |||
- | Set $INST_SystemType$ = GetSystemType | ||
- | set $INST_architecture$ = GetProductProperty(" | ||
- | |||
- | |||
- | Set $LogDir$ = " | ||
- | |||
- | ; ---------------------------------------------------------------- | ||
- | ; - Please edit the following values | ||
- | ; ---------------------------------------------------------------- | ||
- | ; | ||
- | ; therefore please: only lower letters, no umlauts, | ||
- | ; no white space use ' | ||
- | Set $ProductId$ | ||
- | Set $MinimumSpace$ | ||
- | ; the path were we find the product after the installation | ||
- | Set $InstallDir32$ | ||
- | Set $InstallDir64$ | ||
- | Set $LicenseRequired$ = " | ||
- | Set $LicensePool$ | ||
- | ; ---------------------------------------------------------------- | ||
- | |||
- | if not(HasMinimumSpace (" | ||
- | LogError "Not enough space on %SystemDrive%, | ||
- | isFatalError | ||
- | ; Stop process and set installation status to failed | ||
- | else | ||
- | comment "Show product picture" | ||
- | ShowBitmap " | ||
- | |||
- | if FileExists(" | ||
- | comment "Start uninstall sub section" | ||
- | Sub " | ||
- | endif | ||
- | |||
- | if $LicenseRequired$ = " | ||
- | comment " | ||
- | Sub_get_licensekey | ||
- | endif | ||
- | |||
- | comment " | ||
- | |||
- | if ($INST_SystemType$ = "x86 System" | ||
- | Message " | ||
- | comment "Copy files" | ||
- | Files_install_32 /32Bit | ||
- | comment "Start setup program" | ||
- | Winbatch_install_32 | ||
- | Sub_check_exitcode | ||
- | comment "Patch Registry" | ||
- | Registry_install /32Bit | ||
- | comment " | ||
- | LinkFolder_install | ||
- | endif | ||
- | |||
- | if ($INST_SystemType$ = "64 Bit System" | ||
- | Message " | ||
- | Files_install_64 /64Bit | ||
- | comment "Start setup program" | ||
- | Winbatch_install_64 | ||
- | Sub_check_exitcode | ||
- | endif | ||
- | |||
- | endif | ||
- | |||
- | [Winbatch_install_32] | ||
- | ;" | ||
- | " | ||
- | |||
- | [Files_install_32] | ||
- | copy -sv %SCRIPTPATH%\gs905w32.exe $Installtempdir$ | ||
- | |||
- | [Files_del] | ||
- | delete -f " | ||
- | delete -f " | ||
- | |||
- | |||
- | [Winbatch_install_64] | ||
- | ; === Nullsoft Scriptable Install System ================================================================ | ||
- | " | ||
- | " | ||
- | |||
- | [Files_install_64] | ||
- | copy -sv %SCRIPTPATH%\gs905w64.exe $Installtempdir$ | ||
- | |||
- | [Registry_install] | ||
- | ; Example of setting some values of an registry key: | ||
- | ; | ||
- | ; openkey [HKEY_LOCAL_MACHINE\Software\$ProductId$] | ||
- | ; set " | ||
- | ; set " | ||
- | ; set " | ||
- | |||
- | [LinkFolder_install] | ||
- | ; Example of deleting a folder from AllUsers startmenu: | ||
- | ; | ||
- | ; set_basefolder common_programs | ||
- | ; delete_subfolder $ProductId$ | ||
- | ; | ||
- | ; Example of creating an shortcut to the installed exe in AllUsers startmenu: | ||
- | ; | ||
- | ; set_basefolder common_programs | ||
- | ; set_subfolder $ProductId$ | ||
- | ; | ||
- | ; set_link | ||
- | ; name: $ProductId$ | ||
- | ; target: <path to the program> | ||
- | ; parameters: | ||
- | ; working_dir: | ||
- | ; icon_file: | ||
- | ; icon_index: | ||
- | ; end_link | ||
- | ; | ||
- | ; Example of creating an shortcut to the installed exe on AllUsers desktop: | ||
- | ; | ||
- | ; set_basefolder common_desktopdirectory | ||
- | ; set_subfolder "" | ||
- | ; | ||
- | ; set_link | ||
- | ; name: $ProductId$ | ||
- | ; target: <path to the program> | ||
- | ; parameters: | ||
- | ; working_dir: | ||
- | ; icon_file: <path to icon file> | ||
- | ; icon_index: | ||
- | ; end_link | ||
- | |||
- | [Sub_get_licensekey] | ||
- | comment " | ||
- | |||
- | comment " | ||
- | Set $LicenseKey$ = demandLicenseKey ($LicensePool$) | ||
- | ; If there is an assignment of exactly one licensepool to the product the following call is possible: | ||
- | ; Set $LicenseKey$ = demandLicenseKey ("", | ||
- | ; | ||
- | ; If there is an assignment of a license pool to a windows software id, it is possible to use: | ||
- | ; DefVar $WindowsSoftwareId$ | ||
- | ; $WindowsSoftwareId$ = " | ||
- | ; Set $LicenseKey$ = demandLicenseKey ("", | ||
- | |||
- | DefVar $ServiceErrorClass$ | ||
- | set $ServiceErrorClass$ = getLastServiceErrorClass | ||
- | comment "Error class: " + $ServiceErrorClass$ | ||
- | |||
- | if $ServiceErrorClass$ = " | ||
- | comment " | ||
- | else | ||
- | if $ServiceErrorClass$ = " | ||
- | LogError " | ||
- | LogError getLastServiceErrorMessage | ||
- | isFatalError | ||
- | else | ||
- | if $ServiceErrorClass$ = " | ||
- | LogError " | ||
- | isFatalError | ||
- | endif | ||
- | endif | ||
- | endif | ||
- | |||
- | [Sub_check_exitcode] | ||
- | comment "Test for installation success via exit code" | ||
- | set $ExitCode$ = getLastExitCode | ||
- | ; informations to exit codes see | ||
- | ; http:// | ||
- | ; http:// | ||
- | if ($ExitCode$ = " | ||
- | comment "Looks good: setup program gives exitcode zero" | ||
- | else | ||
- | comment "Setup program gives a exitcode unequal zero: " + $ExitCode$ | ||
- | if ($ExitCode$ = " | ||
- | comment " | ||
- | comment " | ||
- | else | ||
- | if ($ExitCode$ = " | ||
- | comment "looks good: setup program gives exitcode 1641" | ||
- | comment " | ||
- | else | ||
- | if ($ExitCode$ = " | ||
- | comment "looks good: setup program gives exitcode 3010" | ||
- | comment " | ||
- | else | ||
- | logError " | ||
- | isFatalError | ||
- | endif | ||
- | endif | ||
- | endif | ||
- | endif | ||
- | </ | ||
- | |||
- | ==== delsub3264.ins ==== | ||
- | |||
- | <code winst> | ||
- | ; Copyright (c) uib gmbh (www.uib.de) | ||
- | ; This sourcecode is owned by uib gmbh | ||
- | ; and published under the Terms of the General Public License. | ||
- | ; credits: http:// | ||
- | |||
- | |||
- | Set $MsiId32$ = ' | ||
- | Set $UninstallProgram32$ = $InstallDir32$ + " | ||
- | |||
- | Set $MsiId64$ = ' | ||
- | Set $UninstallProgram64$ = $InstallDir64$ + " | ||
- | |||
- | ;if (($INST_SystemType$ = "x86 System" | ||
- | Message " | ||
- | |||
- | if FileExists($UninstallProgram32$) | ||
- | comment " | ||
- | Winbatch_uninstall_32 | ||
- | sub_check_exitcode | ||
- | endif | ||
- | |||
- | if not (GetRegistryStringValue32(" | ||
- | comment "MSI id " + $MsiId32$ + " found in registry, starting msiexec to uninstall" | ||
- | Winbatch_uninstall_msi_32 | ||
- | sub_check_exitcode | ||
- | endif | ||
- | |||
- | comment " | ||
- | Files_uninstall_32 /32Bit | ||
- | comment " | ||
- | Registry_uninstall /32Bit | ||
- | ;endif | ||
- | |||
- | ;if ($INST_SystemType$ = "64 Bit System" | ||
- | ; Message " | ||
- | |||
- | ; if FileExists($UninstallProgram64$) | ||
- | ; comment " | ||
- | ; | ||
- | ; | ||
- | ; endif | ||
- | ; | ||
- | ; if not (GetRegistryStringValue64(" | ||
- | ; comment "MSI id " + $MsiId64$ + " found in registry, starting msiexec to uninstall" | ||
- | ; | ||
- | ; | ||
- | ; endif | ||
- | |||
- | ; comment " | ||
- | ; | ||
- | ; comment " | ||
- | ; | ||
- | ;endif | ||
- | |||
- | comment " | ||
- | LinkFolder_uninstall | ||
- | |||
- | [Winbatch_uninstall_32] | ||
- | ; Choose one of the following examples as basis for program uninstall | ||
- | ; | ||
- | ; === Nullsoft Scriptable Install System ================================================================ | ||
- | " | ||
- | ; | ||
- | ; === Inno Setup ======================================================================================== | ||
- | ; " | ||
- | |||
- | |||
- | [Winbatch_uninstall_msi_32] | ||
- | msiexec /x $MsiId32$ /qb! REBOOT=ReallySuppress | ||
- | |||
- | [Files_uninstall_32] | ||
- | ; Example for recursively deleting the installation directory (don't forget the trailing backslash): | ||
- | ; | ||
- | | ||
- | |||
- | [Winbatch_uninstall_64] | ||
- | ; Choose one of the following examples as basis for program uninstall | ||
- | ; | ||
- | ; === Nullsoft Scriptable Install System ================================================================ | ||
- | " | ||
- | ; | ||
- | ; === Inno Setup ======================================================================================== | ||
- | ; " | ||
- | |||
- | |||
- | [Winbatch_uninstall_msi_64] | ||
- | msiexec /x $MsiId64$ /qb! REBOOT=ReallySuppress | ||
- | |||
- | [Files_uninstall_64] | ||
- | ; Example for recursively deleting the installation directory (don't forget the trailing backslash): | ||
- | ; | ||
- | | ||
- | |||
- | [Registry_uninstall] | ||
- | ; Example of deleting a registry key: | ||
- | ; | ||
- | ; deletekey [HKEY_LOCAL_MACHINE\Software\$ProductId$] | ||
- | |||
- | [LinkFolder_uninstall] | ||
- | ; Example of deleting a folder from AllUsers startmenu: | ||
- | ; | ||
- | ; set_basefolder common_programs | ||
- | ; delete_subfolder $ProductId$ | ||
- | ; | ||
- | ; Example of deleting a shortcut from AllUsers desktop: | ||
- | ; | ||
- | ; set_basefolder common_desktopdirectory | ||
- | ; set_subfolder "" | ||
- | ; delete_element $ProductId$ | ||
- | |||
- | [Sub_check_exitcode] | ||
- | comment "Test for installation success via exit code" | ||
- | set $ExitCode$ = getLastExitCode | ||
- | ; informations to exit codes see | ||
- | ; http:// | ||
- | ; http:// | ||
- | if ($ExitCode$ = " | ||
- | comment "Looks good: setup program gives exitcode zero" | ||
- | else | ||
- | comment "Setup program gives a exitcode unequal zero: " + $ExitCode$ | ||
- | if ($ExitCode$ = " | ||
- | comment " | ||
- | comment " | ||
- | else | ||
- | if ($ExitCode$ = " | ||
- | comment "looks good: setup program gives exitcode 1641" | ||
- | comment " | ||
- | else | ||
- | if ($ExitCode$ = " | ||
- | comment "looks good: setup program gives exitcode 3010" | ||
- | comment " | ||
- | else | ||
- | logError " | ||
- | isFatalError | ||
- | endif | ||
- | endif | ||
- | endif | ||
- | endif | ||
- | |||
- | </ | ||
- | |||
- | ==== uninstall3264.ins ==== | ||
- | |||
- | <code winst> | ||
- | ; Copyright (c) uib gmbh (www.uib.de) | ||
- | ; This sourcecode is owned by uib gmbh | ||
- | ; and published under the Terms of the General Public License. | ||
- | ; credits: http:// | ||
- | |||
- | [Actions] | ||
- | requiredWinstVersion >= " | ||
- | |||
- | DefVar $MsiId32$ | ||
- | DefVar $UninstallProgram32$ | ||
- | DefVar $MsiId64$ | ||
- | DefVar $UninstallProgram64$ | ||
- | DefVar $LogDir$ | ||
- | DefVar $ExitCode$ | ||
- | DefVar $ProductId$ | ||
- | DefVar $InstallDir32$ | ||
- | DefVar $InstallDir64$ | ||
- | DefVar $LicenseRequired$ | ||
- | DefVar $LicensePool$ | ||
- | DefVar $INST_SystemType$ | ||
- | DefVar $INST_architecture$ | ||
- | |||
- | Set $INST_SystemType$ = GetSystemType | ||
- | set $INST_architecture$ = GetProductProperty(" | ||
- | |||
- | |||
- | Set $LogDir$ = " | ||
- | |||
- | ; ---------------------------------------------------------------- | ||
- | ; - Please edit the following values | ||
- | ; ---------------------------------------------------------------- | ||
- | Set $ProductId$ | ||
- | Set $InstallDir32$ | ||
- | Set $InstallDir64$ | ||
- | Set $LicenseRequired$ = " | ||
- | Set $LicensePool$ | ||
- | ; ---------------------------------------------------------------- | ||
- | |||
- | |||
- | comment "Show product picture" | ||
- | ShowBitmap " | ||
- | |||
- | Message " | ||
- | |||
- | if FileExists(" | ||
- | comment "Start uninstall sub section" | ||
- | Sub " | ||
- | endif | ||
- | |||
- | if $LicenseRequired$ = " | ||
- | comment " | ||
- | Sub_free_license | ||
- | endif | ||
- | |||
- | [Sub_free_license] | ||
- | comment " | ||
- | |||
- | comment " | ||
- | DefVar $result$ | ||
- | Set $result$ = FreeLicense($LicensePool$) | ||
- | ; If there is an assignment of a license pool to the product, it is possible to use | ||
- | ; Set $result$ = FreeLicense("", | ||
- | ; | ||
- | ; If there is an assignment of a license pool to a windows software id, it is possible to use | ||
- | ; DefVar $WindowsSoftwareId$ | ||
- | ; $WindowsSoftwareId$ = " | ||
- | ; set $result$ = FreeLicense("", | ||
- | |||
- | |||
- | </ | ||
- | |||