examples

Toy examples in single C files.
git clone git://henryandlizzy.uk/examples
Log | Files | Refs

commit a792edfe4c25b783dd7d55c1cc547ee62b4c265f
parent b4c5eed237ea98f08093090a8fb1d7e8a4f3db0e
Author: Henry Wilson <henry@henryandlizzy.uk>
Date:   Mon,  6 Feb 2023 21:54:29 +0000

makefile: Enable address & UB sanitizer

Diffstat:
MTupfile | 7++++---
Mmakefile | 7++++---
2 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/Tupfile b/Tupfile @@ -1,6 +1,7 @@ -WFLAGS = -Wall -Wextra -Werror -CFLAGS = $(WFLAGS) -fdiagnostics-color=always -CXXFLAGS = -std=c++20 $(WFLAGS) -fdiagnostics-color=always +WARNINGS = -Wall -Wextra -Werror +COMMON_FLAGS = $(WARNINGS) -fdiagnostics-color=always -fsanitize=undefined,address +CFLAGS = $(COMMON_FLAGS) +CXXFLAGS = -std=c++20 $(COMMON_FLAGS) LDLIBS_aio = -lrt LDLIBS_gl-asteroids = -lglfw -lGL -lm -lasound diff --git a/makefile b/makefile @@ -1,6 +1,7 @@ -WFLAGS := -Wall -Wextra -Werror -CFLAGS := $(WFLAGS) -CXXFLAGS := -std=c++20 $(WFLAGS) +WARNINGS := -Wall -Wextra -Werror +COMMON_FLAGS := $(WARNINGS) -fdiagnostics-color=always -fsanitize=undefined,address +CFLAGS := $(COMMON_FLAGS) +CXXFLAGS := -std=c++20 $(COMMON_FLAGS) c_sources := $(wildcard src/*.c) cpp_sources := $(wildcard src/*.cpp)