mirror of
https://github.com/thepigeongenerator/tetris_clone.git
synced 2025-12-17 05:55:46 +01:00
sync makefile with template to add more advanced debugging options
This commit is contained in:
5
.vscode/tasks.json
vendored
5
.vscode/tasks.json
vendored
@@ -1,5 +1,10 @@
|
|||||||
{
|
{
|
||||||
"version": "2.0.0",
|
"version": "2.0.0",
|
||||||
|
"options": {
|
||||||
|
"env": {
|
||||||
|
"DEBUG": "1"
|
||||||
|
}
|
||||||
|
},
|
||||||
"tasks": [
|
"tasks": [
|
||||||
{
|
{
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
|
|||||||
8
makefile
8
makefile
@@ -4,9 +4,15 @@ NAME = sdl_template
|
|||||||
CC := clang
|
CC := clang
|
||||||
STD := c17
|
STD := c17
|
||||||
LANG = c
|
LANG = c
|
||||||
CFLAGS := $(shell pkg-config --cflags sdl2) -Wall -g -pedantic
|
CFLAGS := $(shell pkg-config --cflags sdl2) -Wall -Wall -Wextra -Wpedantic -Wno-pointer-arith
|
||||||
LDFLAGS := $(shell pkg-config --libs sdl2) -lm
|
LDFLAGS := $(shell pkg-config --libs sdl2) -lm
|
||||||
|
|
||||||
|
ifeq ($(DEBUG),1)
|
||||||
|
CFLAGS += -Og -g
|
||||||
|
else
|
||||||
|
REL_FLAGS += -O3
|
||||||
|
endif
|
||||||
|
|
||||||
# file locations
|
# file locations
|
||||||
DIR_BIN := bin
|
DIR_BIN := bin
|
||||||
DIR_OBJ := obj
|
DIR_OBJ := obj
|
||||||
|
|||||||
Reference in New Issue
Block a user