10 # Makefile : Builds OGL classes library (MS VC++).
11 # Use FINAL=1 argument to nmake to build final version with no debugging
15 # Set WXDIR for your system
17 OGLDIR = $(WXDIR)\contrib\src\ogl
18 OGLINC = $(WXDIR)\contrib\include\wx\ogl
19 THISDIR = $(WXDIR)\contrib\src\ogl
20 EXTRAFLAGS=/DPROLOGIO=1
22 DOCSOURCEDIR=$(WXDIR)\contrib\docs\latex\ogl
24 !include $(WXDIR)\src\makevc.env
28 OBJECTS = $(D)\basic.obj $(D)\basic2.obj $(D)\canvas.obj $(D)\ogldiag.obj $(D)\lines.obj $(D)\oglmisc.obj $(D)\divided.obj $(D)\constrnt.obj\
29 $(D)\composit.obj $(D)\drawn.obj $(D)\bmpshape.obj $(D)\mfutils.obj
31 LIBTARGET=$(WXDIR)\lib\ogl$(LIBEXT).lib
33 all: $(D) $(LIBTARGET)
35 $(PROGRAM): $(PROGRAM).exe
42 nmake -f makefile.vc FINAL=$(FINAL)
47 nmake -f makefile.vc clean
50 $(LIBTARGET): $(OBJECTS)
58 # NOTE: This causes a floating point stack error when optimized,
60 $(D)\basic.obj: basic.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/lines.h $(OGLINC)/misc.h $(OGLINC)/canvas.h
62 $(CPPFLAGS) /Od /c /Fo$@ /Tp $(*B).$(SRCSUFF)
65 $(D)\basic2.obj: basic2.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/lines.h $(OGLINC)/misc.h $(OGLINC)/canvas.h
67 $(CPPFLAGS) /Od /c /Fo$@ /Tp $(*B).$(SRCSUFF)
70 $(D)\canvas.obj: canvas.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/misc.h $(OGLINC)/canvas.h
72 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
75 $(D)\ogldiag.obj: ogldiag.$(SRCSUFF) $(OGLINC)/ogldiag.h $(OGLINC)/canvas.h $(OGLINC)/basic.h
77 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
80 $(D)\lines.obj: lines.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/misc.h $(OGLINC)/canvas.h $(OGLINC)/lines.h $(OGLINC)/basicp.h $(OGLINC)/linesp.h
82 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
85 $(D)\oglmisc.obj: oglmisc.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/misc.h $(OGLINC)/constrnt.h $(OGLINC)/basicp.h
87 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
90 $(D)\divided.obj: divided.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/misc.h $(OGLINC)/canvas.h $(OGLINC)/divided.h $(OGLINC)/basicp.h
92 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
95 $(D)\constrnt.obj: constrnt.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/constrnt.h
97 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
100 $(D)\composit.obj: composit.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/misc.h $(OGLINC)/canvas.h $(OGLINC)/constrnt.h $(OGLINC)/composit.h $(OGLINC)/basicp.h
102 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
105 $(D)\drawn.obj: drawn.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/misc.h $(OGLINC)/canvas.h $(OGLINC)/drawn.h $(OGLINC)/drawnp.h $(OGLINC)/basicp.h
107 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
110 $(D)\bmpshape.obj: bmpshape.$(SRCSUFF) $(OGLINC)/basic.h $(OGLINC)/misc.h $(OGLINC)/canvas.h $(OGLINC)/bmpshape.h
112 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
115 $(D)\mfutils.obj: mfutils.$(SRCSUFF) $(OGLINC)/mfutils.h
117 $(CPPFLAGS) /c /Fo$@ /Tp $(*B).$(SRCSUFF)
129 DOCSOURCES=$(DOCSOURCEDIR)\ogl.tex \
130 $(DOCSOURCEDIR)\bugs.tex $(DOCSOURCEDIR)\changes.tex\
131 $(DOCSOURCEDIR)\classes.tex $(DOCSOURCEDIR)\intro.tex\
132 $(DOCSOURCEDIR)\topics.tex $(DOCSOURCEDIR)\sample.tex
134 alldocs: mkdirs html htmlhelp htb hlp pdfrtf
136 html: $(DOCDIR)\html\ogl\ogl.htm
137 htmlhelp: $(DOCDIR)\htmlhelp\ogl.chm
138 htb: $(DOCDIR)\htb\ogl.htb
139 hlp: $(DOCDIR)\winhelp\ogl.hlp
140 pdfrtf: $(DOCDIR)\pdf\ogl.rtf
141 ps: $(DOCDIR)\ps\ogl.ps
144 -mkdir $(DOCDIR)\html $(DOCDIR)\html\ogl $(DOCDIR)\htb $(DOCDIR)\htmlhelp $(DOCDIR)\winhelp $(DOCDIR)\pdf
147 touch $(DOCSOURCEDIR)\ogl.tex
149 $(DOCDIR)\winhelp\ogl.hlp: $(DOCSOURCEDIR)\ogl.rtf $(DOCSOURCEDIR)\ogl.hpj
153 move ogl.hlp ogl.cnt $(DOCDIR)\winhelp
156 $(DOCSOURCEDIR)\ogl.rtf: $(DOCSOURCES)
158 -start $(WAITFLAG) tex2rtf $(DOCSOURCEDIR)\ogl.tex $(DOCSOURCEDIR)\ogl.rtf -twice -winhelp
161 $(DOCDIR)\pdf\ogl.rtf: $(DOCSOURCES)
163 -copy *.bmp $(DOCDIR)\pdf
164 -start $(WAITFLAG) tex2rtf $(DOCSOURCEDIR)\ogl.tex $(DOCDIR)\pdf\ogl.rtf -twice -rtf
167 $(DOCDIR)\html\ogl\ogl.htm: $(DOCSOURCES)
169 -mkdir $(DOCDIR)\html\ogl
170 copy *.gif $(DOCDIR)\html\ogl
171 -start $(WAITFLAG) tex2rtf $(DOCSOURCEDIR)\ogl.tex $(DOCDIR)\html\ogl\ogl.htm -twice -html
172 -erase $(DOCDIR)\html\ogl\*.con
174 -erase $(DOCDIR)\html\ogl\*.ref
177 $(DOCDIR)\htmlhelp\ogl.chm: $(DOCDIR)\html\ogl\ogl.htm $(DOCDIR)\html\ogl\ogl.hhp
178 cd $(DOCDIR)\html\ogl
180 -erase $(DOCDIR)\htmlhelp\ogl.chm
181 move ogl.chm $(DOCDIR)\htmlhelp\ogl.chm
184 # An htb file is a zip file containing the .htm, .gif, .hhp, .hhc and .hhk
185 # files, renamed to htb.
186 # This can then be used with e.g. helpview.
187 # Optionally, a cached version of the .hhp file can be generated with hhp2cached.
188 $(DOCDIR)\htb\ogl.htb: $(DOCDIR)\html\ogl\ogl.htm
189 cd $(DOCDIR)\html\ogl
190 -erase ogl.zip ogl.htb
191 zip ogl.zip *.htm *.gif *.hhp *.hhc *.hhk
193 -erase $(DOCDIR)\htb\ogl.htb
194 -erase $(DOCDIR)\htb\ogl.htb
195 move ogl.zip $(DOCDIR)\htb\ogl.htb
198 $(DOCSOURCEDIR)\ogl.dvi: $(DOCSOURCES)
208 $(WXDIR)\docs\ps\ogl.ps: $(DOCSOURCEDIR)\ogl.dvi
210 -dvips32 -o ogl.ps ogl
211 move ogl.ps $(WXDIR)\docs\ps\ogl.ps