From caea5ec4cb60943659edc373f2bb06492b376669 Mon Sep 17 00:00:00 2001 From: Zerocker Date: Fri, 5 Jun 2020 20:40:08 +0900 Subject: [PATCH] Nuke old VERSION OPT_FLAGS and add DEBUG flag --- Makefile | 10 ++++------ build.sh | 4 ++-- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index 49b60620..bfe0f8dc 100644 --- a/Makefile +++ b/Makefile @@ -10,6 +10,8 @@ default: all # These options can either be changed by modifying the makefile, or # by building with 'make SETTING=value'. 'make clean' may be required. +# Build debug version (default) +DEBUG ?= 1 # Version of the game to build VERSION ?= us # Graphics microcode used @@ -280,15 +282,11 @@ GODDARD_SRC_DIRS := src/goddard src/goddard/dynlists MIPSISET := -mips2 MIPSBIT := -32 -ifeq ($(VERSION),eu) - OPT_FLAGS := -O2 -else -ifeq ($(VERSION),sh) - OPT_FLAGS := -O2 +ifeq ($(DEBUG),1) + OPT_FLAGS := -g else OPT_FLAGS := -O2 endif -endif # Set BITS (32/64) to compile for OPT_FLAGS += $(BITS) diff --git a/build.sh b/build.sh index 87d3597b..040860be 100644 --- a/build.sh +++ b/build.sh @@ -7,8 +7,8 @@ LIBAFLA=libaudiofile.la AUDDIR=./tools/audiofile-0.3.6 # Command line options -OPTIONS=("Analog Camera" "No Draw Distance" "Text-saves" "Smoke Texture Fix" "Clean build") -EXTRA=("BETTERCAMERA=1" "NODRAWINGDISTANCE=1" "TEXTSAVES=1" "TEXTURE_FIX=1" "clean") +OPTIONS=("Analog Camera" "No Draw Distance" "Text-saves" "Smoke Texture Fix" "Release build" "Clean build") +EXTRA=("BETTERCAMERA=1" "NODRAWINGDISTANCE=1" "TEXTSAVES=1" "TEXTURE_FIX=1" "DEBUG=0" "clean") # Colors RED=$(tput setaf 1)