libutil

C Utility Library
git clone http://git.omkov.net/libutil
Log | Tree | Refs | README | LICENCE | Download

libutil/Makefile (14 lines, 408 B) -rw-r--r-- file download

beca186 Jakob Wakeling 2024-05-18 12:12:17
0
.PHONY: all build test help
beca186 Jakob Wakeling 2024-05-18 12:12:17
1
all: help
beca186 Jakob Wakeling 2024-05-18 12:12:17
2
beca186 Jakob Wakeling 2024-05-18 12:12:17
3
build: ## Build the project
beca186 Jakob Wakeling 2024-05-18 12:12:17
4
	@cmake -S . -B ./build -DCMAKE_BUILD_TYPE:STRING=Release -DCMAKE_EXPORT_COMPILE_COMMANDS=1
beca186 Jakob Wakeling 2024-05-18 12:12:17
5
	@cmake --build ./build
beca186 Jakob Wakeling 2024-05-18 12:12:17
6
beca186 Jakob Wakeling 2024-05-18 12:12:17
7
test: build ## Run unit tests
beca186 Jakob Wakeling 2024-05-18 12:12:17
8
	@(cd ./build && ctest)
beca186 Jakob Wakeling 2024-05-18 12:12:17
9
beca186 Jakob Wakeling 2024-05-18 12:12:17
10
help: ## Display help information
beca186 Jakob Wakeling 2024-05-18 12:12:17
11
	@grep -E '^[a-zA-Z_-]+:.*?##.*$$' $(MAKEFILE_LIST) | \
beca186 Jakob Wakeling 2024-05-18 12:12:17
12
		awk 'BEGIN {FS = ":.*?## *"}; {printf "\033[36m%-6s\033[0m %s\n", $$1, $$2}'
13