From 9f8cbf9b523eef988a08309c58785590fd59fcb7 Mon Sep 17 00:00:00 2001 From: Eric Mullins Date: Sun, 12 Jul 2009 15:29:28 -0600 Subject: [PATCH] Added Jaws support to GCC makefile --- winboard/makefile.gcc | 106 +++++++++++++++++++++++++++---------------------- 1 files changed, 58 insertions(+), 48 deletions(-) diff --git a/winboard/makefile.gcc b/winboard/makefile.gcc index b358337..43fb4fe 100644 --- a/winboard/makefile.gcc +++ b/winboard/makefile.gcc @@ -18,6 +18,10 @@ compile = @echo "$1"; $(CC) $(CFLAGS) $1 USE_DEBUG=0 +# JAWS support? +JAWS=0 + + # set this to 1 unless you don't mind linking with cygwin1.dll USE_MINGW=1 @@ -28,7 +32,6 @@ CFCYG = -mno-cygwin LFCYG = -mno-cygwin -lmsvcrt endif - CC = gcc FLEX = "flex.exe" # we need version 2.5.4 or later, cygwin's is 2.5.35 # "c:/mingw/mingw32/bin/flex.exe" @@ -46,6 +49,13 @@ CF = -c $(WARN) -pipe $(CFDEBUG) $(DEFS) -I. -I.. CFLAGS = $(CF) $(ARCH) $(OPTS) $(CFCYG) LFLAGS = $(LFCYG) $(CFDEBUG) -fpic -s -mwindows -lwsock32 -lwinmm -lcomctl32 +# set up for JAWS +RESDEPS = $(PROJ).rc $(PROJ).h resource.h +ifeq ($(JAWS),1) + RESDEPS = jaws.rc resource.h jaws.h + DEFS += -DJAWS +endif + all: $(PROJ).exe @@ -65,8 +75,8 @@ $(PROJ).hlp : $(PROJ).rtf # Update the resource if necessary -wbres.o: $(PROJ).rc $(PROJ).h resource.h - windres --use-temp-file --include-dir .. $< -O coff -o $@ +wbres.o: $(RESDEPS) + windres $(DEFS) --use-temp-file --include-dir .. $< -O coff -o $@ # note: cygwin flex needs m4 package. cygwin-setup forgets this dependency @@ -82,7 +92,7 @@ $(PROJ).exe: $(OBJS) $(PROJ).hlp winboard.o: winboard.c config.h winboard.h ../common.h ../frontend.h ../backend.h \ ../moves.h wgamelist.h defaults.h resource.h wclipbrd.h \ - wedittags.h wsockerr.h woptions.h wsnap.h ../lists.h help.h + wedittags.h wsockerr.h woptions.h wsnap.h ../lists.h help.h $(call compile, $<) backend.o: ../backend.c config.h ../common.h ../frontend.h ../backend.h \ @@ -101,50 +111,50 @@ lists.o: ../lists.c config.h ../lists.h ../common.h $(call compile, $<) gamelist.o: ../gamelist.c config.h ../lists.h ../common.h ../frontend.h \ - ../backend.h ../parser.h - $(call compile, $<) - -wclipbrd.o: wclipbrd.c config.h ../common.h ../frontend.h ../backend.h \ - winboard.h resource.h wclipbrd.h ../lists.h - $(call compile, $<) - -wedittags.o: wedittags.c config.h ../common.h winboard.h resource.h ../frontend.h \ - ../backend.h ../lists.h wedittags.h - $(call compile, $<) - -wgamelist.o: wgamelist.c config.h. ../common.h winboard.h resource.h ../frontend.h \ - ../backend.h wgamelist.h ../lists.h - $(call compile, $<) - -woptions.o: woptions.c config.h ../common.h ../frontend.h ../backend.h ../lists.h \ - defaults.h winboard.h resource.h - $(call compile, $<) - -wengineo.o: wengineo.c config.h ../common.h ../frontend.h ../backend.h \ - ../lists.h winboard.h resource.h wsnap.h - $(call compile, $<) - -whistory.o: whistory.c config.h ../common.h ../frontend.h ../backend.h \ - ../lists.h winboard.h resource.h wsnap.h - $(call compile, $<) - -wevalgraph.o: wevalgraph.c config.h ../common.h ../frontend.h ../backend.h \ - ../lists.h winboard.h resource.h wsnap.h - $(call compile, $<) - -wlayout.o: wlayout.c config.h ../common.h winboard.h resource.h - $(call compile, $<) - -wsockerr.o: wsockerr.c wsockerr.h - $(call compile, $<) - -help.o: help.c help.h - $(call compile, $<) - -wsnap.o: wsnap.c wsnap.h - $(call compile, $<) - -pgntags.o: ../pgntags.c config.h ../common.h ../frontend.h ../backend.h \ + ../backend.h ../parser.h + $(call compile, $<) + +wclipbrd.o: wclipbrd.c config.h ../common.h ../frontend.h ../backend.h \ + winboard.h resource.h wclipbrd.h ../lists.h + $(call compile, $<) + +wedittags.o: wedittags.c config.h ../common.h winboard.h resource.h ../frontend.h \ + ../backend.h ../lists.h wedittags.h + $(call compile, $<) + +wgamelist.o: wgamelist.c config.h. ../common.h winboard.h resource.h ../frontend.h \ + ../backend.h wgamelist.h ../lists.h + $(call compile, $<) + +woptions.o: woptions.c config.h ../common.h ../frontend.h ../backend.h ../lists.h \ + defaults.h winboard.h resource.h + $(call compile, $<) + +wengineo.o: wengineo.c config.h ../common.h ../frontend.h ../backend.h \ + ../lists.h winboard.h resource.h wsnap.h + $(call compile, $<) + +whistory.o: whistory.c config.h ../common.h ../frontend.h ../backend.h \ + ../lists.h winboard.h resource.h wsnap.h + $(call compile, $<) + +wevalgraph.o: wevalgraph.c config.h ../common.h ../frontend.h ../backend.h \ + ../lists.h winboard.h resource.h wsnap.h + $(call compile, $<) + +wlayout.o: wlayout.c config.h ../common.h winboard.h resource.h + $(call compile, $<) + +wsockerr.o: wsockerr.c wsockerr.h + $(call compile, $<) + +help.o: help.c help.h + $(call compile, $<) + +wsnap.o: wsnap.c wsnap.h + $(call compile, $<) + +pgntags.o: ../pgntags.c config.h ../common.h ../frontend.h ../backend.h \ ../parser.h ../lists.h $(call compile, $<) -- 1.7.0.4