6 # Copyright: (c) 1996 Julian Smart
10 # Makefile for object graphics library (UNIX).
14 # All common UNIX compiler flags and options are now in
15 # this central makefile.
16 include $(WXDIR)/src/make.env
18 PRODIR = $(WXDIR)/utils/prologio
19 PROINC = $(PRODIR)/src
20 PROLIB = $(PRODIR)/lib/libproio$(GUISUFFIX).a
22 MFDIR = $(WXDIR)/utils/mfutils
25 OGLDIR = $(WXDIR)/utils/ogl
26 OGLLIB = $(OGLDIR)/lib/libogl$(GUISUFFIX).a
28 OBJECTS = $(OBJDIR)/basic.o $(OBJDIR)/basic2.o $(OBJDIR)/canvas.o $(OBJDIR)/lines.o $(OBJDIR)/misc.o\
29 $(OBJDIR)/divided.o $(OBJDIR)/constrnt.o $(OBJDIR)/composit.o $(OBJDIR)/drawn.o\
30 $(OBJDIR)/bitmap.o $(OBJDIR)/ogldiag.o
32 CPPFLAGS = -I$(PROINC) -I$(MFINC) $(XINCLUDE) $(INC) $(GUI) -DDEBUG='$(DEBUG)' $(DEBUGFLAGS) $(WARN) $(OPTIONS) -DPROLOGIO
34 all: $(OBJDIR) $(OGLLIB)
39 cd $(WXDIR)/src/x; $(MAKE) -f makefile.unx OPT=$(OPT) GUI=$(GUI)
42 $(MAKE) -f makefile.unx GUI=-Dwx_motif OPT=$(OPT) GUISUFFIX=_motif LDLIBS='$(MOTIFLDLIBS)' XVIEW_LINK=
45 $(MAKE) -f makefile.unx GUI=-Dwx_xview OPT=$(OPT) GUISUFFIX=_ol
48 $(MAKE) -f makefile.unx GUI=-Dwx_motif GUISUFFIX=_hp CC=CC DEBUG='$(DEBUG)' DEBUGFLAGS='-g' OPT='' WARN='-w' \
49 XINCLUDE='$(HPXINCLUDE)' XLIB='$(HPXLIB)' XVIEW_LINK='' \
57 ar $(AROPTIONS) $@ $(OBJECTS)
60 $(OBJDIR)/basic.o: basic.$(SRCSUFF) basic.h lines.h misc.h canvas.h
61 $(CC) -c $(CPPFLAGS) -o $@ basic.$(SRCSUFF)
63 $(OBJDIR)/basic2.o: basic2.$(SRCSUFF) basic.h lines.h misc.h canvas.h
64 $(CC) -c $(CPPFLAGS) -o $@ basic2.$(SRCSUFF)
66 $(OBJDIR)/canvas.o: canvas.$(SRCSUFF) basic.h misc.h canvas.h
67 $(CC) -c $(CPPFLAGS) -o $@ canvas.$(SRCSUFF)
69 $(OBJDIR)/lines.o: lines.$(SRCSUFF) basic.h misc.h canvas.h lines.h
70 $(CC) -c $(CPPFLAGS) -o $@ lines.$(SRCSUFF)
72 $(OBJDIR)/misc.o: misc.$(SRCSUFF) basic.h misc.h constrnt.h
73 $(CC) -c $(CPPFLAGS) -o $@ misc.$(SRCSUFF)
75 $(OBJDIR)/divided.o: divided.$(SRCSUFF) basic.h misc.h canvas.h divided.h
76 $(CC) -c $(CPPFLAGS) -o $@ divided.$(SRCSUFF)
78 $(OBJDIR)/constrnt.o: constrnt.$(SRCSUFF) basic.h constrnt.h
79 $(CC) -c $(CPPFLAGS) -o $@ constrnt.$(SRCSUFF)
81 $(OBJDIR)/composit.o: composit.$(SRCSUFF) basic.h misc.h canvas.h constrnt.h composit.h
82 $(CC) -c $(CPPFLAGS) -o $@ composit.$(SRCSUFF)
84 $(OBJDIR)/drawn.o: drawn.$(SRCSUFF) basic.h misc.h canvas.h drawn.h drawnp.h
85 $(CC) -c $(CPPFLAGS) -o $@ drawn.$(SRCSUFF)
87 $(OBJDIR)/bitmap.o: bitmap.$(SRCSUFF) basic.h misc.h canvas.h bitmap.h
88 $(CC) -c $(CPPFLAGS) -o $@ bitmap.$(SRCSUFF)
90 $(OBJDIR)/ogldiag.o: ogldiag.$(SRCSUFF) basic.h misc.h canvas.h bitmap.h ogldiag.h
91 $(CC) -c $(CPPFLAGS) -o $@ ogldiag.$(SRCSUFF)
93 HTMLDIR=/home/hardy/html/wx/manuals
96 ps: $(OGLDIR)/docs/ogl.ps
97 xlp: $(OGLDIR)/docs/ogl.xlp
98 html: $(HTMLDIR)/ogl/ogl_contents.html
100 $(OGLDIR)/docs/ogl.xlp: $(OGLDIR)/docs/classes.tex $(OGLDIR)/docs/ogl.tex $(OGLDIR)/docs/topics.tex $(OGLDIR)/docs/changes.tex $(OGLDIR)/docs/intro.tex
101 cd ../docs; tex2rtf ogl.tex tmp.xlp -xlp -twice
102 sed -e "s/WXHELPCONTENTS/OGL Manual/g" < $(OGLDIR)/docs/tmp.xlp > $(OGLDIR)/docs/ogl.xlp
103 /bin/rm -f $(OGLDIR)/docs/tmp.xlp
105 $(HTMLDIR)/ogl/ogl_contents.html: $(OGLDIR)/docs/classes.tex $(OGLDIR)/docs/ogl.tex $(OGLDIR)/docs/topics.tex $(OGLDIR)/docs/changes.tex $(OGLDIR)/docs/intro.tex
106 cd ../docs; tex2rtf ogl.tex $(HTMLDIR)/ogl/ogl -twice -html
108 $(OGLDIR)/docs/ogl.dvi: $(OGLDIR)/docs/ogl.tex $(OGLDIR)/docs/classes.tex $(OGLDIR)/docs/topics.tex $(OGLDIR)/docs/changes.tex $(OGLDIR)/docs/intro.tex
109 cd $(OGLDIR)/docs; latex ogl; latex ogl; makeindex ogl; latex ogl; \
111 $(OGLDIR)/docs/ogl.ps: $(OGLDIR)/docs/ogl.dvi
112 cd $(OGLDIR)/docs; dvips -f -r < ogl.dvi > ogl.ps
115 rm -f $(OBJECTS) $(OGLLIB) core
118 $(MAKE) -f makefile.unx GUISUFFIX=_motif cleaneach
121 $(MAKE) -f makefile.unx GUISUFFIX=_ol cleaneach
124 $(MAKE) -f makefile.unx GUISUFFIX=_hp cleaneach