1    Overview

This chapter describes the various phases in an application development project and the Tru64 UNIX tools that you can use during each of the phases.

This chapter addresses the following topics:

1.1    Application Development Phases

There are five major phases in application development. Table 1-1 describes these phases and the tools and features available for use in each phase.

Table 1-1:  Programming Phases and Tru64 UNIX

Phase Tools/Features
Requirements and specifications StandardsInternationalizationSecurity
Design RoutinesCoding considerationsLibrariesCommon files
Implementation vi, ex, ed, lint, grep, cxref, sed, time, dbx, third, ld, make, compilers, threads
Testing diff, shell scripts, pixie, prof
Maintaining setld, tar, sccs, rcs

In many instances, the Tru64 UNIX system offers more than one tool to do a job. The choices of tools and programming languages to use are left to you.

1.2    Specification and Design Considerations

When you design an application, some of your decisions depend on the nature of the application. Tru64 UNIX provides features and tools to help you create applications that can be portable, internationalized, window-oriented, or whatever is appropriate for the needs of the users of those applications.

One of the primary design considerations concerns adhering to UNIX environment standards and portability. If you want your application to run both on Tru64 UNIX systems and on other UNIX operating systems, consider limiting your design to features that adhere to X/Open portability guidelines and POSIX standards.

You might also need to design your application so that it can be used in a variety of countries. The Tru64 UNIX operating system contains internationalization tools and functions to help you write software to be used by people working in different natural languages.

Another consideration is the terminal environment in which your application will be used. If end users have workstations or window terminals, you might want to design your application to use window displays.

1.2.1    Standards

Adhering to programming standards enhances the ability to port programs and applications between hardware platforms or even operating systems. Writing programs according to portability standards makes it easy for users to move between systems without major retraining. As part of program portability, some standards include internationalization concepts.

The following are the primary standards in the UNIX programming environment:

In addition to the standards in the preceding list, the OSF Application Environment Specification (AES) specifies application-level interfaces that an application must provide to support portable applications and the semantics or protocols associated with these interfaces.

Various ANSI standards apply to specific programming tools such as languages, networks and communication protocols, character coding, and database systems. Information on conformance and extensions to a particular ANSI standard appears in the documentation set for the particular language, network system, or database system. For information about compiling C programs to adhere to ANSI standards, see Chapter 2.

The Tru64 UNIX system allows you to write programs that conform to POSIX and X/Open standards. Information on the POSIX standard is contained in POSIX -- Part 1: System Application Program Interface (API) [C Language] for IEEE Std. 1003.1c-1994. The Tru64 UNIX header files contain POSIX and X/Open conformant information.

1.2.2    Internationalization

An internationalized application provides a run-time interface that allows users to work in their own language with culturally appropriate representations of data. The Tru64 UNIX operating system provides interfaces and utilities for you to develop internationalized applications that conform to Issue 4 of the X/Open CAE specifications. It also supports the Multibyte Support Extension (MSE) of ISO C that is part of Issue 5 of the X/Open CAE specifications.

Considerations for developing internationalized applications include:

To meet these considerations, your applications must not make any assumptions about language, local customs, or coded character sets. Data specific to a culture is held separate from the application's logic. You use run-time facilities to bind your application to the appropriate language message text.

For details about the Tru64 UNIX internationalization package, see Writing Software for the International Market.

1.2.3    Window-Oriented Applications

For information on developing window-oriented applications, see the following manuals:

OSF/Motif Programmer's Guide

Common Desktop Environment: Programmer's Guide

Common Desktop Environment: Programmer's Overview

Common Desktop Environment: Application Builder User's Guide

Common Desktop Environment: Internationalization Programmer's Guide

Common Desktop Environment: Style Guide and Certification Checklist

Common Desktop Environment: Help System Author's and Programmer's Guide

1.2.4    Secure Applications

Tru64 UNIX provides a Security Integration Architecture (SIA) that allows the layering of local and distributed security authentication mechanisms onto the operating system. The SIA configuration framework isolates security-sensitive commands from the specific security mechanisms. See the Security Integration Architecture chapter of the Security manual and the sia*(3) reference pages for more information.

