diff Makefile @ 794:792be135d3af

Spawn a terminal for the debugger when needed if we are not already attached to one
author Michael Pavone <pavone@retrodev.com>
date Sun, 26 Jul 2015 01:11:04 -0700
parents e64975fc5f98
children 0b692b5d154b
line wrap: on
line diff
--- a/Makefile	Sun Jul 26 01:09:05 2015 -0700
+++ b/Makefile	Sun Jul 26 01:11:04 2015 -0700
@@ -5,6 +5,7 @@
 ifeq ($(OS),Windows)
 
 MEM:=mem_win.o
+TERMINAL:=terminal_win.o
 BLASTEM:=blastem.exe
 CC:=wine gcc.exe
 CFLAGS:=-O2 -std=gnu99 -Wreturn-type -Werror=return-type -Werror=implicit-function-declaration -I"C:/MinGW/usr/include/SDL2" -DGLEW_STATIC
@@ -14,6 +15,7 @@
 else
 
 MEM:=mem.o
+TERMINAL:=terminal.o
 BLASTEM:=blastem
 
 ifeq ($(OS),Darwin)
@@ -99,7 +101,7 @@
 AUDIOOBJS=ym2612.o psg.o wave.o
 CONFIGOBJS=config.o tern.o util.o
 
-MAINOBJS=blastem.o debug.o gdb_remote.o vdp.o render_sdl.o io.o romdb.o $(CONFIGOBJS) gst.o $(M68KOBJS) $(TRANSOBJS) $(AUDIOOBJS)
+MAINOBJS=blastem.o debug.o gdb_remote.o vdp.o render_sdl.o io.o romdb.o $(TERMINAL) $(CONFIGOBJS) gst.o $(M68KOBJS) $(TRANSOBJS) $(AUDIOOBJS)
 
 ifeq ($(CPU),x86_64)
 CFLAGS+=-DX86_64 -m64
@@ -119,9 +121,12 @@
 
 ifeq ($(OS),Windows)
 MAINOBJS+= glew32s.lib
+ALL=$(BLASTEM)
+else
+ALL= dis zdis stateview vgmplay blastem termhelper
 endif
 
-all : dis zdis stateview vgmplay blastem
+all : $(ALL)
 
 $(BLASTEM) : $(MAINOBJS)
 	$(CC) -o $(BLASTEM) $(MAINOBJS) $(LDFLAGS)
@@ -188,4 +193,4 @@
 	vasmz80_mot -Fbin -spaces -o $@ $<
 
 clean :
-	rm -rf dis trans stateview test_x86 gen_fib *.o
+	rm -rf $(ALL) trans ztestrun ztestgen *.o