LINUX_SDK COMPILATION
SDK (Software Development Kit) is a collection of development tools provided for a specific software framework, hardware platform, or operating system, designed to help developers create applications more efficiently.
Compilation Host Configuration
Install Ubuntu on a PC to perform SDK compilation.
- Hardware: PC must meet RAM ≥ 16 GB, CPU cores ≥ 4
- Software: Ubuntu 18.04, allocate ≥ 100GB disk space for virtual machines
Note
Testing in ubuntu 22.04/20.04 environments results in numerous compilation errors; not recommended.
Compilation in WSL environment has not been tested and verified; not recommended.
Configuration and installation:
sudo apt install git bc bison build-essential curl flex libsdl1.2-dev
sudo apt install g++-multilib gcc-multilib gnupg gperf libncurses5-dev
sudo apt install imagemagick lib32ncurses5-dev lib32readline-dev squashfs-tools
sudo apt install lib32z1-dev liblz4-tool xsltproc libssl-dev libwxgtk3.0-dev
sudo apt install libxml2 libxml2-utils schedtool lzop pngcrush rsync
sudo apt install yasm zip zlib1g-dev python device-tree-compiler
sudo apt install python-pip gawk openjdk-8-jdk u-boot-tools patchelf expect
sudo pip install pyelftools
Obtaining SDK Source Code
Download SDK. Tina 5.0 Linux SDK supports building two filesystems: buildroot and ubuntu.
├── 1-SDK
│ └── linux
│ ├── README.txt
│ ├── rootfs // Filesystem packages
│ │ ├── buildroot-dl-20250620.tar.gz
│ │ ├── ubuntu-rootfs-20250530.tar.gz
│ │ └── ubuntu-rootfs-20251025.tar.gz
│ └── sdk // SDK source packages
│ ├── t113-linux-20251024.md5
│ ├── t113-linux-20251024.tar.gz
│ └── UPDATE_LOG.txt
Note
1.The SDK cannot be compiled in a shared directory.
2.The compilation host cannot log in using the ROOT account.
1. Copy the SDK source code archive to the compilation host directory and verify file integrity using MD5.
2. Extract the source code archive.
3. Restore the source code files.
Obtaining Rootfs Image
-
Download the Rootfs image. Typically, download the file with the latest date suffix.
-
Buildroot Rootfs
The provided buildroot-dl-*.tar.gz archive can be used for offline compilation of the Buildroot filesystem, reducing the time spent downloading source code during compilation.
Extract buildroot-dl-*.tar.gz into the buildroot/buildroot-201902 directory.
- Ubuntu Rootfs
ubuntu-rootfs-*.tar.gz is the Ubuntu filesystem archive. Compiling it with the SDK source code can generate the Ubuntu system image.
Copy ubuntu-rootfs-*.tar.gz to the SDK's device/config/rootfs_tar directory and rename it to ubuntu-armhf.tar.gz.
Full Compilation
When executing build.sh for the first time to compile the SDK, you must select the compilation configuration and filesystem type.
- SDK Compilation Configuration
./build.sh lunch
======you are building t113 linux======
1. BoardConfig-t113-s3-kickpi-k4b-buildroot.mk
2. BoardConfig-t113-s3-kickpi-k4b-ubuntu.mk
3. BoardConfig-t113-s3-kickpi-k4b-nand-buildroot.mk
4. BoardConfig-t113-s3-kickpi-k4b-nand-ubuntu.mk
which board would you like (1-4): // Select based on board model and desired filesystem
- Compile Image
The generated system image is located at out/update-t113-s3-kickpi-k4b-xxxxxxx.img.
Individual Compilation
Compile U-Boot Individually
Compile Kernel Individually
Compile Buildroot Individually
Other Commands
Kernel Configuration
Tip
Configuration file path: device/config/chips/t113/configs/evb1_auto/linux-5.4/config-5.4
Buildroot Configuration
Tip
Configuration file path: buildroot/buildroot-201902/configs/sun8iw20p1_t113_defconfig
Compilation Toolchain
After compilation is complete, the toolchain is located at: