Kbase P42876: How does the Application Compiler save compiled .r code ?
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  6/16/2009 |
|
Status: Verified
GOAL:
How does the Application Compiler save compiled .r code ?
GOAL:
Where does the Applicaiton Compiler save r-code ?
FACT(s) (Environment):
All Supported Operating Systems
Products / Versions
FIX:
By default, the Application Compiler saves r-code files in the directory that contains the source files.
If the r-code needs to be saved into a different directory than the source, the situation is a little more complex as explained below.
This choice is available under:
Options --> Compiler... and then write a path into the Save Into:fill-in box.
The Application Compiler can either compile files relative to the PROPATH or it must compile them using full pathnames. If any part of the source file directory structure is in the PROPATH, the compiler will attempt to save the r-code into a directory structure composed in the following manner:
1) First it will take the directory specified in the Save Into box as a starting point.
2) Then it will take a look at the source directory. If part of the source directory structure is in the PROPATH, it will strip those directories from the structure. It will then append whatever directories remain on to the end of the structure specified in the Save Into box.
PROPATH relative pathnames were chosen because this allows the Application Compiler to generate XREF files with PROPATH relative file names. Full pathnames in the XREF output file would be useless to anyone attempting to use the XREF output file to construct where-used cross-reference databases, which is widely used.
For example:
Source to be compiled is in c:\Devel\Sub1\Source
Compiled code is specified to be saved into c:\Deploy\Compiled
Propath = .,c:\Devel,c:\dlc,c:\dlc\gui, etc.
The compiler will try to save the r-code into:
c:\Deploy\Compiled\Sub1\Source
Since this file structure does not exist, error message:
Unable to create r-code file "c:\Deploy\Compiled\Sub1Source\<filename.r>" (477)
A solution is to remove from the PROPATH the directories that are part of the source code path. In the above example, you would remove "c:\Devel" from the PROPATH.
Another workaround is to specify the full path and filename of every file that needs to be compiled in the Application Compiler's list of files to compile. You could not simply check off the Look in Subdirectories check-box and list the parent directory. In the above example, the full directory path of each file that needs compiling would need to be spelled out: c:\Devel\Sub1\Source\<filename.p>
In either case, the directory or directories including the include files (.i) for the source code to be compiled MUST be in the propath. If it is not, the Application Compiler will fail to find these include files and error 293 will be generated.