diff options
-rw-r--r-- | manifest-reference.md | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/manifest-reference.md b/manifest-reference.md index 5f0227a..f97136a 100644 --- a/manifest-reference.md +++ b/manifest-reference.md @@ -29,6 +29,8 @@ Every manifest file consists of the following sections: Toggle automatic discovery of test executables - [*auto-executables*](#automatic-target-discovery): Toggle automatic discovery of executables + - [*link*](#link-external-libraries): + Link with external dependencies - Target sections: - [*library*](#library-configuration) Configuration of the library target @@ -282,6 +284,32 @@ helloff = { git = "https://gitlab.com/everythingfunctional/helloff.git" } ``` +## Link external libraries + +> Supported in Fortran fpm only + +To declare link time dependencies on external libraries a list of native libraries can be specified in the *link* entry. +Specify either one library as string or a list of strings in case several libraries should be linked. +When possible the project should only link one native library. +The list of library dependencies is exported to dependent packages. + +*Example:* + +To link against the zlib compression library use + +```toml +link = "z" +``` + +To dependent on LAPACK also BLAS should be linked. +In this case the order of the libraries matters: + +```toml +[build] +link = ["blas", "lapack"] +``` + + ## Automatic target discovery > Supported in Fortran fpm only |