Home | Categories | Alphabetical | Classes | All Contents | [ < ] | [ > ]

Preparing a UNIX Distribution


The following sections describe the steps you must perform prior to distributing your application on UNIX systems. For information on distributing your application on Microsoft Windows systems, see Preparing a Windows Distribution.

The method for preparing an IDL distribution varies depending on the type of IDL application you are distributing:

Unlicensed Native IDL Applications

If your native IDL application is intended to be run in an existing fully-licensed IDL installation, you do not need to create an IDL distribution. Simply package up your application files (either .pro files or .sav files, and any necessary data files) and distribute it to your users along with instructions describing how to install and launch the application.

Virtual Machine Applications

If your IDL Virtual Machine application is intended to be run in an end-user's existing IDL installation, you do not need to create an IDL distribution. Simply distribute the .sav files that make up your application along with instructions on how to install and launch the application. SAVE files created to be run in the IDL Virtual Machine can be placed anywhere on the user's system, and launched as described in Running a .sav File in the IDL Virtual Machine.

Callable IDL Applications

The following steps are required before distributing a Callable IDL application.

Add Your Executables to the Distribution

Copy your application executable to the bin.platform directory, where platform is the name of the platform for which you created the application. If you are distributing your application on multiple platforms, copy the executable for each platform to the corresponding bin.platform directory. Placing your executables in the bin.platform directory offers a couple of advantages:

Rename the idl Script

Located in the bin directory of your distribution is a script called idl. For Callable IDL applications, this script must use the same name as your application executable in the bin.platform directory. For example, if your application executable in the bin.platform directory is called myapp, rename the idl script in the bin directory to myapp.

Edit the Startup Script

In the top-level directory of your application distribution, there is a startup script with the name specified by the savefile parameter you specified when you ran the make_rt script. Make the following changes to this script:

  1. For Callable IDL applications, you must edit this startup script to execute the script in the bin directory that you renamed in the previous section, Rename the idl Script. For example, if your application executable in the bin.platform directory is called myapp, and you therefore renamed the idl script in the bin directory to myapp, you would edit the startup script in the top-level directory as follows:
  2. ./bin/myapp 
    

Note
The above command requires the user to execute the startup script from the top-level directory of your application distribution. To allow the user to launch your application from a different directory, the user (or your installation script) could change the command to use the full path to the script in the bin directory. See the example after the following step.

  1. In order to allow your application to find the correct executable (either IDL or a Callable IDL executable), the IDL_DIR environment variable must be set on the user's machine to point to the top-level directory of your application. Because this location is not known until the user installs your application, IDL_DIR must be set by either an installation script or by the user.
  2. If there are other RSI products installed on the user's machine, IDL_DIR may already be set. For this reason, IDL_DIR should be set for the instance of the shell that will be used to start your application, but should not be set in the user's login scripts such as .cshrc or .profile. This allows IDL_DIR to be set properly for your application, without conflicting with the IDL_DIR setting for other products the user may have installed.

    The most convenient way to set IDL_DIR on the user's machine is to have your installation script (or the user) edit the startup script. This saves the user from having to manually set IDL_DIR prior to launching your application. You can either provide the user with instructions on adding the necessary commands to the startup script, or you can have your installation script modify the startup script. For example, if an application called myapp is installed in the /home/apps directory, your startup script would resemble the following:

    IDL_DIR=/home/apps 
    export IDL_DIR 
    /home/apps/bin/myapp 
    

    If you do not modify the startup script, the user must set IDL_DIR at the command prompt prior to launching your application. For example, if your application is installed in the user's /home/myapp directory, the user could execute the following command at the C shell prompt:

    setenv IDL_DIR /home/myapp 
    

Starting Your UNIX Application

For both IDL and Callable IDL applications, starting your application on UNIX requires the following steps:

  1. Set the IDL_DIR environment variable as described above.
  2. Execute the startup script in the top-level directory of your application.

Home | Categories | Alphabetical | Classes | All Contents | [ < ] | [ > ]