Inkscape

From WPKG | Open Source Software Deployment and Distribution
Jump to: navigation, search

Inkscape is a vector graphics editor. It is free software.

Inkscape 0.91[edit]

Inkscape 0.91 introduces 64-bit builds for Windows along with MSI installers. The following package definition removes the old 32-bit 0.48 version before installing the 64-bit MSI.

<package
	id="inkscape"
	name="Inkscape"
	revision="%version%"
	reboot="false">
		
	<variable name="version" value="0.91" />
		
	<check
		type="uninstall"
		condition="versionequalto"
		path="Inkscape %version%"
		value="%version%" />
		
	<install cmd='msiexec /qn /i "%SOFTWARE%\inkscape\inkscape-%version%-x64.msi"' />
		
	<upgrade include="remove" />
	<upgrade include="install" />
		
	<!-- Remove 0.48 EXE installer -->
	<remove cmd='"%PROGRAMFILES(X86)%\Inkscape\uninstall.exe" /S'>
		<exit code='any' />
	</remove>
	<!-- Remove 0.91 x64 MSI -->
	<remove cmd='msiexec /qn /x{81922150-317E-4BB0-A31D-FF1C14F707C5}'>
		<exit code='any' />
	</remove>
</package>

Inkscape 0.48.2[edit]

This version has the following problem: the executable reports the wrong version (0.48.1) in its headers. So this version of the package checks for the uninstall presence instead. It also uses an extra variable to handle the part of the file name that is not part of the version. Previous version that extra part was only "-2" and now is "-1-win32". I personally prefer incremental numbers as package revision (hence the 3). Modify it as needed.

<package
  id="inkscape"
  name="Inkscape"
  revision="3"
  reboot="false"
  priority="50">

  <variable name="version" value="0.48.2" />
  <variable name="extra" value="-1-win32" />

  <check
      type="uninstall"
      condition="exists"
      path="Inkscape %version%" />

  <install cmd='"%SOFTWARE%\inkscape\Inkscape-%version%%extra%.exe" /S' />

  <upgrade cmd='"%SOFTWARE%\inkscape\Inkscape-%version%%extra%.exe" /S' />

  <remove cmd='"%PROGRAMFILES%\Inkscape\uninstall.exe" /S' />

</package>


Inkscape 0.48[edit]

This version cleans up properly after uninstall, so removing the install directory isn't required. Note that although the advertised version is 0.48, the actual version is 0.48.0 and the installer file has a number appended to it.

<package
  id="inkscape"
  name="Inkscape"
  revision="%version%"
  reboot="false"
  priority="50">
	
  <variable name="version" value="0.48.1" />
	
  <check type ="logical" condition="or">
    <check type="file" condition="versionequalto" path="%PROGRAMFILES%\Inkscape\Inkscape.exe" value="0.48.1.0" />
    <check type="file" condition="versionequalto" path="%PROGRAMFILES(x86)%\Inkscape\Inkscape.exe" value="0.48.1.0" />
  </check>

  <install cmd='"%SOFTWARE%\apps\inkscape\Inkscape-%version%-2.exe" /S' />

  <upgrade cmd='"%SOFTWARE%\apps\inkscape\Inkscape-%version%-2.exe" /S' />

  <remove cmd='"%PROGRAMFILES%\Inkscape\uninstall.exe" /S' />
</package>

Inkscape 0.47[edit]

WPKG Package[edit]

To upgrade Inkscape, you need to uninstall the previous version and remove the program directory (the uninstall leaves uninst.exe then new version's installer complains it won't install into a non-empty directory).

<package
  id="inkscape"
  name="Inkscape"
  revision="047"
  reboot="false"
  priority="10">

  <check type="uninstall" condition="exists" path="Inkscape 0.47" />

  <install cmd='"%SOFTWARE%\inkscape\Inkscape-0.47-3.exe" /S /GTK=OFF' />

  <upgrade cmd='cmd /c "IF EXIST "%PROGRAMFILES%\Inkscape\inkscape.exe" "%PROGRAMFILES%\Inkscape\Uninstall.exe"" /S' />
  <upgrade cmd='cmd /c "IF EXIST "%PROGRAMFILES%\Inkscape\nul.ext" rmdir "%PROGRAMFILES%\Inkscape" /s /q"' />
  <upgrade cmd="%SOFTWARE%\inkscape\Inkscape-0.47-3.exe /S" >
      <exit code="2" />
  </upgrade>

  <remove cmd='"%PROGRAMFILES%\Inkscape\uninstall.exe" /S' />
</package>

Installer Switches[edit]

You can get a list of these by running the installer with /?.

  • /S: silent
  • /D=(directory): where to install inkscape
  • /GTK=(OFF/ON): GTK+ Runtime environment
  • /SHORTCUTS=(OFF/ON): shortcuts to start inkscape
  • /ALLUSER=(OFF/ON): for all users on the computer
  • /DESKTOP=(OFF/ON): Desktop icon
  • /QUICKLAUNCH=(OFF/ON): quick launch icon
  • /SVGEDITOR=(OFF/ON): default SVG editor
  • /CONTEXTMENUE=(OFF/ON): context menue integration
  • /PREFERENCES=(OFF/ON): delete users preference files
  • /ADDFILES=(OFF/ON): additional files
  • /EXAMPLES=(OFF/ON): examples
  • /TUTORIALS=(OFF/ON): tutorials
  • /LANGUAGES=(OFF/ON): translated menues, examples, etc.
  • /[locale code]=(OFF/ON): e.g am, es, es_MX as in Inkscape supported