Build Overview

[English]

Basic Concepts

  • Project - Specifically refers to a directory or subdirectory under armino/projects/ that contains all the files and configurations needed to build an executable application, as well as other supporting files such as partition tables, data/filesystem partitions, and bootloader.

  • Project Configuration - Specifically refers to the sdkconfig.h file generated in the build directory during the build process.

  • Application - An executable file built by ARMINO. A project typically builds two applications: the project application (the main executable file, i.e., user-defined firmware) and the bootloader (which starts and initializes the project application).

  • Component - Modular and independent code that is compiled into a static library (.a file) and linked into the application.

  • Target - Specifically refers to the hardware device that runs the built application, such as bk7239, bk7258, etc.

Project Example

- armino/
    - components/
    - include/
    - middleware/
        - arch/
            - bk7239/
                - bk7239.defconfig
                - ...
    - projects/
        - my_project/
            - config/
                - bk7239/config
                - bk7258/config
            - CMakeLists.txt
            - Kconfig.projbuild
            - main/
                - main.c
                - Kconfig
                - CMakeLists.txt
            - components/
                - c1/
                    - c1.c
                    - Kconfig
                    - CMakeLists.txt
                - c2/

Using make to Trigger Build

Run make in the armino root directory. The most commonly used make commands are as follows:

  • make bkxxx - Build target bkxxx with the default project armino/projects/app.

  • make bkxxx PROJECT=a/b - Build bkxxx with project armino/projects/a/b

  • make all - Build all targets

  • make cleanbkxxx - Clean target bkxxx

  • make clean - Clean all targets

The make build indirectly calls the armino tool through armino/Makefile to perform the build, which eliminates the hassle of setting environment variables when using the armino tool directly. This method is recommended.

You can also execute make commands in the project directory without specifying the project:

  • make bkxxx - Build target with current project

  • make clean - Clean build artifacts