source: Daodan/makefile@ 684

Last change on this file since 684 was 684, checked in by alloc, 12 years ago

Daodan: Fixed makefile to forward-export to realbink

  • Property svn:executable set to *
File size: 1017 bytes
Line 
1UNAME := $(shell uname -s)
2ifeq ("Linux","$(UNAME)")
3 GCC := i686-w64-mingw32-gcc
4 DLLTOOL := i686-w64-mingw32-dlltool
5else
6 GCC := gcc
7 DLLTOOL := dlltool
8endif
9
10GCCFLAGS = -O0 -Wall -fomit-frame-pointer -fpack-struct
11LINKFLAGS = -O0 -Wall -fomit-frame-pointer -fpack-struct -s -mdll -mthread -Xlinker --major-image-version -Xlinker 1
12
13#LIBS = -lwinmm -lopengl32 -lgdi32
14LIBS = -lgdi32
15OBJS = src/binkw32.def
16OUT = build/binkw32.dll
17
18SRC = src/Daodan.c src/Daodan_BSL.c src/Daodan_Character.c src/Daodan_Cheater.c src/Daodan_Console.c src/Daodan_DLLStubs.c src/daodan_gl.c src/Daodan_Patch.c src/Daodan_Persistence.c src/Daodan_Utility.c src/Daodan_Win32.c src/Daodan_WindowHack.c src/inifile_reader.c src/Oni_Symbols.c
19DEST = $(patsubst src/%.c,build/%.o,$(SRC))
20
21ALL: $(DEST) $(OBJS)
22 echo "Linking $<"
23 $(GCC) $(LINKFLAGS) -o $(OUT) $(DEST) $(OBJS) $(LIBS)
24
25clean:
26 rm $(DEST)
27 rm $(OUT)
28
29build/%.o: src/%.c
30 echo "Compiling $<"
31 $(GCC) $(GCCFLAGS) -c -o $@ $<
32 echo
33
Note: See TracBrowser for help on using the repository browser.