The Programmer's Guide to Security portion of the Security manual also provides detailed information on all aspects of creating trusted programs.

1.3    Major Software Development Tools

The Tru64 UNIX system is compatible with a number of higher-level languages, and it includes tools for linking and debugging programs.

1.3.1    Languages Supported by the Tru64 UNIX Environment

The Tru64 UNIX operating system includes an assembler (for assembly language programs) and a Java development kit (JDK). Compilers for other languages -- such as C, C++, Fortran, Ada, and Pascal -- are separately orderable.

For a complete list of optional products, contact your Compaq representative.

For more information on Java, see the Java documentation in the following directory on the system where the JDK in installed:

/usr/share/doclib/java/index.html

For more information on the assembler, see as(1) and the Assembly Language Programmer's Guide.

You can order documentation for the other languages when you order the compilers for those languages.

1.3.2    Linking Object Files

In most instances, you can use the C compiler driver command (cc) to link separate object files into a single executable object file.

As part of the compilation process, most compiler drivers call the linker (ld) to combine one or more object files into a single executable object file. In addition, the linker resolves external references, searches libraries, and performs all other processing required to create an executable object file.

The development environment allows you to create applications composed of source code files written in different languages. In these instances, you compile each of the files separately and then link the compiled object files together in a separate step. You invoke the linker separately from the compiler by entering the ld command.

You can create shared libraries by using compiler driver commands or the ld command. In addition, you can create archive (static) libraries by using the ar command. For more information on how to create libraries, see Chapter 4. For detailed information on compiling and linking programs, see Chapter 2 and Chapter 4, as well as the documentation sets for the individual languages.

1.3.3    Debugging and Program Analysis Tools

The following tools are the primary debugging and program analysis tools on the Tru64 UNIX operating system:

The ladebug debugger is also supported on the Tru64 UNIX operating system. In addition to providing the features provided by the dbx debugger, it supports features for debugging multithreaded programs. For information on the ladebug debugger, which supports C, C++, and Fortran, see the Ladebug Debugger Manual and ladebug(1).

1.4    Source File Control

An integral part of creating a software application is managing the development and maintenance processes. The Tru64 UNIX operating system provides the Source Code Control System (SCCS) utility and the RCS code management system to help you store application modules in a directory, track changes made to those module files, and monitor user access to the files.

SCCS and RCS on the Tru64 UNIX operating system provide support similar to SCCS and RCS utilities on other UNIX systems. In addition, Tru64 UNIX has an sccs preprocessor, which provides an interface to the more traditional SCCS commands.

SCCS and RCS maintain a record of changes made to files stored using the utility. The record can include information on why the changes were made, who made them, and when they were made. You can use either SCCS or RCS to recover previous versions of files as well as to maintain different versions simultaneously. SCCS is useful for application project management because it does not allow two people to modify the same file simultaneously.

For more information , see sccs(1), rcs(1), and the Programming Support Tools manual.

1.5    Program Installation Tools

After you create your program or application, you might want to package it as a kit for the setld installation utility so that it can be easily distributed to other users. The Tru64 UNIX operating system has several utilities that you can use to install, remove, combine, validate, and configure programs and applications.

Software for Tru64 UNIX systems consists of a hierarchical group of files and directories. If your application or program consists of more than one file or directory, you need to determine how the files and directories are grouped within the hierarchy. The setld installation process preserves the integrity of each product's hierarchy when it is transferred from the development system to a production system (that is, when the product is installed). The kitting process includes grouping the component files for the product into subsets, allowing the system administrator to install some or all of them as needed.

Using the setld utility and its related tools provides the following benefits:

Using setld, you can load your application on any of the following distribution media for installation on other systems:

For more information on using the setld command and creating and managing software product kits, see the Programming Support Tools manual.

1.6    Overview of Interprocess Communication Facilities

Interprocess communication (IPC) is the exchange of information between two or more processes. In single-process programming, modules within a single process communicate with each other using global variables and function calls, with data passing between the functions and the callers. When programming using separate processes having images in separate address spaces, you need to use additional communication mechanisms.

Tru64 UNIX provides the following facilities for interprocess communication: