A S-PLUS package utility used to create a shared library from
C, C++, or FORTRAN source files.
The source files are compiled and resulting object files are
linked to make a shared library.
A shared library is also known as a shared object, dynamic
library, or dynamic shared object.
USAGE:
Splus CMD SHLIB -o libName [files]
REQUIRED ARGUMENTS:
-o libName
The name of the library to make, not including the extension.
The extension will be .dll on Windows and .so on most UNIX and Linux systems
(.sl on HP-UX).
When building S-PLUS packages, the library name should be "S".
OPTIONAL ARGUMENTS:
files
names of source files to be compiled and included in
the shared library. If no files are included on the command line,
then all files in the current working directory having these
extensions: .c, .C, .f, .F, will be compiled.
-h, --help
print usage message.
--clean-first
remove all object files and the old shared library before compiling
and creating the new library.
--clean-after
remove object files and, if any, other intermediate build
files made during build that are not needed
to use the shared library.
By default, no files are removed after the library is built.
--no-clean-after
do not remove object files, or other build files, after making
the shared library.
By default, no files are removed after the library is built.
-v, --verbose
give more detailed progress reports.
SIDE EFFECTS:
Source files are compiled creating object files in the same directory
as the source files. The object files are linked to create a
shared library file having the name and in the directory specified by
the -o option. If no directory is specified by the -o option then the
library file is put in the current working directory. If the
--clean-after
option is specified,
then all object files and other
unneeded build files are deleted after the library is built.
DETAILS:
On UNIX, the extension of the shared
library file is .so, and on Windows, the extension is .dll.
SEE ALSO:
Read Guide to S-PLUS Packages for more information.
Other package utilities:
,
(and DATAINSTALL),
.
EXAMPLES:
# compile all the package's source code to make a new shared library
# (current working directory is the package's "src" directory)
Splus CMD SHLIB --clean-first -o ../S
# compile specific source files to make a new shared library
# (current working directory is the package directory)
Splus CMD SHLIB -o S src/funcC.c src/funcF.f