Skip to content

Commit

Permalink
simplify building debug builds
Browse files Browse the repository at this point in the history
  • Loading branch information
sauerbraten committed Jan 12, 2023
1 parent 943ed69 commit 00452d5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ SHELL := /bin/bash

.PHONY: build install clean anticheat linux macos windows apply-patches gzip-cfgs embed-cfgs clean-sauer update-src from-patches changes-to-patch ensure-sauer-dir

# build install: export DEBUG=1
build:
cd src && make --jobs=8

Expand Down
3 changes: 2 additions & 1 deletion src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ endif
CFLAGS= --target=$(TARGET)
CXXFLAGS= --target=$(TARGET) -fomit-frame-pointer -ffast-math
ifdef DEBUG
override CXXFLAGS+= -O0 -g -DDEBUG=$$DEBUG
override CFLAGS+= -g3
override CXXFLAGS+= -O0 -g3 -DDEBUG=$$DEBUG
else
override CXXFLAGS+= -O3
endif
Expand Down

0 comments on commit 00452d5

Please sign in to comment.