Name Date Size #Lines LOC

..--

abi/x86_64/H16-Oct-2023-13,75913,758

docs/H13-Jun-2025-679457

evolutions/H16-Jun-2025-9064

include/H08-Nov-2023-12,1714,832

instance-db/H08-Jun-2023-

scripts/H10-May-2025-205110

src/H14-Jun-2025-20,27616,287

subprojects/H08-Jun-2023-43

tests/H14-Jun-2025-26,00020,938

tools/H14-Jun-2025-249213

.clang-formatH A D23-Oct-20233.6 KiB119116

.clang-tidyH A D02-Jun-20258.1 KiB226222

CHANGELOG.mdH A D27-Jun-202530.7 KiB872620

CONTRIBUTING.mdH A D26-Jun-202517.1 KiB494333

Doxyfile.inH A D25-Mar-202512.2 KiB361359

LICENSEH A D08-Jun-202311.1 KiB202169

OWNERSH A D13-Mar-20241.9 KiB5752

README.mdH A D17-Jun-20251.7 KiB7451

meson.buildH A D16-Jun-20253 KiB116100

meson.optionsH A D03-Feb-2025606 2625

README.md

1# libpldm
2
3This is a library which deals with the encoding and decoding of PLDM messages.
4It should be possible to use this library by projects other than OpenBMC, and
5hence certain constraints apply to it:
6
7- keeping it light weight
8- implementation in C
9- minimal dynamic memory allocations
10- endian-safe
11- no OpenBMC specific dependencies
12
13Source files are named according to the PLDM Type, for eg base.[h/c], fru.[h/c],
14etc.
15
16Given a PLDM command "foo", the library will provide the following API: For the
17Requester function:
18
19```c
20encode_foo_req() - encode a foo request
21decode_foo_resp() - decode a response to foo
22```
23
24For the Responder function:
25
26```c
27decode_foo_req() - decode a foo request
28encode_foo_resp() - encode a response to foo
29```
30
31The library also provides API to pack and unpack PLDM headers.
32
33## To Build
34
35`libpldm` is configured and built using `meson`. Python's `pip` or
36[`pipx`][pipx] can be used to install a recent version on your machine:
37
38[pipx]: https://pipx.pypa.io/latest/
39
40```sh
41pipx install meson
42```
43
44Once `meson` is installed:
45
46```sh
47meson setup build && meson compile -C build
48```
49
50## To run unit tests
51
52```sh
53meson test -C build
54```
55
56## Working with `libpldm`
57
58Components of the library ABI[^1] (loosely, functions) are separated into three
59categories:
60
61[^1]: ["library API + compiler ABI = library ABI"][libstdc++-library-abi]
62
63[libstdc++-library-abi]:
64  https://gcc.gnu.org/onlinedocs/libstdc++/manual/abi.html
65
661. Stable
672. Testing
683. Deprecated
69
70Applications depending on `libpldm` should aim to only use functions from the
71stable category. However, this may not always be possible. What to do when
72required functions fall into the deprecated or testing categories is discussed
73in [CONTRIBUTING](CONTRIBUTING.md#Library-background).
74