For example: What should I do if I want to set in Unix a different default installation directory than the one used in Windows?

asked 06 Sep '11, 04:14

Jake's gravatar image

Jake ♦♦
181534175
accept rate: 98%


Let's say you want to use c:\myapp-4.0 for Windows and /usr/local/myapp-4.0 for Unix as the default installation directory. In InstallBuilder, go to "Customization" screen and then to the "Installer" tab. Specify /usr/local/${product_shortname}-${product_version} as Installation Directory and Save the project.xml file. Now edit your project.xml file with your favorite text editor and replace the line <preInstallationActionList/> with this code:

<preInstallationActionList>
  <setInstallerVariable>
    <name>installdir</name>
      <value>${env(SYSTEMDRIVE)}/${product_shortname}- ${product_version}</value>
      <ruleList>
        <platformTest>
          <type>windows</type>
        </platformTest>
      </ruleList>
  </setInstallerVariable>
</preInstallationActionList>

Remember that if you choose /usr/local as the destination for your application you have to require that the installation is performed as the root user. ${product_shortname} and ${product_version} are installer variables. You can find the complete list of the default installer variables available and their meaning in the product documentation included with InstallBuilder.

link

answered 06 Sep '11, 04:20

Jake's gravatar image

Jake ♦♦
181534175
accept rate: 98%

edited 15 Sep '11, 10:33

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×14
×10
×4

Asked: 06 Sep '11, 04:14

Seen: 250 times

Last updated: 15 Sep '11, 10:33

powered by BitNami OSQA