~cr3/+junk/dt

« back to all changes in this revision

Viewing changes to Makefile.qnx

  • Committer: Marc Tardif
  • Date: 2010-04-14 19:09:45 UTC
  • Revision ID: marc.tardif@canonical.com-20100414190945-op293hsog8niroma
Initial release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#
 
2
# %Z%%M% %I% %E% 1990 by Robin Miller
 
3
#
 
4
#/****************************************************************************
 
5
# *                                                                          *
 
6
# *                       COPYRIGHT (c) 1990 - 2004                          *
 
7
# *                        This Software Provided                            *
 
8
# *                                  By                                      *
 
9
# *                       Robin's Nest Software Inc.                         *
 
10
# *                                                                          *
 
11
# * Permission to use, copy, modify, distribute and sell this software and   *
 
12
# * its documentation for any purpose and without fee is hereby granted      *
 
13
# * provided that the above copyright notice appear in all copies and that   *
 
14
# * both that copyright notice and this permission notice appear in the      *
 
15
# * supporting documentation, and that the name of the author not be used    *
 
16
# * in advertising or publicity pertaining to distribution of the software   *
 
17
# * without specific, written prior permission.                              *
 
18
# *                                                                          *
 
19
# * THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,        *
 
20
# * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN      *
 
21
# * NO EVENT SHALL HE BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL   *
 
22
# * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR    *
 
23
# * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS  *
 
24
# * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF   *
 
25
# * THIS SOFTWARE.                                                           *
 
26
# *                                                                          *
 
27
# ****************************************************************************/
 
28
#
 
29
# Makefile -- makefile for program 'dt'
 
30
#       
 
31
 
 
32
# System makefile definitions for program makefiles
 
33
 
 
34
.SUFFIXES:      .ln
 
35
 
 
36
.c.ln:
 
37
                @lint -c $(LINTFLAGS) $<
 
38
 
 
39
.c~.ln:
 
40
                @echo $<
 
41
                @$(GET) -G$*.c $(GFLAGS) $<
 
42
                @lint -c $(LINTFLAGS) $*.c
 
43
                @rm -f $*.c
 
44
 
 
45
PRINTER=        lpr
 
46
 
 
47
PR_FLAGS=       -p -P28
 
48
 
 
49
TR_PRINTER=     $(PRINTER)
 
50
 
 
51
TR_FLAGS=       -t -P28
 
52
 
 
53
# Libraries the program links to which are considered volatile
 
54
 
 
55
LIBS=
 
56
 
 
57
# Libraries considered static
 
58
 
 
59
EXTLIBS=
 
60
 
 
61
LINTLIBS=
 
62
 
 
63
# P or G flag ( override on command line by invoking make PORG=-g )
 
64
 
 
65
#PORG=  -Otail -mc
 
66
#PORG=  -Otail -mf -w3
 
67
PORG=   -Otail -mf
 
68
 
 
69
AWK=    awk
 
70
CFLAGS= $(PORG) -DFIFO -DTTY -DRAND48 -D_QNX_SOURCE -D_QNX_32BIT -fi=unix.h
 
71
#CFLAGS= $(PORG) -DFIFO -DTTY -DRAND48 -D_QNX_SOURCE -D_QNX_32BIT -fi=unix.h -v 9.52
 
72
CPP=    /lib/cpp
 
73
CPPOPTS= -D_QNX_SOURCE
 
74
#CPPOPTS= -P
 
75
LDFLAGS=
 
76
 
 
77
# end of system makefile definitions
 
78
 
 
79
HDRS=           dt.h
 
80
 
 
81
### MKMF:SOURCES ###
 
82
 
 
83
CFILES=         \
 
84
                dt.c    \
 
85
                dtgen.c         \
 
86
                dtinfo.c        \
 
87
                dtread.c        \
 
88
                dtwrite.c       \
 
89
                dtstats.c       \
 
90
                dttty.c         \
 
91
                dtutil.c        \
 
92
                dtusage.c       \
 
93
                dtprocs.c       \
 
94
                dtfifo.c        \
 
95
                dttape.c
 
96
 
 
97
 
 
98
### MKMF:OBJECTS ###
 
99
 
 
100
OBJS=           ${CFILES:.c=.o}
 
101
 
 
102
 
 
103
### MKMF:LINTOBJS ###
 
104
 
 
105
LINTOBJS=       ${CFILES:.c=.ln}
 
