From 346b8f6105519a223e7f67029eeac59a5e420f5c Mon Sep 17 00:00:00 2001 From: Aleksey Veresov Date: Fri, 28 Aug 2020 07:20:36 +0300 Subject: More descriptions added. --- Makefile | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 0cb1cbc..208f55e 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,14 @@ -dns_example: dns_example.c dns.c dns.h - gcc dns_example.c dns.c -I. -o $@ +DEBUG ?= yes + +CFLAGS = -xc -ansi -Wall +ifeq '$(DEBUG)' 'yes' +CFLAGS += -g -O0 +else +CFLAGS += -O3 +endif + +dns_example: dns_example.c dns.c + gcc $(CFLAGS) $^ -I. -o $@ .PHONY: clean clean: -- cgit v1.2.3