|
|
1.1 root 1: # @(#)makefile 1.4
2: #
3: # Curses Library Low Level Makefile
4: #
5: # CFLAGS has -DVIDEO & -DKEYPAD for the libcurses.a library. They could
6: # be put into a separate variable if desired, but I saw no reason
7: # for doing so.
8: # DFLAGS, TFLAGS, & PFLAGS are for debugging, tracing, & profiling
9: # respectively. They all contain the DEBUG flag because it is
10: # thought that any of the styles of compiling is still debugging.
11: # Also the DEBUG flag will create very large files and it is not
12: # recommended that all of the files be compiled with the DEBUG
13: # flag defined. This will make 'ar' die because the library will
14: # exceed 2065 blocks in size. But I see no reason not to compile
15: # individual or groups of files with these flags defined. These
16: # flags can't be used on a pdp11/70 or other small machines
17: # because of the huge sizes of .o files produced for the library.
18: # FILES is used for the naming of the object files.
19: # O is used to destinguish between compiling, debugging, tracing, &
20: # profiling.
21: # MINICURSES is a flag used to compile a small version of libcurses.
22: # It should not be used for the compiling of libcurses.a. It is
23: # strictly for the application programmers convenience.
24: # If MINICURSES is desired with ti4 or show then type:
25: # "make <[ti4][show] MINICURSES=-DMINICURSES"
26: #
27: ROOT =
28: INCLUDE = $(ROOT)/usr/include
29: LIB = $(ROOT)/usr/lib
30: CURSES = libcurses.a
31: BIN = $(ROOT)/usr/bin
32: O = o
33: MINICURSES =
34: CFLAGS = -DVIDEO -DKEYPAD -O
35: DFLAGS = -DVIDEO -DKEYPAD -DDEBUG -I.
36: TFLAGS = -DVIDEO -DKEYPAD -DDEBUG -O -I.
37: PFLAGS = -DVIDEO -DKEYPAD -DDEBUG -p -O -I.
38: FILES = __cflush.$(O) __sscans.$(O) _blanks.$(O) _c_clean.$(O) \
39: _clearhl.$(O) _clearline.$(O) _comphash.$(O) _delay.$(O) \
40: _delchars.$(O) _dellines.$(O) _dumpwin.$(O) _ec_quit.$(O) \
41: _fixdelay.$(O) _forcehl.$(O) _hlmode.$(O) _id_char.$(O) \
42: _init_cost.$(O) _inschars.$(O) _insmode.$(O) _kpmode.$(O) \
43: _line_free.$(O) _ll_move.$(O) _outch.$(O) _outchar.$(O) \
44: _pos.$(O) _reset.$(O) _scrdown.$(O) _scrollf.$(O) _sethl.$(O) \
45: _setmode.$(O) _setwind.$(O) _shove.$(O) _sprintw.$(O) \
46: _sputc.$(O) _syncmodes.$(O) _tscroll.$(O) _window.$(O) \
47: addch.$(O) addstr.$(O) baudrate.$(O) beep.$(O) box.$(O) \
48: capnames.$(O) cbreak.$(O) chktypeahd.$(O) clear.$(O) \
49: clearok.$(O) clreolinln.$(O) clrtobot.$(O) clrtoeol.$(O) \
50: cntcostfn.$(O) crmode.$(O) curses.$(O) def_prog.$(O) \
51: def_shell.$(O) delayoutpt.$(O) delch.$(O) deleteln.$(O) \
52: delwin.$(O) doprnt.$(O) doscan.$(O) doupdate.$(O) draino.$(O) \
53: echo.$(O) endwin.$(O) erase.$(O) erasechar.$(O) fixterm.$(O) \
54: flash.$(O) flushinp.$(O) getch.$(O) getstr.$(O) idlok.$(O) \
55: gettmode.$(O) has_ic.$(O) has_il.$(O) idln.getst.$(O) \
56: initkeypad.$(O) initscr.$(O) insch.$(O) insertln.$(O) \
57: intrflush.$(O) keypad.$(O) killchar.$(O) leaveok.$(O) \
58: line_alloc.$(O) ll_refresh.$(O) longname.$(O) m_addch.$(O) \
59: m_addstr.$(O) m_clear.$(O) m_erase.$(O) m_move.$(O) meta.$(O) \
60: m_refresh.$(O) m_tstp.$(O) makenew.$(O) miniinit.$(O) \
61: move.$(O) mvcur.$(O) mvprintw.$(O) mvscanw.$(O) mvwin.$(O) \
62: mvwprintw.$(O) mvwscanw.$(O) naps.$(O) newpad.$(O) \
63: newterm.$(O) newwin.$(O) nl.$(O) nocbreak.$(O) nocrmode.$(O) \
64: nodelay.$(O) noecho.$(O) nonl.$(O) noraw.$(O) nttychktrm.$(O) \
65: overlay.$(O) overwrite.$(O) pnoutrfrsh.$(O) prefresh.$(O) \
66: printw.$(O) putp.$(O) raw.$(O) reset_prog.$(O) resetshell.$(O) \
67: resetterm.$(O) resetty.$(O) restarttrm.$(O) saveterm.$(O) \
68: savetty.$(O) scanw.$(O) scroll.$(O) scrollok.$(O) select.$(O) \
69: set_term.$(O) setbuffred.$(O) setterm.$(O) setupterm.$(O) \
70: showstring.$(O) subwin.$(O) tgetent.$(O) tgetflag.$(O) \
71: tgetnum.$(O) tgetstr.$(O) tgoto.$(O) touchwin.$(O) tparm.$(O) \
72: tputs.$(O) traceonoff.$(O) tstp.$(O) two.twostr.$(O) \
73: typeahead.$(O) unctrl.$(O) vidattr.$(O) vidputs.$(O) \
74: vsprintf.$(O) vsscanf.$(O) wattroff.$(O) wattron.$(O) \
75: wattrset.$(O) wnoutrfrsh.$(O) wprintw.$(O) wrefresh.$(O) \
76: writechars.$(O) wscanw.$(O) wstandend.$(O) wstandout.$(O)
77:
78: .SUFFIXES: .o .d .t .p
79:
80: .c.o:
81: $(CC) $(CFLAGS) $(MINICURSES) -c $*.c
82:
83: .c.d:
84: if [ -f $*.o ] ; then mv $*.o tmp ; fi
85: $(CC) $(DFLAGS) $(MINICURSES) -c $*.c
86: mv $*.o $*.d
87: if [ -f tmp ] ; then mv tmp $*.o
88: .c.t:
89: if [ -f $*.o ] ; then mv $*.o tmp ; fi
90: $(CC) $(TFLAGS) $(MINICURSES) -c $*.c
91: mv $*.o $*.d
92: if [ -f tmp ] ; then mv tmp $*.o
93:
94: .c.p:
95: if [ -f $*.o ] ; then mv $*.o tmp ; fi
96: $(CC) $(PFLAGS) $(MINICURSES) -c $*.c
97: mv $*.o $*.d
98: if [ -f tmp ] ; then mv tmp $*.o
99:
100: all: $(CURSES)
101:
102: $(CURSES): $(FILES) curses.h curshdr.h term.h unctrl.h curses.ext curses.c
103: ar rv $(CURSES) `lorder *.$(O) | tsort`
104:
105: debug:
106: $(MAKE) O=d CURSES=libdcurses.a
107:
108: trace:
109: $(MAKE) O=t CURSES=libtcurses.a
110:
111: profile:
112: $(MAKE) O=p CURSES=libpcurses.a
113:
114: show: libcurses.a show.o
115: $(CC) $(CFLAGS) $(MINICURSES) show.o libcurses.a -o show
116: /bin/rm show.o
117:
118: tic: tic.o capnames.o
119: -if pdp11; \
120: then \
121: cc -i $(CFLAGS) $(MINICURSES) tic.o capnames.o -o tic; \
122: /bin/rm tic.o; \
123: else \
124: cc $(CFLAGS) -DL_ctermid $(MINICURSES) tic.o capnames.o -o tic; \
125: /bin/rm tic.o; \
126: fi
127:
128: ti4: libcurses.a ti4.o
129: cc $(CFLAGS) $(MINICURSES) ti4$(O) libcurses.a -o ti4
130: /bin/rm ti4.o
131:
132: ti4.o:
133: cc mkti4.c -O -o mkti4
134: mkti4 >ti4.c
135: cc $(CFLAGS) $(MINICURSES) ti4.c -O -c
136:
137: clean:
138: /bin/rm -f *.o
139:
140: clobber: clean
141: /bin/rm -f libcurses.a tic
142:
143: install: libcurses.a tic
144: cp libcurses.a $(LIB)/libcurses.a
145: cp tic $(BIN)/tic
146: chmod 775 $(BIN)/tic
147: chmod 664 $(LIB)/libcurses.a
148: chgrp bin $(BIN)/tic $(LIB)/libcurses.a
149: chown bin $(BIN)/tic $(LIB)/libcurses.a
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.