Setting Dynamic Library Path Parameters in Makefile

Setting Dynamic Library Path Parameters in Makefile

Table of Contents 1. Makefile Dynamic Library Related 1.1 Libs Variable 1.2 LDFLAGS Variable 1.3 Differences Between the Two 2. Configuration Methods 2.1 Specifying Library Path During Compilation 2.2 Specifying Library Path During Runtime 3. Testing 1. Makefile Dynamic Library Related 1.1 Libs Variable In a Makefile, Libs is typically a variable used to store … Read more

Refactoring a Go Project Makefile

Refactoring a Go Project Makefile

If you are not familiar with Makefile, I recommend reading Ruanyifeng’s article “Make Command Tutorial[1]“. This article will guide you to write a more elegant Makefile through a refactoring example, so let’s get started! Assuming there is a project named foo, developed in Golang and deployed on Docker, its Makefile is as follows: APP = … Read more

STM32 Bare Metal Programming 04 – Makefile Automation

STM32 Bare Metal Programming 04 - Makefile Automation

Makefile: Build Automation We can use the make command line tool instead of manually typing in “compile”, “link”, and “flash” commands, automating the entire process. The make tool uses a configuration file called Makefile to read the instructions for executing actions. This automation is great because it also documents the process of building firmware and … Read more

In-Depth Analysis of CMake Build Process: From Fundamentals to Complex Projects

In-Depth Analysis of CMake Build Process: From Fundamentals to Complex Projects

1. Analysis of the Project Structure After CMake Build 1.1 Directory Structure After CMake Build After CMake build is complete, a directory named build will be generated in the root directory of the project. This directory is where all intermediate files and final target files generated during the CMake build process are stored. Below, we … Read more

A Concise Guide to Makefile in Chip Design

A Concise Guide to Makefile in Chip Design

What can Makefile do? Makefile can execute commands based on specified dependency rules and whether files have been modified. It is commonly used to compile software source code, only recompiling modified files, which significantly speeds up the compilation process. The Basic Format of Makefile Target: Dependencies Command The target is the result to be generated, … Read more

From 0 to 1: Easily Master Makefile

From 0 to 1: Easily Master Makefile

Click on the above “IT Circle“, select “Top Public Account” Critical moments, delivered first! This article is published by reader Liang Xu from the public account, please do not reprint without authorization! 1. What is Makefile A typical enterprise-level project usually has many source files, sometimes categorized by function, type, or module in different directories, … Read more

Writing Makefiles for Python Projects

Writing Makefiles for Python Projects

As a fan of Makefiles, I use them in almost every hobby project. I also advocate for their use in work projects. For open source projects, Makefiles inform code contributors on how to build, test, and deploy the project. Moreover, if you use Makefiles correctly, they can greatly simplify your CI/CD process scripts, as you … Read more

Key Points for Writing Makefiles in Windows Environment

Key Points for Writing Makefiles in Windows Environment

(Star this for CPP developers to enhance C/C++ skills) Author: Zhu Jincan (This article is submitted by the author) 1. Basic Patterns of Makefiles in Windows Environment From my observation, there is a basic pattern for makefiles in the Windows environment, which is as follows: 1. Set compiler flags 2. If the compiler flags are … Read more