]> git.saurik.com Git - wxWidgets.git/blame - src/png/scripts/makefile.bc32
Fix recursion problems when loading pages from a virtual file system using the WebKit...
[wxWidgets.git] / src / png / scripts / makefile.bc32
CommitLineData
0272a10d
VZ
1# Makefile for libpng
2# 32-bit Borland C++ (Note: All modules are compiled in C mode)
3# To build the library, do:
4# "make -fmakefile.bc32"
5#
6# -------------------- 32-bit Borland C++ --------------------
7
8### Absolutely necessary for this makefile to work
9.AUTODEPEND
10
11## Where zlib.h, zconf.h and zlib.lib are
12ZLIB_DIR=..\zlib
13
0272a10d
VZ
14## Compiler, linker and lib stuff
15CC=bcc32
16LD=bcc32
17LIB=tlib
18
19# -3 = 386, -4 = 486, -5 = Pentium etc.
20!ifndef TARGET_CPU
21#TARGET_CPU=-6
22!endif
23
24# Use this if you don't want Borland's fancy exception handling
25# (Caution: doesn't work with CBuilderX)
26#NOEHLIB=noeh32.lib
27
28!ifdef DEBUG
29CDEBUG=-v
30LDEBUG=-v
31!else
32CDEBUG=
33LDEBUG=
34!endif
35
36# STACKOFLOW=1
37!ifdef STACKOFLOW
38CDEBUG=$(CDEBUG) -N
39LDEBUG=$(LDEBUG) -N
40!endif
41
42# -O2 optimize for speed
43# -d merge duplicate strings
44# -k- turn off standard stack frame
45# -w display all warnings
46CFLAGS=-I$(ZLIB_DIR) -O2 -d -k- -w $(TARGET_CPU) $(CDEBUG)
47
48# -M generate map file
49LDFLAGS=-L$(ZLIB_DIR) -M $(LDEBUG)
50
0272a10d
VZ
51## Variables
52OBJS = \
53 png.obj \
54 pngerror.obj \
55 pngget.obj \
56 pngmem.obj \
57 pngpread.obj \
58 pngread.obj \
59 pngrio.obj \
60 pngrtran.obj \
61 pngrutil.obj \
62 pngset.obj \
63 pngtrans.obj \
64 pngwio.obj \
65 pngwrite.obj \
66 pngwtran.obj \
67 pngwutil.obj
68
69LIBOBJS = \
70 +png.obj \
71 +pngerror.obj \
72 +pngget.obj \
73 +pngmem.obj \
74 +pngpread.obj \
75 +pngread.obj \
76 +pngrio.obj \
77 +pngrtran.obj \
78 +pngrutil.obj \
79 +pngset.obj \
80 +pngtrans.obj \
81 +pngwio.obj \
82 +pngwrite.obj \
83 +pngwtran.obj \
84 +pngwutil.obj
85
86LIBNAME=libpng.lib
87
0272a10d
VZ
88## Implicit rules
89# Braces let make "batch" calls to the compiler,
90# 2 calls instead of 12; space is important.
91.c.obj:
92 $(CC) $(CFLAGS) -c {$*.c }
93
94.c.exe:
95 $(CC) $(CFLAGS) $(LDFLAGS) $*.c $(LIBNAME) zlib.lib $(NOEHLIB)
96
97.obj.exe:
98 $(LD) $(LDFLAGS) $*.obj $(LIBNAME) zlib.lib $(NOEHLIB)
99
0272a10d
VZ
100## Major targets
101all: libpng pngtest
102
103libpng: $(LIBNAME)
104
105pngtest: pngtest.exe
106
107test: pngtest.exe
108 pngtest
109
0272a10d
VZ
110## Minor Targets
111
b61cc19c
PC
112png.obj: png.c png.h pngconf.h pngpriv.h
113pngerror.obj: pngerror.c png.h pngconf.h pngpriv.h
114pngget.obj: pngget.c png.h pngconf.h pngpriv.h
115pngmem.obj: pngmem.c png.h pngconf.h pngpriv.h
116pngpread.obj: pngpread.c png.h pngconf.h pngpriv.h
117pngread.obj: pngread.c png.h pngconf.h pngpriv.h
118pngrio.obj: pngrio.c png.h pngconf.h pngpriv.h
119pngrtran.obj: pngrtran.c png.h pngconf.h pngpriv.h
120pngrutil.obj: pngrutil.c png.h pngconf.h pngpriv.h
121pngset.obj: pngset.c png.h pngconf.h pngpriv.h
122pngtrans.obj: pngtrans.c png.h pngconf.h pngpriv.h
123pngwio.obj: pngwio.c png.h pngconf.h pngpriv.h
124pngwrite.obj: pngwrite.c png.h pngconf.h pngpriv.h
125pngwtran.obj: pngwtran.c png.h pngconf.h pngpriv.h
126pngwutil.obj: pngwutil.c png.h pngconf.h pngpriv.h
127pngtest.obj: pngtest.c png.h pngconf.h
0272a10d
VZ
128
129$(LIBNAME): $(OBJS)
130 -del $(LIBNAME)
131 $(LIB) $(LIBNAME) @&&|
132$(LIBOBJS), libpng
133|
134
0272a10d
VZ
135# Cleanup
136clean:
137 -del *.obj
138 -del $(LIBNAME)
139 -del pngtest.exe
140 -del *.lst
141 -del *.map
142 -del *.tds
143 -del pngout.png
144
0272a10d 145# End of makefile for libpng