6641ad7a7ffa8f847cf78e7c4c29692d07ae96c3
[platform/core/ml/nnfw.git] / onert-micro / README.md
1 # luci-micro
2
3 `luci-micro` is MCU specialized build of luci-interpreter with several benchmark applications.
4
5 ## Contents
6
7 Luci-micro contains cmake infrastructure to build:
8 - stand-alone interpreter library
9 - benchmark applications using luci interpreter on arm MCUs
10
11 ## How to build stand alone library
12
13 Stand-alone library is simply built by `luci_interpreter_micro_arm` target.
14 Result library will be placed in  `<ONE root>/build/compiler/luci-micro/standalone_arm/luci-interpreter/src/libluci_interpreter.a`.
15
16 ### Prerequisites
17
18 - Everything you need for ONE project: see [how-to-build-compiler.md](../../docs/howto/how-to-build-compiler.md)
19 - arm-none-eabi-gcc and arm-none-eabi-g++ compilers
20
21 To install needed arm compilers on ubuntu:
22 ```
23 $ sudo apt-get install gcc-arm-none-eabi
24 ```
25
26 **cmake build**
27
28 ``` bash
29 $ cd <path to ONE>
30 $ mkdir build
31 # cd build
32 $ cmake ../infra/nncc
33 $ make -j$(nproc) luci_interpreter_micro_arm
34 ```
35
36 **nncc script build**
37
38 ``` bash
39 $ cd <path to ONE>
40 $ ./nncc configure
41 $ ./nncc build -j$(nproc) luci_interpreter_micro_arm
42 ```
43
44 ### Known issues
45
46 Interpreter uses TensorFlow headers that produces warnings.
47
48 `Linux` x86 build uses "-isystem" flag to suppress warnings from external sources,
49 but some old arm compilers have issues with it:
50 [bug](https://bugs.launchpad.net/gcc-arm-embedded/+bug/1698539)
51
52 `-isystem` hack is disabled for MCU build, because of this MCU build is broken if `-Werror` flag is set.
53
54 ## How to use
55
56 TBD