AcuMakeLib
Make a dynamic shared library from user codes, implementing user-defined functions. This program runs on Linux platforms only.
Syntax
acuMakeLib [options]
Type
AcuSolve User-Defined Functions Program
Description
AcuMakeLib is a utility program that builds a dynamic shared library from a set of user source codes containing user-defined functions. One or more libraries may then be loaded into AcuSolve. AcuMakeLib is for Linux platforms only.
AcuMakeLib relies on files stored in ACUSIM installed directories. As such, it requires the environment variables ACUSIM_HOME and ACUSIM_MACHINE. The .acusim file must be sourced for these variables to be defined.
acuMakeLib - command not found
then Perl may not be on your system.
In the following, the full name of each option is followed by its abbreviated name and its type. For a general description of option specifications, see Command Line Options and Configuration Files. See below for more individual option details:
- help or h (boolean)
- If set, the program prints a usage message and exits. The usage message includes all available options, their current values and the source of their current values.
- user_library or lib (string)
- The name of the resulting dynamic shared library.
- user_source_files or src (string)
- Comma-separated list of user source files. The comma-separated fields may contain shell file name generation characters. All files must have extension ".c" (for C codes) or ".f, .for, .f77, .f90, .f95" (for Fortran codes). If user_source_files is set to _auto, all files with extension ".c" and ".f, .for, .f77, .f90, .f95" in the current directory are assumed.
- optimization or opt (enumerated)
- Compiler optimization level:
- O
- Default system optimization
- O1
- Compiler optimization O1
- O2
- Compiler optimization O2
- O3
- Compiler optimization O3
- debug
- Compile with debug option
- c_compiler or cc (string)
- Specify C compiler command. If the default _auto option is selected, the script searches for Intel's icc compiler at first, then the gcc compiler later in the system. If you want to use a specific compiler, the compiler command can be specified by this option.
- f_compiler or fc (string)
- Specify Fortran compiler command. If the default _auto option is selected, the script searches for Intel's ifort compiler at first, then the gfortran compiler later in the system. If you want to use a specific compiler, the compiler command can be specified by this option.
- c_compiler_flags or cflags (string)
- These flags are added to the built-in C compiler flags. The default C compiler is gcc.
- fortran_compiler_flags or fflags (string)
- These flags are added to the built-in Fortran compiler flags. The default Fortran compiler is gfortran.
- linker_flags or lflags (string)
- These flags are added to the built-in linker flags.
- make_clean or clean (boolean)
- Clean the directory before compiling.
- verbose or v (integer)
- Set the verbose level for printing information to the screen. Each higher verbose level prints more information. If verbose is set to 0 (or less), only warning and error messages are printed. If verbose is set to 1, basic processing information is printed in addition to warning and error messages. This level is recommended. Verbose levels greater than 1 provide information useful only for debugging.
Examples
acuMakeLib -lib libusr.so -src "usr*.c,fusr*.f" -cc gcc -fc gfortran
user_library= libusr.so
user_source_files= usr*.c,fusr*.f
acuMakeLib
Note that on the command line usr*.c,fusr*.f was enclosed in a pair of double quotes so that the shell would not expand it. Instead, the expansion was done in AcuMakeLib. The Unix shell file name generation characters "*", "?", and "[]" are accepted and expanded by AcuMakeLib.