mirror of https://github.com/bsnes-emu/bsnes.git
Added debug/release configurations
This commit is contained in:
parent
1a66f26a5e
commit
abfebf0eb2
9
Makefile
9
Makefile
|
@ -12,6 +12,7 @@ CC := clang
|
|||
CFLAGS += -Werror -Wall -std=gnu11 -ICore -D_GNU_SOURCE
|
||||
SDL_LDFLAGS := -lSDL
|
||||
LDFLAGS += -lc -lm
|
||||
CONF ?= debug
|
||||
|
||||
ifeq ($(shell uname -s),Darwin)
|
||||
CFLAGS += -F/Library/Frameworks
|
||||
|
@ -20,6 +21,14 @@ LDFLAGS += -framework AppKit
|
|||
SDL_LDFLAGS := -framework SDL
|
||||
endif
|
||||
|
||||
ifeq ($(CONF),debug)
|
||||
CFLAGS += -g
|
||||
else ifeq ($(CONF), release)
|
||||
CFLAGS += -O3
|
||||
else
|
||||
$(error Invalid value for CONF: $(CONF). Use "debug" or "release")
|
||||
endif
|
||||
|
||||
cocoa: $(BIN)/Sameboy.app
|
||||
sdl: $(BIN)/sdl/sameboy $(BIN)/sdl/dmg_boot.bin $(BIN)/sdl/cgb_boot.bin
|
||||
bootroms: $(BIN)/BootROMs/cgb_boot.bin $(BIN)/BootROMs/dmg_boot.bin
|
||||
|
|
Loading…
Reference in New Issue