1 # Copyright 2000, International Business Machines Corporation and others.
4 # This software has been released under the terms of the IBM Public
5 # License. For details, see the LICENSE file in the top-level source
6 # directory or online at http://www.openafs.org/dl/license10.html
8 # Makefile for gtx, a display-independent, object-oriented window toolkit.
11 include @TOP_OBJDIR@/src/config/Makefile.config
12 include @TOP_OBJDIR@/src/config/Makefile.lwp
15 INSTALL_DATA = @INSTALL_DATA@
16 INSTALL_PROGRAM = @INSTALL_PROGRAM@
17 INSTALL_SCRIPT = @INSTALL_SCRIPT@
31 ${TOP_INCDIR}/afs/keys.h \
32 ${TOP_INCDIR}/afs/cellconfig.h \
33 ${TOP_INCDIR}/afs/cmd.h
36 ${TOP_LIBDIR}/librx.a \
37 ${TOP_LIBDIR}/liblwp.a \
38 ${TOP_LIBDIR}/libsys.a \
39 ${TOP_LIBDIR}/libcmd.a \
40 ${TOP_LIBDIR}/libkauth.a \
41 ${TOP_LIBDIR}/libauth.a \
42 ${TOP_LIBDIR}/librxkad.a \
43 ${TOP_LIBDIR}/libdes.a \
44 ${TOP_LIBDIR}/libcom_err.a \
47 EXTRA_LIBS=${TXLIBS} ${XLIBS}
49 KEYMAP_SRCS=keymap.c input.c frame.c
51 KEYMAP_OBJS=keymap.o input.o frame.o
53 WINDOW_SRCS=curseswindows.c \
58 WINDOW_OBJS=curseswindows.o \
63 OBJECT_SRCS=objects.c \
67 OBJECT_OBJS=objects.o \
78 ${TOP_LIBDIR}/libgtx.a \
79 ${TOP_INCDIR}/afs/gtxcurseswin.h \
80 ${TOP_INCDIR}/afs/gtxdumbwin.h \
81 ${TOP_INCDIR}/afs/gtxframe.h \
82 ${TOP_INCDIR}/afs/gtxinput.h \
83 ${TOP_INCDIR}/afs/gtxkeymap.h \
84 ${TOP_INCDIR}/afs/gtxlightobj.h \
85 ${TOP_INCDIR}/afs/gtxobjdict.h \
86 ${TOP_INCDIR}/afs/gtxobjects.h \
87 ${TOP_INCDIR}/afs/gtxtextcb.h \
88 ${TOP_INCDIR}/afs/gtxtextobj.h \
89 ${TOP_INCDIR}/afs/gtxwindows.h \
90 ${TOP_INCDIR}/afs/gtxX11win.h
92 ${TOP_LIBDIR}/libgtx.a: libgtx.a
95 ${TOP_INCDIR}/afs/gtxcurseswin.h: gtxcurseswin.h
98 ${TOP_INCDIR}/afs/gtxdumbwin.h: gtxdumbwin.h
101 ${TOP_INCDIR}/afs/gtxframe.h: gtxframe.h
102 ${INSTALL_DATA} $? $@
104 ${TOP_INCDIR}/afs/gtxinput.h: gtxinput.h
105 ${INSTALL_DATA} $? $@
107 ${TOP_INCDIR}/afs/gtxkeymap.h: gtxkeymap.h
108 ${INSTALL_DATA} $? $@
110 ${TOP_INCDIR}/afs/gtxlightobj.h: gtxlightobj.h
111 ${INSTALL_DATA} $? $@
113 ${TOP_INCDIR}/afs/gtxobjdict.h: gtxobjdict.h
114 ${INSTALL_DATA} $? $@
116 ${TOP_INCDIR}/afs/gtxobjects.h: gtxobjects.h
117 ${INSTALL_DATA} $? $@
119 ${TOP_INCDIR}/afs/gtxtextcb.h: gtxtextcb.h
120 ${INSTALL_DATA} $? $@
122 ${TOP_INCDIR}/afs/gtxtextobj.h: gtxtextobj.h
123 ${INSTALL_DATA} $? $@
125 ${TOP_INCDIR}/afs/gtxwindows.h: gtxwindows.h
126 ${INSTALL_DATA} $? $@
128 ${TOP_INCDIR}/afs/gtxX11win.h: gtxX11win.h
129 ${INSTALL_DATA} $? $@
131 tests: object_test screen_test curses_test cb_test gtxtest
133 # All objects in the library
134 LIBSRCS = ${KEYMAP_SRCS} ${WINDOW_SRCS} ${OBJECT_SRCS} ${DICT_SRCS} ${CB_SRCS}
135 LIBOBJS = $(KEYMAP_OBJS) ${WINDOW_OBJS} ${OBJECT_OBJS} ${DICT_OBJS} ${CB_OBJS}
140 keymap.o: keymap.c ${INCLS}
142 frame.o: frame.c $(INCLS)
144 input.o: input.c ${INCLS}
146 curseswindows.o: curseswindows.c ${INCLS}
148 dumbwindows.o: dumbwindows.c ${INCLS}
150 X11windows.o: X11windows.c ${INCLS}
152 windows.o: windows.c ${INCLS}
154 lightobject.o: lightobject.c ${INCLS}
156 textobject.o: textobject.c ${INCLS}
158 textcb.o: textcb.c ${INCLS}
163 curses_test.o: curses_test.c ${INCLS} AFS_component_version_number.o
165 curses_test: curses_test.o $(LIBS)
166 $(AFS_LDRULE) curses_test.o $(LIBS) ${EXTRA_LIBS}
168 screen_test.o: screen_test.c ${INCLS} AFS_component_version_number.o
170 screen_test: screen_test.o ${WINDOW_OBJS} ${LIBS}
171 $(AFS_LDRULE) screen_test.o ${WINDOW_OBJS} ${LIBS} ${EXTRA_LIBS}
173 cb_test.o: cb_test.c ${INCLS} AFS_component_version_number.o
175 cb_test: cb_test.o ${CB_OBJS} ${LIBS}
176 $(AFS_LDRULE) cb_test.o ${CB_OBJS} ${LIBS} ${EXTRA_LIBS}
178 gtxtest.o: gtxtest.c ${INCLS} AFS_component_version_number.o
180 gtxtest: gtxtest.o libgtx.a ${LIBS}
181 $(AFS_LDRULE) gtxtest.o libgtx.a ${LIBS} ${EXTRA_LIBS}
183 object_test.o: object_test.c ${INCLS} AFS_component_version_number.o
185 object_test: object_test.o ${WINDOW_OBJS} ${DICT_OBJS} ${OBJECT_OBJS} ${CB_OBJS} ${LIBS}
186 $(AFS_LDRULE) object_test.o ${WINDOW_OBJS} ${DICT_OBJS} \
187 ${OBJECT_OBJS} ${CB_OBJS} ${LIBS} ${EXTRA_LIBS}
190 # Installation targets
192 libgtx.a: ${LIBOBJS} AFS_component_version_number.o
194 $(AR) crv $@ ${LIBOBJS} AFS_component_version_number.o
198 ${INSTALL} -d ${DESTDIR}${libdir}/afs
199 ${INSTALL} -d ${DESTDIR}${includedir}/afs
200 ${INSTALL_DATA} libgtx.a ${DESTDIR}${libdir}/afs/libgtx.a
201 ${INSTALL_DATA} ${srcdir}/gtxcurseswin.h ${DESTDIR}${includedir}/afs/gtxcurseswin.h
202 ${INSTALL_DATA} ${srcdir}/gtxdumbwin.h ${DESTDIR}${includedir}/afs/gtxdumbwin.h
203 ${INSTALL_DATA} ${srcdir}/gtxframe.h ${DESTDIR}${includedir}/afs/gtxframe.h
204 ${INSTALL_DATA} ${srcdir}/gtxinput.h ${DESTDIR}${includedir}/afs/gtxinput.h
205 ${INSTALL_DATA} ${srcdir}/gtxkeymap.h ${DESTDIR}${includedir}/afs/gtxkeymap.h
206 ${INSTALL_DATA} ${srcdir}/gtxlightobj.h ${DESTDIR}${includedir}/afs/gtxlightobj.h
207 ${INSTALL_DATA} ${srcdir}/gtxobjdict.h ${DESTDIR}${includedir}/afs/gtxobjdict.h
208 ${INSTALL_DATA} ${srcdir}/gtxobjects.h ${DESTDIR}${includedir}/afs/gtxobjects.h
209 ${INSTALL_DATA} ${srcdir}/gtxtextcb.h ${DESTDIR}${includedir}/afs/gtxtextcb.h
210 ${INSTALL_DATA} ${srcdir}/gtxtextobj.h ${DESTDIR}${includedir}/afs/gtxtextobj.h
211 ${INSTALL_DATA} ${srcdir}/gtxwindows.h ${DESTDIR}${includedir}/afs/gtxwindows.h
212 ${INSTALL_DATA} ${srcdir}/gtxX11win.h ${DESTDIR}${includedir}/afs/gtxX11win.h
215 ${INSTALL} -d ${DEST}/lib/afs
216 ${INSTALL} -d ${DEST}/include/afs
217 ${INSTALL_DATA} libgtx.a ${DEST}/lib/afs/libgtx.a
218 ${INSTALL_DATA} ${srcdir}/gtxcurseswin.h ${DEST}/include/afs/gtxcurseswin.h
219 ${INSTALL_DATA} ${srcdir}/gtxdumbwin.h ${DEST}/include/afs/gtxdumbwin.h
220 ${INSTALL_DATA} ${srcdir}/gtxframe.h ${DEST}/include/afs/gtxframe.h
221 ${INSTALL_DATA} ${srcdir}/gtxinput.h ${DEST}/include/afs/gtxinput.h
222 ${INSTALL_DATA} ${srcdir}/gtxkeymap.h ${DEST}/include/afs/gtxkeymap.h
223 ${INSTALL_DATA} ${srcdir}/gtxlightobj.h ${DEST}/include/afs/gtxlightobj.h
224 ${INSTALL_DATA} ${srcdir}/gtxobjdict.h ${DEST}/include/afs/gtxobjdict.h
225 ${INSTALL_DATA} ${srcdir}/gtxobjects.h ${DEST}/include/afs/gtxobjects.h
226 ${INSTALL_DATA} ${srcdir}/gtxtextcb.h ${DEST}/include/afs/gtxtextcb.h
227 ${INSTALL_DATA} ${srcdir}/gtxtextobj.h ${DEST}/include/afs/gtxtextobj.h
228 ${INSTALL_DATA} ${srcdir}/gtxwindows.h ${DEST}/include/afs/gtxwindows.h
229 ${INSTALL_DATA} ${srcdir}/gtxX11win.h ${DEST}/include/afs/gtxX11win.h
235 $(RM) -f *.o *.a *.ln object_test screen_test curses_test core cb_test gtxtest AFS_component_version_number.c
237 include ../config/Makefile.version