106
 
 
107
### MKMF:TARGETS ###
 
108
 
 
109
PROGRAM=        dt
 
110
 
 
111
# system targets for program makefile
 
112
 
 
113
$(PROGRAM):     $(OBJS) $(XOBJS) $(LIBS)
 
114
                @echo -n loading $(PROGRAM) ... 
 
115
                @$(CC) -o $(PROGRAM) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) $(EXTLIBS)
 
116
                @echo done
 
117
 
 
118
print:;
 
119
                @$(PRINTER) $(PRINTFLAGS) $(CFILES)
 
120
 
 
121
prettyprint:;
 
122
                @vgrind $(CFILES) | $(TROFFPRINTER) $(TROFFPRINTERFLAGS)
 
123
 
 
124
lint:           $(LINTOBJS)
 
125
                lint $(LINTFLAGS) $(LINTOBJS) $(LINTLIBS)
 
126
                touch lint
 
127
 
 
128
clean:;
 
129
                @rm -f $(OBJS) $(PROGRAM)
 
130
 
 
131
tags:   $(CFILES) $(HDRS)
 
132
        ctags -st $(CFILES) $(HDRS)
 
133
 
 
134
# end of system targets for program makefile
 
135
 
 
136
depend: makedep
 
137
        echo '/^# DO NOT DELETE THIS LINE/+1,$$d' >eddep
 
138
        echo '$$r makedep' >>eddep
 
139
        echo 'w' >>eddep
 
140
        cp Makefile Makefile.bak
 
141
        ex - Makefile < eddep
 
142
        rm eddep makedep makedep1 makedeperrs
 
143
 
 
144
makedep: ${CFILES}
 
145
        @cat /dev/null >makedep
 
146
        -(for i in ${CFILES} ; do \
 
147
                ${CPP} -M ${CPPOPTS} $$i >> makedep; done) \
 
148
                2>makedeperrs
 
149
        sed \
 
150
                -e 's,^.*genassym\.o:,assym.s assym.L:,' \
 
151
                -e 's,^\(.*\)\.o:,\1.o \1.ln:,' makedep > makedep1
 
152
        ${AWK} ' { if ($$1 != prev) { print rec; rec = $$0; prev = $$1; } \
 
153
                else { if (length(rec $$3) > 78) { print rec; rec = $$0; } \
 
154
                       else rec = rec " " $$3 } } \
 
155
              END { print rec } ' makedep1 > makedep
 
156
        @cat makedeperrs
 
157
        @(if [ -s makedeperrs ]; then false; fi)
 
158
 
 
159
 
 
160
# DO NOT DELETE THIS LINE
 
161
 
 
162
dt.o dt.ln:     dt.c ./dt.h /usr/include/stdio.h
 
163
dt.o dt.ln:     /usr/include/float.h
 
164
dt.o dt.ln:     /usr/include/stdlib.h
 
165
dt.o dt.ln:     /usr/include/sys/types.h /usr/include/string.h
 
166
dt.o dt.ln: /usr/include/termios.h
 
167
dt.o dt.ln:     /usr/include/time.h
 
168
dt.o dt.ln:     /usr/include/unistd.h 
 
169
dt.o dt.ln:     /usr/include/errno.h
 
170
dt.o dt.ln:     /usr/include/sys/times.h 
 
171
dt.o dt.ln:     /usr/include/fcntl.h
 
172
dt.o dt.ln:     /usr/include/signal.h
 
173
dt.o dt.ln:     /usr/include/sys/wait.h 
 
174
dt.o dt.ln:     /usr/include/sys/types.h 
 
175
dt.o dt.ln:     /usr/include/signal.h
 
176
dtread.o dtread.ln:     dtread.c ./dt.h /usr/include/stdio.h
 
177
dtread.o dtread.ln:     /usr/include/float.h
 
178
dtread.o dtread.ln:     /usr/include/stdlib.h 
 
179
dtread.o dtread.ln:     /usr/include/string.h
 
180
dtread.o dtread.ln:     /usr/include/termios.h
 
181
dtread.o dtread.ln:     /usr/include/time.h 
 
182
dtread.o dtread.ln:     /usr/include/unistd.h 
 
183
dtread.o dtread.ln:     /usr/include/errno.h
 
184
dtread.o dtread.ln:     /usr/include/sys/times.h 
 
