Chapter Contents |
Previous |
Next |
Cross-Debugging |
The
SAS/C Debugger
provides the capability of debugging programs in a cross-development environment.
To debug a load module that was compiled with the SAS/C
or C++ cross-platform compiler, you simply run the program with the
=debug
runtime option, just like any other SAS/C or
C++ load module.
When developing an application in a cross-development environment, the files used by the debugger, with the exception of the load module, may reside on the host workstation. In order for the debugger to access files that reside on the workstation, a distributed file system must be used to establish a client/server relationship between the target mainframe and the host workstation. The distributed file system used in the SAS/C cross-development environment is the Network File System (NFS) described in Installing and Administering the NFS Client and SAS Technical Report C-113 SAS/C Connectivity Support Library, Release 1.00. Using NFS, the debugger, running on the mainframe under OS/390 or CMS, has direct access to the source, include, and debugger files that reside on the host workstation.
If the debugger's default file searching mechanism
does not meet your needs, you can change or augment the search mechanism with
the debugger's
set search
command.
The
set search
command is
used to specify filename templates. Filename
templates are used to specify the identity and location of the source, include,
or debugger files associated with the load module being debugged. Multiple
filename templates can be defined for each type of file. As a result, the
debugger can search for a file by more than one name or in multiple locations.
Each template is saved in a search list, and each search list is associated
with a specific type of file.
Filename templates are
character strings which are similar to
the patterns used in a C
printf
statement. Each filename template
may contain conversion specifiers and characters. A conversion
specifier is a character or a string preceded by a percent character. The
conversion specifier is either replaced by its associated string or specifies
the format of the conversion specifier that follows it. The resulting string
is used as the name of the file to be opened. If a file with the resulting
name cannot be opened, the next filename template in the search list is processed
until either a file is opened or there are no more filename templates in the
search list for that type of file.
This is a very powerful technique that allows you to
direct the debugger to files that have moved or even changed names or file
systems. This chapter explains how to use the
set search
and
set cache
commands to define filename templates and establish search
lists.
Debugging in a Cross-Development Environment illustrates the relationship between the files used by the SAS/C Debugger in the cross-development environment.
Debugging in a Cross-Development Environment
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright © 2001 by SAS Institute Inc., Cary, NC, USA. All rights reserved.