Last change
on this file since 682 was 678, checked in by alloc, 12 years ago |
Daodan: Updated src to work with MinGW
|
-
Property svn:executable
set to
*
|
File size:
979 bytes
|
Line | |
---|
1 | GCC = i686-w64-mingw32-gcc
|
---|
2 | DLLTOOL = i686-w64-mingw32-dlltool
|
---|
3 |
|
---|
4 | GCCFLAGS = -O0 -Wall -fomit-frame-pointer -fpack-struct
|
---|
5 | LINKFLAGS = -O0 -Wall -fomit-frame-pointer -fpack-struct -s -mdll -mthread
|
---|
6 |
|
---|
7 | #LIBS = -lwinmm -lopengl32 -lgdi32
|
---|
8 | LIBS = -lgdi32
|
---|
9 | OBJS = obj/binkw32.a
|
---|
10 | OUT = build/binkw32.dll
|
---|
11 |
|
---|
12 | SRC = 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
|
---|
13 | DEST = $(patsubst src/%.c,build/%.o,$(SRC))
|
---|
14 |
|
---|
15 | ALL: $(FOLDERS) $(DEST) $(OBJS)
|
---|
16 | echo "Linking $<"
|
---|
17 | $(GCC) $(LINKFLAGS) -o $(OUT) $(DEST) $(OBJS) $(LIBS)
|
---|
18 |
|
---|
19 | clean:
|
---|
20 | rm $(DEST)
|
---|
21 | rm $(OUT)
|
---|
22 |
|
---|
23 | obj/binkw32.a: src/binkw32.def
|
---|
24 | echo "Generating binkw32.a"
|
---|
25 | $(DLLTOOL) -d $< -l $@
|
---|
26 |
|
---|
27 | build/%.o: src/%.c
|
---|
28 | echo "Compiling $<"
|
---|
29 | $(GCC) $(GCCFLAGS) -c -o $@ $<
|
---|
30 | echo
|
---|
31 |
|
---|
32 | $(FOLDERS):
|
---|
33 | mkdir $@
|
---|
Note:
See
TracBrowser
for help on using the repository browser.