Contents

 

HP secure development lifecycle......................................................................

7

1 An overview of HP Fortran...........................................................................

8

The HP Fortran compiler environment...........................................................................................

8

Driver......................................................................................................................................

9

C preprocessor.......................................................................................................................

10

Front-end...............................................................................................................................

11

Back-end...............................................................................................................................

13

Linker....................................................................................................................................

15

Tools.....................................................................................................................................

17

HP-UX operating system...........................................................................................................

17

2 Compiling and linking..............................................................................

18

Compiling with the f90 command.............................................................................................

18

f90 command syntax..........................................................................................................

18

Command-line options............................................................................................................

19

Commonly-used options......................................................................................................

20

Command-line options by category......................................................................................

20

Option descriptions............................................................................................................

21

Symbol binding options...........................................................................................................

37

Using optimization options.......................................................................................................

38

Reviewing general optimization options.....................................................................................

38

Fine-tuning optimization options...............................................................................................

40

Filenames..............................................................................................................................

49

Linking HP Fortran programs....................................................................................................

50

Linking with f90 vs. ld.........................................................................................................

50

Linking to libraries..............................................................................................................

51

Linking to nondefault libraries.........................................................................................

52

Linking HP Fortran 90 routines........................................................................................

52

Additional HP Fortran libraries........................................................................................

53

Linking to shared libraries...............................................................................................

53

Library search rules.......................................................................................................

54

Special-purpose compilations...................................................................................................

54

Compiling programs with modules.......................................................................................

54

Examples.....................................................................................................................

56

Compiling with make.....................................................................................................

57

Managing .mod files.....................................................................................................

58

Compiling for different PA-RISC machines..............................................................................

58

Creating shared libraries....................................................................................................

59

Compiling with +pic......................................................................................................

59

Linking with -b..............................................................................................................

60

Examples.....................................................................................................................

60

Using the C preprocessor........................................................................................................

60

Processing cpp directives....................................................................................................

61

Saving the cpp output file...................................................................................................

62

Creating demand-loadable executables.....................................................................................

62

Creating shared executables....................................................................................................

62

Compiling in 64-bit mode........................................................................................................

63

Using environment variables.....................................................................................................

63

F90ROOT environment variable...........................................................................................

64

ST_F90COM[64] environment variable.................................................................................

64

HP_F90OPTS environment variable......................................................................................

64

Contents 3