Using xmake and Zig for More Elegant Embedded System Development

Using xmake and Zig for More Elegant Embedded System Development

Introduction In the field of embedded system development, the stability and maintainability of build tools are crucial for the long-term development of projects. Embedded projects often require cross-compilation for different hardware platforms, each relying on specific build toolchains, making the environment setup complex. With the popularity of the LLVM toolchain, adopting modern build toolchains in … Read more

Essential Knowledge for Cross-Compilation: Choosing the Wrong -mfloat-abi Can Slow Floating Point Operations by 100 Times (Including Practical Example with Cortex-M4)

Essential Knowledge for Cross-Compilation: Choosing the Wrong -mfloat-abi Can Slow Floating Point Operations by 100 Times (Including Practical Example with Cortex-M4)

Hello everyone, I am a programmer who loves to share. I am happy to share my experiences and understanding from my work. -begin- In embedded development, the handling of floating point operations directly affects the performance and compatibility of programs, and -mfloat-abi is the key option that controls the floating point operation strategy. It determines … Read more

Cross-Compiling FFmpeg for Rockchip

Cross-Compiling FFmpeg for Rockchip

FFmpeg Rockchip encapsulates the hardware-accelerated video codec library MPP from Rockchip, allowing for easier use of Rockchip’s hardware-accelerated video encoding and decoding capabilities through FFmpeg’s command line and API. FFmpeg Rockchip depends on Rockchip’s MPP and librga libraries, so we first need to cross-compile the MPP and librga libraries. Compilation Environment The compilation system is … Read more

Advanced Cross-Compilation: The -mcpu Option Boosts Program Performance with ARM Cortex Practical Cases

Hello everyone, I am a programmer who loves to share. I am happy to share my experiences and insights from my work. -begin- Day 1: The -mcpu Option of Cross Toolchains – “Tailoring” the Instruction Set for Target CPUs In embedded development, advanced options of cross toolchains (such as arm-linux-gnueabihf-gcc) can make the compiled programs … Read more

Detailed Guide to Running Qt Applications on Embedded Linux: Platform Plugin Mechanisms from Qt4 to Qt5/6

Introduction Deploying Qt applications in embedded Linux systems is a common requirement in scenarios such as industrial control, smart terminals, and in-vehicle systems. However, unlike desktop environments, embedded devices often lack a complete graphics stack (such as X11 or Wayland) and may not even have a window manager. Therefore, Qt provides various platform plugins to … Read more

Cross-Compiling Specific Kernel Drivers with PetaLinux

We need to compile the u-dma-buf driver. This repository contains a Makefile.The Makefile has the following parameters: Parameter Name Description Default Value ARCH Architecture Name <span>$(shell uname -m | sed -e s/arm.*/arm/ -e s/aarch64.*/arm64/)</span> KERNEL_SRC Kernel Source Directory <span>/lib/modules/$(shell uname -r)/build</span> Cross Compile If you have a cross-compilation environment for the target system, you can … Read more

Cross-Compilation in Embedded Development

Cross-Compilation in Embedded Development

“In embedded development, target devices often cannot compile locally due to limited resources. Cross-compilation becomes a key technology—using a powerful host platform and a dedicated toolchain to generate executable code for the target platform. This article elaborates on its concepts and general processes, detailing cross-compilation implementation with examples from the three major architectures: ARM, MIPS, … Read more

Linux Kernel Compilation and Packaging

Linux Kernel Compilation and Packaging

1. Desktop Kernel Compilation a. Environment Preparation # Update apt package sources sudo apt update # Install compilation software environment apt install git fakeroot build-essential ncurses-dev xz-utils libssl-dev bc flex libelf-dev bison dwarves u-boot-tools xxd libncurses5-dev openssl Explanation: fakeroot: A tool for simulating a fake root environment build-essential: Basic compilation tools and environment, including: C, … Read more

Practical Guide to Compiling and Using Valgrind and ASan Tools on Embedded Development Boards

Practical Guide to Compiling and Using Valgrind and ASan Tools on Embedded Development Boards

On Embedded Development Boards Practical Guide to Compiling and Using Valgrind and ASan Tools 01 Introduction In embedded development, memory issues (such as memory leaks, out-of-bounds access, double free, etc.) are major causes of program crashes or instability. Valgrind and AddressSanitizer (ASan) are two powerful memory detection tools, but their usage scenarios and deployment methods … Read more

Rust Series (1) – Installation

Rust Series (1) - Installation

Installation Environment The company’s virtualization solution is written in Rust, and here is a configuration for the Rust environment. Remember, do not use the version from the Ubuntu repository; instead, follow the documentation to use the latest version. Necessary Tools apt install curl rsync gdb-multiarch openocd cargo doxygen qemu-user-static \ build-essential libncurses5-dev libssl-dev libgtk2.0-dev libglib2.0-dev … Read more