New in version 3.0.
See also
Please make sure to read Library Dependency Finder (LDF) guide first.
lib_deps
¶See also
Please make sure to read Library Dependency Finder (LDF) guide first.
Specify project dependencies that should be installed automatically to libdeps_dir before environment processing. Multiple dependencies are allowed (multi-lines or separated with comma+space “, “).
If you have multiple build environments that depend on the same libraries, you can use Dynamic variables to use common configuration.
Valid forms
; one line definition (comma + space)
[env:myenv]
lib_deps = LIBRARY_1, LIBRARY_2, LIBRARY_N
; multi-line definition
[env:myenv2]
lib_deps =
LIBRARY_1
LIBRARY_2
LIBRARY_N
The each line with LIBRARY_1... LIBRARY_N
will be passed automatically to
platformio lib install command. Please follow to platformio lib install for
detailed documentation about possible values.
Example:
[env:myenv]
lib_deps =
13
PubSubClient
ArduinoJson@~5.6,!=5.4
https://github.com/gioblu/PJON.git#v2.0
me-no-dev/ESPAsyncTCP
IRremoteESP8266=https://github.com/markszabo/IRremoteESP8266/archive/master.zip
lib_ignore
¶See also
Please make sure to read Library Dependency Finder (LDF) guide first.
Specify libraries which should be ignored by Library Dependency Finder.
The correct value for this option is library name (not
folder name). In the most cases, library name is pre-defined in manifest file
(library.json, library.properties
, module.json
). The multiple
library names are allowed, split them with comma+space “, “.
There is ability to ignore built-in mbed libraries: mbed-rtos, mbed-events, mbed-fs, mbed-net, mbed-rpc, mbed-dsp, mbed-USBHost, mbed-USBDevice. See full list here.
Example:
[env:myenv]
lib_ignore = SPI, Ethernet, mbed-fs
lib_extra_dirs
¶See also
Please make sure to read Library Dependency Finder (LDF) guide first.
A list with extra directories/storages where Library Dependency Finder (LDF) will look for dependencies. Multiple paths are allowed. Please separate them using comma+space “, “.
This option can be set by global environment variable
PLATFORMIO_LIB_EXTRA_DIRS
or using global [platformio]
section
and lib_extra_dirs option.
Warning
This is a not direct path to a library with source code. It should be a path
to storage that contains libraries grouped by folders. For example,
D:\PlatformIO\extra\libraries
but not D:\PlatformIO\extra\libraries\FooLibrary
.
Example:
[env:myenv]
lib_extra_dirs = /common/libraries, /iot/libraries
lib_ldf_mode
¶New in version 3.0.
See also
Please make sure to read Library Dependency Finder (LDF) guide first.
This option specifies how does Library Dependency Finder should analyze
dependencies (#include
directives). See Dependency Finder Mode for details.
Example:
[env:myenv]
lib_ldf_mode = chain
lib_compat_mode
¶See also
Please make sure to read Library Dependency Finder (LDF) guide first.
Library compatibility mode allows to control strictness of Library Dependency Finder. More details Compatibility Mode.
By default, this value is set to lib_compat_mode = 1
and means that LDF
will check only for framework compatibility.
Example:
[env:myenv]
lib_compat_mode = 1
lib_archive
¶New in version 3.4.1.
Create an archive (*.a
, static library) from the object files and link it
into a firmware (program). This is default behavior of PlatformIO Build System
(lib_archive = true
).
Setting lib_archive = false
will instruct PIO Build System to link object
files directly (in-line). This could be useful if you need to override weak
symbols defined in framework or other libraries.
You can disable library archiving per a custom library using libArchive field in library.json manifest.
Example:
[env:myenv]
lib_archive = false