Fix for x86_64 build fail
[platform/upstream/connectedhomeip.git] / examples / persistent-storage / linux / README.md
1 # CHIP Linux Persistent Storage Example
2
3 An example testing and demonstrating the key value storage API.
4
5 <hr>
6
7 -   [CHIP Linux Persistent Storage Example](#chip-linux-persistent-storage-example)
8     -   [Introduction](#introduction)
9     -   [Linux](#linux)
10         -   [Building](#building)
11         -   [Running](#running)
12
13 <hr>
14
15 <a name="intro"></a>
16
17 ## Introduction
18
19 This example serves to both test the key value storage implementation and API as
20 it is brought-up on different platforms, as well as provide an example for how
21 to use the API.
22
23 In the future this example can be moved into a unit test when available on all
24 platforms.
25
26 <a name="Linux"></a>
27
28 ## Linux
29
30 The Linux platform KVS is fully implemented, the KVS is enabled and configured
31 by providing a file during the init call.
32
33 <a name="building"></a>
34
35 ### Building
36
37 -   Install tool chain
38
39           $ sudo apt-get install git gcc g++ python pkg-config libssl-dev libdbus-1-dev libglib2.0-dev ninja-build python3-venv python3-dev unzip
40
41 -   Build the example application:
42
43           $ cd ~/connectedhomeip/examples/persistent-storage/linux
44           $ git submodule update --init
45           $ source third_party/connectedhomeip/scripts/activate.sh
46           $ gn gen out/debug
47           $ ninja -C out/debug
48
49 <a name="running"></a>
50
51 ### Running
52
53 -   Run Linux Example
54
55             $ cd ~/connectedhomeip/examples/persistent-storage/linux
56             $ sudo out/debug/persistent_storage