Open System Services Porting Guide (G06.24+, H06.03+)
Table Of Contents
- What’s New in This Manual
- About This Manual
- 1 Introduction to Porting
- 2 The Development Environment
- 3 Useful Porting Tools
- 4 Interoperating Between User Environments
- Purpose of Interoperability
- The OSS User Environment
- OSS Commands for the Guardian User
- Guardian Commands for the UNIX User
- OSS Pathname and Guardian Filename Conversions
- Running the OSS Shell and Commands From TACL
- Running Guardian Commands From the OSS Shell
- Running OSS Processes With Guardian Attributes
- Using OSS Commands to Manage Guardian Objects
- 5 Interoperating Between Programming Environments
- 6 OSS Porting Considerations
- 7 Porting UNIX Applications to the OSS Environment
- 8 Migrating Guardian Applications to the OSS Environment
- General Migration Guidelines
- C Compiler Issues for Guardian Programs
- Using New and Extended Guardian Procedures
- Using OSS Functions in a Guardian Program
- Interoperating With OSS Programs
- Starting an OSS Program From the Guardian Environment
- C Compiler Considerations for OSS Programs
- Porting a Guardian Program to the OSS Environment
- How Arguments Are Passed to the C or C++ Program
- Differences in the Two Run-Time Environments
- Which Run-Time Routines Are Available
- Use of Common Run-Time Environment (CRE) Functions
- Replacing Guardian Procedure Calls With Equivalent OSS Functions
- Which IPC Mechanisms Can Be Used
- Interactions Between Guardian and OSS Functions
- 9 Porting From Specific UNIX Systems
- 10 Native Migration Overview
- 11 Porting or Migrating Sockets Applications
- 12 Porting Threaded Applications
- A Equivalent OSS and UNIX Commands for Guardian Users
- B Equivalent Guardian Commands for OSS and UNIX Users
- C Equivalent Inspect Debugging Commands for dbx Commands
- D Equivalent Native Inspect Debugging Commands for dbx Commands
- E Standard POSIX Threads Functions: Differences Between the Previous and Current Standards
- Glossary
- Index
Interoperating Between User Environments
Open System Services Porting Guide—520573-006
4-9
Guardian Environment Variables and the OSS Shell
specified filenames used by the process and other user-specified information in the
form of the ASSIGN and PARAM environment variables. This start-up sequence
usually occurs whenever one process creates another; the creating process sends the
information to the new process, but it is up to the new process to somehow use the
information.
A DEFINE is a named set of attributes and values that you use to pass information to a
process before running it. DEFINEs remove the need to set up attributes each time a
given process is invoked: the attributes can be passed or retrieved simply by specifying
the name of the DEFINE.
DEFINEs are automatically passed to the new Guardian process from its parent
process when the new process is created. You can use DEFINEs to pass attributes to
a process to provide one of the following:
•
An alternate name for accessing a file
•
A list of subvolumes to search for a filename
•
A simple means of passing attributes to the spooler subsystem
•
A simple means of setting up attributes for labeled tape processing
You can use DEFINEs interactively using TACL, or you can work with DEFINEs
programmatically. For detailed information on using DEFINEs interactively, refer to the
Guardian User’s Guide; for detailed information on using DEFINEs programmatically,
refer to the Guardian Programmer’s Guide.
If the defmode on parameter is set for the gtacl or OSH utility, all Guardian DEFINE
values of the process executing the utility are inherited by the child process. If the
defmode off parameter is set for the gtacl or OSH utility, only the Guardian
=_DEFAULTS DEFINE values inherited by OSH are inherited by the child process.
Refer to the gtacl(1) and osh(1) reference pages either online or in the Open
System Services Shell and Utilities Reference Manual for the details on the defmode
parameter settings.
For the OSH utility, all Guardian environment PARAMs are converted into OSS
environment variables for the child process, but no Guardian environment ASSIGN
values are passed to the child process. For more information on Guardian PARAMs
(HOME, LOGNAME, PATH, and PWD) in the OSS environment, see the discussion of
Guardian environment variables and the process environment in the osh(1) online
reference page.
The following table shows the mapping of the interactive Guardian DEFINEs to the
OSS shell define commands:
Guardian DEFINE
OSS Shell
Command DEFINE Command Purpose
ADD DEFINE add_define Creates new DEFINEs.
DELETE DEFINE del_define Deletes DEFINEs.
INFO DEFINE info_define Displays DEFINE attributes and values.