You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The stdlib project exports CMake package files and pkg-config files to make stdlib usable for other projects.
221
223
The package files are located in the library directory in the installation prefix.
222
224
@@ -235,6 +237,18 @@ target_link_libraries(
235
237
To make the installed stdlib project discoverable add the stdlib directory to the ``CMAKE_PREFIX_PATH``.
236
238
The usual install location of the package files is ``$PREFIX/lib/cmake/fortran_stdlib``.
237
239
240
+
### Using stdlib with a regular Makefile
241
+
242
+
The library can be included in a regular Makefile, for example with
243
+
```make
244
+
STDLIB_PATH := path/to/build
245
+
LIBDIRS := $(STDLIB_PATH)/src
246
+
INCDIRS := $(STDLIB_PATH)/src/mod_files
247
+
...
248
+
```
249
+
Here it is assumed that the compiler will look for libraries in `LIBDIRS` and for module files in `INCDIRS`.
250
+
A flag `-lfortran_stdlib` should be included to link against `libfortran_stdlib.a` or `libfortran_stdlib.so`.
251
+
238
252
## Documentation
239
253
240
254
Documentation is a work in progress (see issue [#4](https://github.com/fortran-lang/stdlib/issues/4)) but already available at [stdlib.fortran-lang.org](https://stdlib.fortran-lang.org).
0 commit comments