Getting Started : 3. Getting Started Using OpenROAD : Simple Client Applications : How You Can Make an Application Image
 
Share this page                  
How You Can Make an Application Image
After you have developed and debugged your application, you can make an application image of it. An image is a compiled, executable file that lets you run an application. In this procedure you will make an application image of the ProjectApp1 application.
Creating an application image follows these basic steps:
1. Set the starting component for the application.
2. Make an application image using the MakeImage utility.
3. Run the Build Assistant to create a reusable build command.
4. Run the build command to create the application image.
Set the Starting Component
Before you make an image of an application, you should specify the starting component—the first component of an application that runs when you run the application image. In this procedure, you will set ProjectFrame as the starting component.
To set the starting component for ProjectApp1
1. Click the Develop tab and select ProjectApp1 in the Applications portlet.
2. Click the Application Properties portlet tab (at the bottom of the Application Properties portlet) and ensure that the portlet is active.
3. Click File, Open to edit the properties.
4. Click the control button to the right of the Starting Component field.
The Select Starting Component dialog appears.
5. Select the component projectframe and click OK.
Projectframe is entered into the Starting Component field.
6. Click File, Save and Close.
You are now ready to make an image of the ProjectApp1 application.
Make an Application Image Using the Image Tool
In this procedure, you will create an executable image of the ProjectApp1 application that you created in Create an Application.
To create an image of ProjectApp1
1. Click the Develop tab and select the ProjectApp1 application in Applications portlet.
2. Right-click on ProjectApp1 and select Image Application from the context menu.
The Make Image dialog opens.
3. Click the Browse button to the right of the Output File field.
A File Selection dialog appears, filling in name ProjectApp1.img.
4. Change the directory to fullpath\Ingres_instance\ingres\w4glapps.
5. Click Save.
The File Selection dialog closes.
6. Click Go.
The Make Image dialog closes and makes the ProjectApp1.img file.
7. Check the OpenROAD Trace Window to see if the image file was built successfully.
To run the image
1. Click Start, All Programs, Actian OpenROAD 6.2, Resources, Runimage.
The RunImage dialog appears.
2. In the File field, enter ProjectApp1.img.
3. Click OK.
The application image runs, opening ProjectFrame.
4. Close the application.
Now you can create a reusable build command to make an image of the ProjectApp1 application.
Use the Build Assistant to Create a Build Command
The MakeImage utility requires that you specify parameters every time you use the utility. You can specify and save these settings in a reusable build command file, which you create on the Build tab.
In this procedure, you will use the Build Assistant to create a build command that you can use to create the ProjectApp1.img file. For this procedure, the ProjectApp1 application must be selected in the Applications portlet of the Develop tab.
To create a build command
1. Select ProjectApp1 on the Develop tab.
2. Click the Build tab.
3. Click the New button on the toolbar.
The OpenROAD Build Assistant appears.
4. Click Next on the OpenROAD Build Assistant dialog.
5. Select build type: Build Command. Then click Next.
6. Select the OpenROAD utility to run: MakeImage. Then click Next.
7. Configure the build command for the current application.
8. Click OK to complete the wizard process.
MakeImage parameters are displayed in the Build tab portlet.
9. Set the Trace Window drop-down to Yes so that the application will log to the Trace window when the application is run.
Note:  This is a convenient way to see that the application has run.
10. Click File, Save and Close.
The build command is listed in the Build Commands/Scripts portlet.
You can now run the build command to create an image of the ProjectApp1 application.
Run the Build Command
In this procedure, you will use the build command you created in Use the Build Assistant to Create a Build Command to create an image of the ProjectApp1 application.
To run the build command
1. Click the Build tab.
2. Select the build command “Make image of "ProjectApp1"...” in the Build Commands/Scripts portlet.
3. Click Run, Run.
A Trace window opens briefly, showing the progress of the build.
4. Click the Log portlet tab to see the contents of the log for the w4glrun makeimage command.
Building the image again is a simple matter of selecting the build command and running it. In this way, you can quickly create a new image of the application after making modifications to it.