]>
Commit | Line | Data |
---|---|---|
c801d85f | 1 | # |
7921cf2b | 2 | # File: makefile.vc |
c801d85f KB |
3 | # Author: Julian Smart |
4 | # Created: 1993 | |
3156ba6e | 5 | # Updated: |
c801d85f KB |
6 | # Copyright: (c) 1993, AIAI, University of Edinburgh |
7 | # | |
8 | # "%W% %G%" | |
9 | # | |
10 | # Makefile : Builds winpng.lib library for Windows 3.1 | |
11 | ||
12 | # Change WXDIR or WXWIN to wherever wxWindows is found | |
13 | WXDIR = $(WXWIN) | |
c801d85f KB |
14 | |
15 | WINPNGDIR = ..\png | |
16 | WINPNGINC = $(WINPNGDIR) | |
5fa399c9 JS |
17 | |
18 | !if "$(FINAL)" == "1" | |
19 | WINPNGLIB=..\..\lib\png.lib | |
20 | !else | |
21 | WINPNGLIB=..\..\lib\pngd.lib | |
22 | !endif | |
c801d85f KB |
23 | |
24 | INC = /I..\zlib | |
25 | ||
26 | # Set this to nothing if your compiler is MS C++ 7 | |
27 | ZOPTION= | |
28 | ||
29 | !ifndef FINAL | |
30 | FINAL=0 | |
31 | !endif | |
32 | ||
3156ba6e | 33 | PRECOMP=/YuWX.H |
c801d85f KB |
34 | |
35 | !if "$(FINAL)" == "0" | |
36 | OPT = /Od | |
3156ba6e RD |
37 | CPPFLAGS= /W4 /Zi $(CRTFLAG) /GX $(ZOPTION) $(OPT) /D__WXMSW__ $(INC) |
38 | CFLAGS= /W4 /Zi $(CRTFLAG) /GX /Od /D__WXMSW__ $(INC) | |
c801d85f | 39 | LINKFLAGS=/NOD /CO /ONERROR:NOEXE |
3156ba6e | 40 | _CRTFLAG=/MDd |
c801d85f KB |
41 | !else |
42 | # /Ox for real FINAL version | |
43 | OPT = /O2 | |
3156ba6e RD |
44 | CPPFLAGS= /W4 $(CRTFLAG) /GX /D__WXMSW__ $(INC) |
45 | CFLAGS= /W4 $(CRTFLAG) /GX /D__WXMSW__ $(INC) | |
c801d85f | 46 | LINKFLAGS=/NOD /ONERROR:NOEXE |
3156ba6e | 47 | _CRTFLAG=/MDd |
c801d85f KB |
48 | !endif |
49 | ||
3156ba6e RD |
50 | !if "$(CRTFLAG)" == "" |
51 | CRTFLAG=$(_CRTFLAG) | |
52 | !endif | |
53 | ||
54 | ||
c801d85f KB |
55 | OBJECTS = png.obj pngread.obj pngrtran.obj pngrutil.obj \ |
56 | pngpread.obj pngtrans.obj pngwrite.obj pngwtran.obj pngwutil.obj \ | |
57 | pngerror.obj pngmem.obj pngwio.obj pngrio.obj pngget.obj pngset.obj | |
58 | ||
59 | all: $(WINPNGLIB) | |
60 | ||
61 | $(WINPNGLIB): $(OBJECTS) | |
7fee680b | 62 | -erase $(WINPNGLIB) |
c801d85f KB |
63 | lib @<< |
64 | -out:$(WINPNGLIB) | |
65 | $(OBJECTS) | |
66 | << | |
67 | ||
68 | .c.obj: | |
69 | cl -DWIN32 $(OPT) $(CFLAGS) /c $*.c | |
70 | ||
71 | clean: | |
e6f09be7 BM |
72 | -erase *.obj |
73 | -erase *.exe | |
7fee680b | 74 | -erase $(WINPNGLIB) |
c801d85f KB |
75 | |
76 | cleanall: clean |