185
dtread.o dtread.ln:     /usr/include/sys/types.h
 
186
dtwrite.o dtwrite.ln:   dtwrite.c ./dt.h /usr/include/stdio.h
 
187
dtwrite.o dtwrite.ln:   /usr/include/float.h
 
188
dtwrite.o dtwrite.ln:   /usr/include/stdlib.h 
 
189
dtwrite.o dtwrite.ln:   /usr/include/string.h
 
190
dtwrite.o dtwrite.ln:   /usr/include/termios.h
 
191
dtwrite.o dtwrite.ln:   /usr/include/time.h 
 
192
dtwrite.o dtwrite.ln:   /usr/include/unistd.h 
 
193
dtwrite.o dtwrite.ln:   /usr/include/errno.h
 
194
dtwrite.o dtwrite.ln:   /usr/include/sys/times.h 
 
195
dtwrite.o dtwrite.ln:   /usr/include/sys/types.h
 
196
dtstats.o dtstats.ln:   dtstats.c ./dt.h /usr/include/stdio.h
 
197
dtstats.o dtstats.ln:   /usr/include/float.h
 
198
dtstats.o dtstats.ln:   /usr/include/stdlib.h 
 
199
dtstats.o dtstats.ln:   /usr/include/string.h
 
200
dtstats.o dtstats.ln:   /usr/include/termios.h
 
201
dtstats.o dtstats.ln:   /usr/include/time.h 
 
202
dtstats.o dtstats.ln:   /usr/include/unistd.h 
 
203
dtstats.o dtstats.ln:   /usr/include/errno.h
 
204
dtstats.o dtstats.ln:   /usr/include/sys/times.h 
 
205
dtstats.o dtstats.ln:   /usr/include/sys/types.h
 
206
dttty.o dttty.ln:       dttty.c ./dt.h /usr/include/stdio.h 
 
207
dttty.o dttty.ln:       /usr/include/float.h
 
208
dttty.o dttty.ln:       /usr/include/stdlib.h 
 
209
dttty.o dttty.ln:       /usr/include/string.h
 
210
dttty.o dttty.ln:       /usr/include/termios.h
 
211
dttty.o dttty.ln:       /usr/include/time.h 
 
212
dttty.o dttty.ln:       /usr/include/unistd.h 
 
213
dttty.o dttty.ln:       /usr/include/errno.h
 
214
dttty.o dttty.ln:       /usr/include/sys/times.h 
 
215
dttty.o dttty.ln:       /usr/include/sys/types.h
 
216
dtutil.o dtutil.ln:     dtutil.c ./dt.h /usr/include/stdio.h
 
217
dtutil.o dtutil.ln:     /usr/include/float.h
 
218
dtutil.o dtutil.ln:     /usr/include/stdlib.h 
 
219
dtutil.o dtutil.ln:     /usr/include/string.h
 
220
dtutil.o dtutil.ln:     /usr/include/termios.h
 
221
dtutil.o dtutil.ln:     /usr/include/time.h 
 
222
dtutil.o dtutil.ln:     /usr/include/unistd.h 
 
223
dtutil.o dtutil.ln:     /usr/include/errno.h
 
224
dtutil.o dtutil.ln:     /usr/include/sys/times.h 
 
225
dtutil.o dtutil.ln:     /usr/include/fcntl.h
 
226
dtutil.o dtutil.ln:     /usr/include/malloc.h
 
227
dtutil.o dtutil.ln:     /usr/include/sys/stat.h 
 
228
dtutil.o dtutil.ln:     /usr/include/sys/types.h 
 
229
dtusage.o dtusage.ln:   dtusage.c ./dt.h /usr/include/stdio.h
 
230
dtusage.o dtusage.ln:   /usr/include/float.h
 
231
dtusage.o dtusage.ln:   /usr/include/stdlib.h 
 
232
dtusage.o dtusage.ln:   /usr/include/sys/types.h /usr/include/string.h
 
233
dtusage.o dtusage.ln:   /usr/include/termios.h
 
234
dtusage.o dtusage.ln:   /usr/include/time.h 
 
235
dtusage.o dtusage.ln:   /usr/include/unistd.h 
 
236
dtusage.o dtusage.ln:   /usr/include/errno.h
 
237
dtusage.o dtusage.ln:   /usr/include/sys/times.h 
 
238
dtusage.o dtusage.ln:   /usr/include/sys/types.h