Commit | Line | Data |
---|---|---|
eb02fd64 | 1 | # |
131a3881 | 2 | # Makefile for directory with subdirs to build. |
7fcfdcf7 | 3 | # Copyright (C) 1990, 1991, 1992 Free Software Foundation |
eb02fd64 | 4 | # |
4dfe09da RP |
5 | # This file is free software; you can redistribute it and/or modify |
6 | # it under the terms of the GNU General Public License as published by | |
7 | # the Free Software Foundation; either version 2 of the License, or | |
8 | # (at your option) any later version. | |
9 | # | |
10 | # This program is distributed in the hope that it will be useful, | |
11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
13 | # GNU General Public License for more details. | |
14 | # | |
15 | # You should have received a copy of the GNU General Public License | |
16 | # along with this program; if not, write to the Free Software | |
17 | # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ | |
18 | # | |
f149eb99 | 19 | |
eb02fd64 | 20 | srcdir = . |
28f3b094 | 21 | |
4d714963 | 22 | prefix = /usr/local |
eb02fd64 | 23 | |
7fcfdcf7 SC |
24 | exec_prefix = $(prefix) |
25 | bindir = $(exec_prefix)/bin | |
26 | libdir = $(exec_prefix)/lib | |
2198e4ba | 27 | tooldir = $(libdir) |
7fcfdcf7 | 28 | |
4d714963 | 29 | datadir = $(prefix)/lib |
7fcfdcf7 | 30 | mandir = $(prefix)/man |
4d714963 RP |
31 | man1dir = $(mandir)/man1 |
32 | man2dir = $(mandir)/man2 | |
33 | man3dir = $(mandir)/man3 | |
34 | man4dir = $(mandir)/man4 | |
35 | man5dir = $(mandir)/man5 | |
36 | man6dir = $(mandir)/man6 | |
37 | man7dir = $(mandir)/man7 | |
38 | man8dir = $(mandir)/man8 | |
39 | man9dir = $(mandir)/man9 | |
7fcfdcf7 | 40 | infodir = $(prefix)/info |
4d714963 RP |
41 | includedir = $(prefix)/include |
42 | docdir = $(datadir)/doc | |
43 | ||
44 | SHELL = /bin/sh | |
45 | ||
46 | INSTALL = install -c | |
47 | INSTALL_PROGRAM = $(INSTALL) | |
48 | INSTALL_DATA = $(INSTALL) | |
3c8735af | 49 | |
ec342d7d | 50 | AR = ar |
ba8abfce | 51 | AR_FLAGS = qc |
f8a6ad66 | 52 | CFLAGS = -g |
4d714963 | 53 | RANLIB = ranlib |
eb02fd64 | 54 | |
98a33b6d | 55 | BISON = `if [ -f $${rootme}/byacc/byacc ] ; \ |
06a07944 RP |
56 | then echo $${rootme}/byacc/byacc ; \ |
57 | else echo bison -y ; \ | |
06a07944 | 58 | fi` |
2645fb0c | 59 | |
98a33b6d | 60 | LEX = `if [ -f $${rootme}/flex/flex ] ; \ |
8b361a95 | 61 | then echo $${rootme}/flex/flex ; \ |
2198e4ba MT |
62 | else echo flex ; fi` |
63 | ||
98a33b6d | 64 | MAKEINFO = `if [ -f $${rootme}/texinfo/C/makeinfo ] ; \ |
77806c3e RP |
65 | then echo $${rootme}/texinfo/C/makeinfo ; \ |
66 | else echo makeinfo ; fi` | |
b772d75e | 67 | |
868ebe79 | 68 | SUBDIRS = libiberty mmalloc glob readline opcodes bfd gdb binutils opcodes ld gas tgas gcc libg++ newlib libm # clib -- newlib replaces |
6a3958b2 RP |
69 | OTHERS = |
70 | ||
a0f47eb7 | 71 | ALL = all.normal |
b26ff9d8 | 72 | INSTALL_TARGET = install.all |
fb660409 RP |
73 | |
74 | ### for debugging | |
75 | #GCCVERBOSE=-v | |
76 | ||
98a33b6d | 77 | GXX = `if [ -f $${rootme}/gcc/gcc ] ; \ |
f0e9ba1e PB |
78 | then echo $${rootme}/gcc/gcc -B$${rootme}/gcc/ ; \ |
79 | else echo gcc ; fi` | |
80 | ||
98a33b6d | 81 | XTRAFLAGS = `if [ -f $${rootme}/gcc/gcc ] ; \ |
f0e9ba1e PB |
82 | then echo -I$${rootme}/gcc/include ; \ |
83 | else echo ; fi` | |
23e3e7f9 | 84 | |
eb02fd64 | 85 | #### host and target specific makefile fragments come in here. |
ec342d7d | 86 | ### |
eb02fd64 | 87 | |
2198e4ba MT |
88 | FLAGS_TO_PASS = \ |
89 | "prefix=$(prefix)" \ | |
90 | "exec_prefix=$(exec_prefix)" \ | |
91 | "tooldir=$(tooldir)" \ | |
92 | "AR=$(AR)" \ | |
93 | "AR_FLAGS=$(AR_FLAGS)" \ | |
94 | "CC=$(CC)" \ | |
95 | "CFLAGS=$(CFLAGS)" \ | |
96 | "RANLIB=$(RANLIB)" \ | |
97 | "LOADLIBES=$(LOADLIBES)" \ | |
98 | "LDFLAGS=$(LDFLAGS)" \ | |
99 | "BISON=$(BISON)" \ | |
100 | "LEX=$(LEX)" \ | |
101 | "MAKEINFO=$(MAKEINFO)" \ | |
102 | "INSTALL=$(INSTALL)" \ | |
103 | "INSTALL_DATA=$(INSTALL_DATA)" \ | |
104 | "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" | |
105 | ||
4d714963 | 106 | .PHONY: all info install-info clean-info |
f8a6ad66 | 107 | .NOEXPORT: |
4d714963 | 108 | |
a0f47eb7 | 109 | all: $(ALL) |
4d714963 | 110 | |
98a33b6d DZ |
111 | info: |
112 | @rootme=`pwd` ; export rootme ; $(MAKE) $(FLAGS_TO_PASS) subdir_do DO=info "DODIRS=$(SUBDIRS)" | |
c5f94070 | 113 | |
2198e4ba MT |
114 | # Note libg++ has to be handled specially (we can't compile it with CC=cc). |
115 | check: | |
98a33b6d DZ |
116 | @rootme=`pwd` ; export rootme ; $(MAKE) $(FLAGS_TO_PASS) subdir_do DO=check \ |
117 | "DODIRS=`echo $(SUBDIRS) | sed -e \"s/libg\+\+//\"" | |
118 | @rootme=`pwd` ; export rootme ; $(MAKE) $(FLAGS_TO_PASS) subdir_do DO=check \ | |
119 | "DODIRS=libg++" "CC=${GXX}" "XTRAFLAGS=${XTRAFLAGS}" | |
7fcfdcf7 | 120 | |
25113b46 | 121 | clean-info: |
06a07944 | 122 | @$(MAKE) $(FLAGS_TO_PASS) subdir_do DO=clean-info "DODIRS=$(SUBDIRS)" |
98a33b6d | 123 | |
9a9e8e7f | 124 | install-info: install-info-dirs force |
8b361a95 SEF |
125 | -parent=`echo $(infodir)|sed -e 's@/[^/]*$$@@'`; \ |
126 | if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi | |
127 | -if [ -d $(infodir) ] ; then true ; else mkdir $(infodir) ; fi | |
06a07944 | 128 | @$(MAKE) $(FLAGS_TO_PASS) subdir_do DO=install-info "DODIRS=$(SUBDIRS)" |
06a07944 | 129 | @$(MAKE) $(FLAGS_TO_PASS) dir.info install-dir.info |
9a9e8e7f RP |
130 | |
131 | install-dir.info: | |
8b361a95 SEF |
132 | -parent=`echo $(infodir)|sed -e 's@/[^/]*$$@@'`; \ |
133 | if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi | |
134 | -if [ -d $(infodir) ] ; then true ; else mkdir $(infodir) ; fi | |
9a9e8e7f | 135 | $(INSTALL_DATA) dir.info $(infodir)/dir.info |
4d714963 | 136 | |
618f57a9 | 137 | all.normal: all-autoconf all-libiberty all-mmalloc all-texinfo \ |
868ebe79 MW |
138 | all-byacc all-flex all-opcodes all-bfd all-ld all-gas all-tgas \ |
139 | all-gcc all-binutils all-libg++ all-readline all-gdb \ | |
c4fb14b7 | 140 | all-make all-rcs all-cvs all-diff all-grep \ |
98a33b6d | 141 | all-patch all-emacs all-ispell all-etc \ |
06a07944 | 142 | all-newlib all-gprof all-send_pr all-libm |
dcbfc14d | 143 | |
dfa891fc | 144 | all.cross: all-libiberty all-mmalloc all-gas all-byacc all-flex all-ld \ |
868ebe79 | 145 | all-opcodes all-bfd all-readline all-gdb all-binutils all-gcc \ |
aa06ff7e | 146 | all-newlib |
06a07944 | 147 | # $(MAKE) $(FLAGS_TO_PASS) subdir_do DO=all "DODIRS=$(SUBDIRS) $(OTHERS)" |
4d714963 | 148 | |
618f57a9 RP |
149 | clean: clean-autoconf clean-libiberty clean-mmalloc clean-texinfo \ |
150 | clean-bfd clean-newlib clean-binutils clean-flex \ | |
aa06ff7e | 151 | clean-byacc clean-ld clean-gas clean-etc clean-opcodes \ |
dfa891fc | 152 | clean-gcc clean-readline clean-glob clean-gdb \ |
c4fb14b7 | 153 | clean-make clean-diff clean-grep clean-rcs \ |
2198e4ba | 154 | clean-cvs clean-patch clean-emacs clean-ispell \ |
06a07944 | 155 | clean-libg++ clean-gprof clean-send_pr clean-libm |
7fcfdcf7 SC |
156 | -rm -rf *.a TEMP errs core *.o *~ \#* TAGS *.E |
157 | ||
158 | clean-stamps: | |
c4fb14b7 | 159 | -rm -f all-* |
4d714963 | 160 | |
98a33b6d | 161 | install: $(INSTALL_TARGET) |
8b361a95 SEF |
162 | -parent=`echo $(man1dir)|sed -e 's@/[^/]*$$@@'`; \ |
163 | if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi | |
164 | -if [ -d $(man1dir) ] ; then true ; else mkdir $(man1dir) ; fi | |
b26ff9d8 | 165 | |
06a07944 RP |
166 | install.all: install-no-fixedincludes |
167 | @if [ -f ./gcc/Makefile ] ; then \ | |
168 | rootme=`pwd` ; export rootme ; \ | |
169 | (cd ./gcc; \ | |
170 | $(MAKE) $(FLAGS_TO_PASS) install-headers) ; \ | |
171 | else \ | |
172 | true ; \ | |
173 | fi | |
174 | ||
dfa891fc DZ |
175 | install-no-fixedincludes: install-dirs gcc-no-fixedincludes \ |
176 | install-autoconf \ | |
177 | install-bfd \ | |
178 | install-binutils \ | |
aa06ff7e | 179 | install-opcodes \ |
dfa891fc DZ |
180 | install-byacc \ |
181 | install-cvs \ | |
182 | install-diff \ | |
183 | install-emacs \ | |
98a33b6d | 184 | install-etc \ |
dfa891fc DZ |
185 | install-flex \ |
186 | install-gas \ | |
187 | install-gdb \ | |
188 | install-glob \ | |
189 | install-gprof \ | |
190 | install-grep \ | |
191 | install-ispell \ | |
192 | install-ld \ | |
193 | install-libg++ \ | |
194 | install-libiberty \ | |
195 | install-libm \ | |
196 | install-make \ | |
197 | install-mmalloc \ | |
198 | install-newlib \ | |
199 | install-patch \ | |
200 | install-rcs \ | |
201 | install-readline \ | |
202 | install-send_pr \ | |
203 | install-texinfo | |
204 | ||
06a07944 RP |
205 | gcc-no-fixedincludes: |
206 | @if [ -f ./gcc/Makefile ] ; then \ | |
207 | rootme=`pwd` ; export rootme ; \ | |
208 | (cd ./gcc; \ | |
209 | $(MAKE) $(FLAGS_TO_PASS) install install-man \ | |
210 | "INSTALL_HEADERS=install-common-headers install-float-h install-limits-h") ; \ | |
211 | else \ | |
212 | true ; \ | |
213 | fi | |
dcbfc14d DZ |
214 | |
215 | install.cross: install-dirs install-libiberty install-mmalloc \ | |
aa06ff7e | 216 | install-binutils install-opcodes install-byacc install-flex \ |
dfa891fc DZ |
217 | install-ld install-gas install-readline \ |
218 | install-glob install-gdb install-mmalloc \ | |
98a33b6d | 219 | install-newlib install-gcc install-etc |
23e3e7f9 | 220 | |
618f57a9 RP |
221 | ### autoconf |
222 | all-autoconf: force | |
a5cdd8af | 223 | @if [ -f ./autoconf/Makefile ] ; then \ |
618f57a9 | 224 | rootme=`pwd` ; export rootme ; \ |
a5cdd8af | 225 | (cd ./autoconf; $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
618f57a9 RP |
226 | else \ |
227 | true ; \ | |
228 | fi | |
229 | ||
230 | clean-autoconf: force | |
06a07944 | 231 | @if [ -f ./autoconf/Makefile ] ; then \ |
618f57a9 | 232 | rootme=`pwd` ; export rootme ; \ |
98a33b6d | 233 | (cd ./autoconf; $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
618f57a9 RP |
234 | else \ |
235 | true ; \ | |
236 | fi | |
237 | ||
238 | install-autoconf: force | |
06a07944 | 239 | @if [ -f ./autoconf/Makefile ] ; then \ |
618f57a9 | 240 | rootme=`pwd` ; export rootme ; \ |
98a33b6d DZ |
241 | (cd ./autoconf; $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
242 | else \ | |
243 | true ; \ | |
244 | fi | |
245 | ||
246 | ### etc | |
247 | all-etc: force | |
248 | @if [ -f ./etc/Makefile ] ; then \ | |
249 | rootme=`pwd` ; export rootme ; \ | |
250 | (cd ./etc; $(MAKE) $(FLAGS_TO_PASS) all) ; \ | |
251 | else \ | |
252 | true ; \ | |
253 | fi | |
254 | ||
255 | clean-etc: force | |
256 | @if [ -f ./etc/Makefile ] ; then \ | |
257 | rootme=`pwd` ; export rootme ; \ | |
258 | (cd ./etc; $(MAKE) $(FLAGS_TO_PASS) clean) ; \ | |
259 | else \ | |
260 | true ; \ | |
261 | fi | |
262 | ||
263 | install-etc: force | |
264 | @if [ -f ./etc/Makefile ] ; then \ | |
265 | rootme=`pwd` ; export rootme ; \ | |
266 | (cd ./etc; $(MAKE) $(FLAGS_TO_PASS) install) ; \ | |
618f57a9 RP |
267 | else \ |
268 | true ; \ | |
269 | fi | |
270 | ||
4d714963 | 271 | ### libiberty |
c4fb14b7 | 272 | all-libiberty: force |
06a07944 | 273 | @if [ -f ./libiberty/Makefile ] ; then \ |
77806c3e | 274 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 275 | (cd ./libiberty; \ |
2198e4ba | 276 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
277 | else \ |
278 | true ; \ | |
279 | fi | |
4d714963 RP |
280 | |
281 | clean-libiberty: force | |
06a07944 | 282 | @if [ -f ./libiberty/Makefile ] ; then \ |
77806c3e | 283 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 284 | (cd ./libiberty; \ |
2198e4ba | 285 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
286 | else \ |
287 | true ; \ | |
288 | fi | |
4d714963 RP |
289 | |
290 | install-libiberty: force | |
06a07944 | 291 | @if [ -f ./libiberty/Makefile ] ; then \ |
77806c3e | 292 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 293 | (cd ./libiberty; \ |
2198e4ba | 294 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
295 | else \ |
296 | true ; \ | |
297 | fi | |
23e3e7f9 | 298 | |
66cfe047 | 299 | ### mmalloc |
c4fb14b7 | 300 | all-mmalloc: force |
06a07944 | 301 | @if [ -f ./mmalloc/Makefile ] ; then \ |
66cfe047 SG |
302 | rootme=`pwd` ; export rootme ; \ |
303 | (cd ./mmalloc; \ | |
2198e4ba | 304 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
66cfe047 SG |
305 | else \ |
306 | true ; \ | |
307 | fi | |
66cfe047 SG |
308 | |
309 | clean-mmalloc: force | |
06a07944 | 310 | @if [ -f ./mmalloc/Makefile ] ; then \ |
66cfe047 SG |
311 | rootme=`pwd` ; export rootme ; \ |
312 | (cd ./mmalloc; \ | |
2198e4ba | 313 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
66cfe047 SG |
314 | else \ |
315 | true ; \ | |
316 | fi | |
317 | ||
318 | install-mmalloc: force | |
06a07944 | 319 | @if [ -f ./mmalloc/Makefile ] ; then \ |
66cfe047 SG |
320 | rootme=`pwd` ; export rootme ; \ |
321 | (cd ./mmalloc; \ | |
2198e4ba | 322 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
66cfe047 SG |
323 | else \ |
324 | true ; \ | |
325 | fi | |
326 | ||
4d714963 | 327 | ### texinfo |
c4fb14b7 | 328 | all-texinfo: all-libiberty |
06a07944 | 329 | @if [ -f ./texinfo/Makefile ] ; then \ |
77806c3e RP |
330 | rootme=`pwd` ; export rootme ; \ |
331 | rootme=`pwd` ; export rootme ; \ | |
7fcfdcf7 | 332 | (cd ./texinfo; \ |
2198e4ba | 333 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
334 | else \ |
335 | true ; \ | |
336 | fi | |
4d714963 RP |
337 | |
338 | clean-texinfo: force | |
06a07944 | 339 | @if [ -f ./texinfo/Makefile ] ; then \ |
77806c3e | 340 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 341 | (cd ./texinfo; \ |
2198e4ba | 342 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
343 | else \ |
344 | true ; \ | |
345 | fi | |
4d714963 RP |
346 | |
347 | install-texinfo: force | |
06a07944 | 348 | @if [ -f ./texinfo/Makefile ] ; then \ |
77806c3e | 349 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 350 | (cd ./texinfo; \ |
2198e4ba | 351 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
352 | else \ |
353 | true ; \ | |
354 | fi | |
23e3e7f9 | 355 | |
4d714963 | 356 | ### bfd |
c4fb14b7 | 357 | all-bfd: force |
06a07944 | 358 | @if [ -f ./bfd/Makefile ] ; then \ |
77806c3e | 359 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 360 | (cd ./bfd; \ |
2198e4ba | 361 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
362 | else \ |
363 | true ; \ | |
364 | fi | |
4d714963 RP |
365 | |
366 | clean-bfd: force | |
06a07944 | 367 | @if [ -f ./bfd/Makefile ] ; then \ |
77806c3e | 368 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 369 | (cd ./bfd; \ |
2198e4ba | 370 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
371 | else \ |
372 | true ; \ | |
373 | fi | |
4d714963 RP |
374 | |
375 | install-bfd: force | |
06a07944 | 376 | @if [ -f ./bfd/Makefile ] ; then \ |
77806c3e | 377 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 378 | (cd ./bfd; \ |
2198e4ba | 379 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
380 | else \ |
381 | true ; \ | |
382 | fi | |
23e3e7f9 | 383 | |
aa06ff7e SC |
384 | |
385 | ### opcodes | |
386 | all-opcodes: force | |
387 | @if [ -f ./opcodes/Makefile ] ; then \ | |
388 | rootme=`pwd` ; export rootme ; \ | |
389 | (cd ./bfd; \ | |
390 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ | |
391 | else \ | |
392 | true ; \ | |
393 | fi | |
394 | ||
395 | clean-opcodes: force | |
396 | @if [ -f ./opcodes/Makefile ] ; then \ | |
397 | rootme=`pwd` ; export rootme ; \ | |
398 | (cd ./bfd; \ | |
399 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ | |
400 | else \ | |
401 | true ; \ | |
402 | fi | |
403 | ||
404 | install-opcodes: force | |
405 | @if [ -f ./opcodes/Makefile ] ; then \ | |
406 | rootme=`pwd` ; export rootme ; \ | |
407 | (cd ./bfd; \ | |
408 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ | |
409 | else \ | |
410 | true ; \ | |
411 | fi | |
412 | ||
4d714963 | 413 | ### binutils |
aa06ff7e | 414 | all-binutils: all-opcodes all-libiberty all-bfd all-flex |
06a07944 | 415 | @if [ -f ./binutils/Makefile ] ; then \ |
77806c3e | 416 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 417 | (cd ./binutils; \ |
2198e4ba | 418 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
419 | else \ |
420 | true ; \ | |
421 | fi | |
4d714963 RP |
422 | |
423 | clean-binutils: force | |
06a07944 | 424 | @if [ -f ./binutils/Makefile ] ; then \ |
77806c3e | 425 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 426 | (cd ./binutils; \ |
2198e4ba | 427 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
428 | else \ |
429 | true ; \ | |
430 | fi | |
4d714963 RP |
431 | |
432 | install-binutils: force | |
06a07944 | 433 | @if [ -f ./binutils/Makefile ] ; then \ |
77806c3e | 434 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 435 | (cd ./binutils; \ |
2198e4ba | 436 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
7fcfdcf7 SC |
437 | else \ |
438 | true ; \ | |
439 | fi | |
440 | ||
441 | ### newlib | |
c4fb14b7 | 442 | all-newlib: force |
06a07944 | 443 | @if [ -f ./newlib/Makefile ] ; then \ |
7fcfdcf7 SC |
444 | rootme=`pwd` ; export rootme ; \ |
445 | (cd ./newlib; \ | |
2198e4ba | 446 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
7fcfdcf7 SC |
447 | else \ |
448 | true ; \ | |
449 | fi | |
7fcfdcf7 SC |
450 | |
451 | clean-newlib: force | |
06a07944 | 452 | @if [ -f ./newlib/Makefile ] ; then \ |
7fcfdcf7 SC |
453 | rootme=`pwd` ; export rootme ; \ |
454 | (cd ./newlib; \ | |
2198e4ba | 455 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
7fcfdcf7 SC |
456 | else \ |
457 | true ; \ | |
458 | fi | |
459 | ||
460 | install-newlib: force | |
06a07944 | 461 | @if [ -f ./newlib/Makefile ] ; then \ |
7fcfdcf7 SC |
462 | rootme=`pwd` ; export rootme ; \ |
463 | (cd ./newlib; \ | |
06a07944 | 464 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
465 | else \ |
466 | true ; \ | |
467 | fi | |
23e3e7f9 | 468 | |
9a14a29d | 469 | ### gprof |
c4fb14b7 | 470 | all-gprof: all-libiberty all-bfd |
06a07944 RP |
471 | @if [ -f ./gprof/Makefile ] ; then \ |
472 | (cd gprof; $(MAKE) $(FLAGS_TO_PASS) all) ; \ | |
9a14a29d SEF |
473 | else \ |
474 | true ; \ | |
475 | fi | |
9a14a29d SEF |
476 | |
477 | clean-gprof: force | |
06a07944 RP |
478 | @if [ -f ./gprof/Makefile ] ; then \ |
479 | (cd gprof; $(MAKE) $(FLAGS_TO_PASS) clean) ; \ | |
9a14a29d SEF |
480 | else \ |
481 | true ; \ | |
482 | fi | |
483 | ||
484 | install-gprof: force | |
06a07944 RP |
485 | @if [ -f ./gprof/Makefile ] ; then \ |
486 | (cd gprof; $(MAKE) $(FLAGS_TO_PASS) install) ; \ | |
9a14a29d SEF |
487 | else \ |
488 | true ; \ | |
489 | fi | |
490 | ||
4d714963 | 491 | ### byacc |
c4fb14b7 | 492 | all-byacc: force |
06a07944 | 493 | @if [ -f ./byacc/Makefile ] ; then \ |
77806c3e | 494 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 495 | (cd ./byacc; \ |
2198e4ba | 496 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
497 | else \ |
498 | true ; \ | |
499 | fi | |
4d714963 RP |
500 | |
501 | clean-byacc: force | |
06a07944 | 502 | @if [ -f ./byacc/Makefile ] ; then \ |
77806c3e | 503 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 504 | (cd ./byacc; \ |
2198e4ba | 505 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
506 | else \ |
507 | true ; \ | |
508 | fi | |
4d714963 RP |
509 | |
510 | install-byacc: force | |
06a07944 | 511 | @if [ -f ./byacc/Makefile ] ; then \ |
77806c3e | 512 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 513 | (cd ./byacc; \ |
2198e4ba | 514 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
515 | else \ |
516 | true ; \ | |
517 | fi | |
23e3e7f9 | 518 | |
dcbfc14d | 519 | ### flex |
2198e4ba | 520 | all-flex: all-libiberty |
06a07944 | 521 | @if [ -f ./flex/Makefile ] ; then \ |
dcbfc14d DZ |
522 | rootme=`pwd` ; export rootme ; \ |
523 | (cd ./flex; \ | |
2198e4ba | 524 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
dcbfc14d DZ |
525 | else \ |
526 | true ; \ | |
527 | fi | |
528 | ||
529 | clean-flex: force | |
06a07944 | 530 | @if [ -f ./flex/Makefile ] ; then \ |
dcbfc14d DZ |
531 | rootme=`pwd` ; export rootme ; \ |
532 | (cd ./flex; \ | |
2198e4ba | 533 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
dcbfc14d DZ |
534 | else \ |
535 | true ; \ | |
536 | fi | |
537 | ||
538 | install-flex: force | |
06a07944 | 539 | @if [ -f ./flex/Makefile ] ; then \ |
dcbfc14d DZ |
540 | rootme=`pwd` ; export rootme ; \ |
541 | (cd ./flex; \ | |
2198e4ba | 542 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
dcbfc14d DZ |
543 | else \ |
544 | true ; \ | |
545 | fi | |
4d714963 | 546 | ### gcc |
6995fe83 | 547 | all-gcc: all-libiberty all-byacc |
06a07944 | 548 | @if [ -f ./gcc/Makefile ] ; then \ |
77806c3e | 549 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 550 | (cd ./gcc; \ |
2198e4ba | 551 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
552 | else \ |
553 | true ; \ | |
554 | fi | |
4d714963 RP |
555 | |
556 | clean-gcc: force | |
06a07944 | 557 | @if [ -f ./gcc/Makefile ] ; then \ |
77806c3e | 558 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 559 | (cd ./gcc; \ |
2198e4ba | 560 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
561 | else \ |
562 | true ; \ | |
563 | fi | |
4d714963 | 564 | |
c4fb14b7 | 565 | install-gcc: force |
06a07944 | 566 | @if [ -f ./gcc/Makefile ] ; then \ |
77806c3e | 567 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 568 | (cd ./gcc; \ |
2198e4ba | 569 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
570 | else \ |
571 | true ; \ | |
572 | fi | |
23e3e7f9 | 573 | |
4d714963 | 574 | ### readline |
c4fb14b7 | 575 | all-readline: force |
06a07944 | 576 | @if [ -f ./readline/Makefile ] ; then \ |
77806c3e | 577 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 578 | (cd ./readline; \ |
2198e4ba | 579 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
580 | else \ |
581 | true ; \ | |
582 | fi | |
4d714963 RP |
583 | |
584 | clean-readline: force | |
06a07944 | 585 | @if [ -f ./readline/Makefile ] ; then \ |
77806c3e | 586 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 587 | (cd ./readline; \ |
2198e4ba | 588 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
589 | else \ |
590 | true ; \ | |
591 | fi | |
4d714963 RP |
592 | |
593 | install-readline: force | |
06a07944 | 594 | @if [ -f ./readline/Makefile ] ; then \ |
77806c3e | 595 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 596 | (cd ./readline; \ |
2198e4ba | 597 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
598 | else \ |
599 | true ; \ | |
600 | fi | |
23e3e7f9 | 601 | |
4d714963 | 602 | ### glob |
c4fb14b7 | 603 | all-glob: force |
06a07944 | 604 | @if [ -f ./glob/Makefile ] ; then \ |
77806c3e | 605 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 606 | (cd ./glob; \ |
2198e4ba | 607 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
608 | else \ |
609 | true ; \ | |
610 | fi | |
4d714963 RP |
611 | |
612 | clean-glob: force | |
06a07944 | 613 | @if [ -f ./glob/Makefile ] ; then \ |
77806c3e | 614 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 615 | (cd ./glob; \ |
2198e4ba | 616 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
617 | else \ |
618 | true ; \ | |
619 | fi | |
4d714963 RP |
620 | |
621 | install-glob: force | |
06a07944 | 622 | @if [ -f ./glob/Makefile ] ; then \ |
77806c3e | 623 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 624 | (cd ./glob; \ |
2198e4ba | 625 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
626 | else \ |
627 | true ; \ | |
628 | fi | |
23e3e7f9 | 629 | |
4d714963 | 630 | ### gas |
c4fb14b7 | 631 | all-gas: all-libiberty all-bfd |
06a07944 | 632 | @if [ -f ./gas/Makefile ] ; then \ |
77806c3e | 633 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 634 | (cd ./gas; \ |
2198e4ba | 635 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
636 | else \ |
637 | true ; \ | |
638 | fi | |
4d714963 RP |
639 | |
640 | clean-gas: force | |
06a07944 | 641 | @if [ -f ./gas/Makefile ] ; then \ |
77806c3e | 642 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 643 | (cd ./gas; \ |
2198e4ba | 644 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
645 | else \ |
646 | true ; \ | |
647 | fi | |
4d714963 RP |
648 | |
649 | install-gas: force | |
06a07944 | 650 | @if [ -f ./gas/Makefile ] ; then \ |
77806c3e | 651 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 652 | (cd ./gas; \ |
2198e4ba | 653 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
654 | else \ |
655 | true ; \ | |
656 | fi | |
23e3e7f9 | 657 | |
3ad0ef37 SC |
658 | ### gas |
659 | all-tgas: all-libiberty all-bfd | |
660 | @if [ -f ./tgas/Makefile ] ; then \ | |
661 | rootme=`pwd` ; export rootme ; \ | |
662 | (cd ./tgas; \ | |
663 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ | |
664 | else \ | |
665 | true ; \ | |
666 | fi | |
667 | ||
668 | ||
4d714963 | 669 | ### ld |
6995fe83 | 670 | all-ld: all-libiberty all-bfd all-byacc all-flex |
06a07944 | 671 | @if [ -f ./ld/Makefile ] ; then \ |
77806c3e | 672 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 673 | (cd ./ld; \ |
2198e4ba | 674 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
675 | else \ |
676 | true ; \ | |
677 | fi | |
a0f47eb7 | 678 | |
4d714963 | 679 | clean-ld: force |
06a07944 | 680 | @if [ -f ./ld/Makefile ] ; then \ |
77806c3e | 681 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 682 | (cd ./ld; \ |
2198e4ba | 683 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
684 | else \ |
685 | true ; \ | |
686 | fi | |
6a3958b2 | 687 | |
4d714963 | 688 | install-ld: force |
06a07944 | 689 | @if [ -f ./ld/Makefile ] ; then \ |
77806c3e | 690 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 691 | (cd ./ld; \ |
2198e4ba | 692 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
693 | else \ |
694 | true ; \ | |
695 | fi | |
23e3e7f9 | 696 | |
4d714963 | 697 | ### gdb |
6995fe83 | 698 | all-gdb: all-bfd all-libiberty all-mmalloc all-readline all-glob all-byacc |
06a07944 | 699 | @if [ -f ./gdb/Makefile ] ; then \ |
77806c3e | 700 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 701 | (cd ./gdb; \ |
2198e4ba | 702 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
703 | else \ |
704 | true ; \ | |
705 | fi | |
4d714963 RP |
706 | |
707 | clean-gdb: force | |
06a07944 | 708 | @if [ -f ./gdb/Makefile ] ; then \ |
77806c3e | 709 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 710 | (cd ./gdb; \ |
2198e4ba | 711 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
712 | else \ |
713 | true ; \ | |
714 | fi | |
4d714963 RP |
715 | |
716 | install-gdb: force | |
06a07944 | 717 | @if [ -f ./gdb/Makefile ] ; then \ |
77806c3e | 718 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 719 | (cd ./gdb; \ |
2198e4ba | 720 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
721 | else \ |
722 | true ; \ | |
723 | fi | |
23e3e7f9 | 724 | |
4d714963 | 725 | ### make |
c4fb14b7 | 726 | all-make: all-libiberty |
06a07944 | 727 | @if [ -f ./make/Makefile ] ; then \ |
77806c3e | 728 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 729 | (cd ./make; \ |
2198e4ba | 730 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
731 | else \ |
732 | true ; \ | |
733 | fi | |
4d714963 RP |
734 | |
735 | clean-make: force | |
06a07944 | 736 | @if [ -f ./make/Makefile ] ; then \ |
77806c3e | 737 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 738 | (cd ./make; \ |
2198e4ba | 739 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
740 | else \ |
741 | true ; \ | |
742 | fi | |
4d714963 RP |
743 | |
744 | install-make: force | |
06a07944 | 745 | @if [ -f ./make/Makefile ] ; then \ |
77806c3e | 746 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 747 | (cd ./make; \ |
2198e4ba | 748 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
749 | else \ |
750 | true ; \ | |
751 | fi | |
23e3e7f9 | 752 | |
4d714963 | 753 | ### diff |
c4fb14b7 | 754 | all-diff: force |
06a07944 | 755 | @if [ -f ./diff/Makefile ] ; then \ |
77806c3e | 756 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 757 | (cd ./diff; \ |
2198e4ba | 758 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
759 | else \ |
760 | true ; \ | |
761 | fi | |
4d714963 RP |
762 | |
763 | clean-diff: force | |
06a07944 | 764 | @if [ -f ./diff/Makefile ] ; then \ |
77806c3e | 765 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 766 | (cd ./diff; \ |
2198e4ba | 767 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
768 | else \ |
769 | true ; \ | |
770 | fi | |
4d714963 RP |
771 | |
772 | install-diff: force | |
06a07944 | 773 | @if [ -f ./diff/Makefile ] ; then \ |
77806c3e | 774 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 775 | (cd ./diff/; \ |
2198e4ba | 776 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
777 | else \ |
778 | true ; \ | |
779 | fi | |
23e3e7f9 | 780 | |
4d714963 | 781 | ### grep |
c4fb14b7 | 782 | all-grep: force |
06a07944 | 783 | @if [ -f ./grep/Makefile ] ; then \ |
77806c3e | 784 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 785 | (cd ./grep; \ |
2198e4ba | 786 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
787 | else \ |
788 | true ; \ | |
789 | fi | |
4d714963 RP |
790 | |
791 | clean-grep: force | |
06a07944 | 792 | @if [ -f ./grep/Makefile ] ; then \ |
77806c3e | 793 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 794 | (cd ./grep; \ |
2198e4ba | 795 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
796 | else \ |
797 | true ; \ | |
798 | fi | |
4d714963 RP |
799 | |
800 | install-grep: force | |
06a07944 | 801 | @if [ -f ./grep/Makefile ] ; then \ |
77806c3e | 802 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 803 | (cd ./grep; \ |
2198e4ba MT |
804 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
805 | else \ | |
806 | true ; \ | |
807 | fi | |
808 | ||
809 | ### rcs | |
810 | all-rcs: force | |
06a07944 | 811 | @if [ -f ./rcs/Makefile ] ; then \ |
2198e4ba MT |
812 | rootme=`pwd` ; export rootme ; \ |
813 | (cd ./rcs; \ | |
814 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ | |
b26ff9d8 RP |
815 | else \ |
816 | true ; \ | |
817 | fi | |
4d714963 RP |
818 | |
819 | clean-rcs: force | |
06a07944 | 820 | @if [ -f ./rcs/Makefile ] ; then \ |
77806c3e | 821 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 822 | (cd ./rcs; \ |
2198e4ba | 823 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
824 | else \ |
825 | true ; \ | |
826 | fi | |
4d714963 | 827 | |
c4fb14b7 | 828 | install-rcs: force |
06a07944 | 829 | @if [ -f ./rcs/Makefile ] ; then \ |
77806c3e | 830 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 831 | (cd ./rcs; \ |
2198e4ba | 832 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
833 | else \ |
834 | true ; \ | |
835 | fi | |
23e3e7f9 | 836 | |
4d714963 | 837 | ### cvs |
c4fb14b7 | 838 | all-cvs: force |
06a07944 | 839 | @if [ -f ./cvs/Makefile ] ; then \ |
77806c3e | 840 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 841 | (cd ./cvs; \ |
2198e4ba | 842 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
843 | else \ |
844 | true ; \ | |
845 | fi | |
4d714963 | 846 | |
c4fb14b7 | 847 | clean-cvs: force |
06a07944 | 848 | @if [ -f ./cvs/Makefile ] ; then \ |
77806c3e | 849 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 850 | (cd ./cvs; \ |
2198e4ba | 851 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
852 | else \ |
853 | true ; \ | |
854 | fi | |
4d714963 | 855 | |
c4fb14b7 | 856 | install-cvs: force |
06a07944 | 857 | @if [ -f ./cvs/Makefile ] ; then \ |
77806c3e | 858 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 859 | (cd ./cvs; \ |
2198e4ba | 860 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
861 | else \ |
862 | true ; \ | |
863 | fi | |
23e3e7f9 | 864 | |
7c9feeb7 | 865 | ### patch |
c4fb14b7 | 866 | all-patch: force |
06a07944 | 867 | @if [ -f ./patch/Makefile ] ; then \ |
77806c3e | 868 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 869 | (cd ./patch; \ |
2198e4ba | 870 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
7c9feeb7 RP |
871 | else \ |
872 | true ; \ | |
873 | fi | |
874 | ||
c4fb14b7 | 875 | clean-patch: force |
06a07944 | 876 | @if [ -f ./patch/Makefile ] ; then \ |
77806c3e | 877 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 878 | (cd ./patch; \ |
2198e4ba | 879 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
7c9feeb7 RP |
880 | else \ |
881 | true ; \ | |
882 | fi | |
883 | ||
c4fb14b7 | 884 | install-patch: force |
06a07944 | 885 | @if [ -f ./patch/Makefile ] ; then \ |
77806c3e | 886 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 887 | (cd ./patch; \ |
2198e4ba | 888 | $(MAKE) $(FLAGS_TO_PASS) \ |
7c9feeb7 | 889 | bindir=$(bindir) \ |
2198e4ba | 890 | man1dir=$(man1dir) install) ; \ |
7c9feeb7 RP |
891 | else \ |
892 | true ; \ | |
893 | fi | |
894 | ||
4d714963 | 895 | ### emacs |
c4fb14b7 | 896 | all-emacs: force |
06a07944 | 897 | @if [ -f ./emacs/Makefile ] ; then \ |
77806c3e | 898 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 899 | (cd ./emacs; \ |
2198e4ba | 900 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
901 | else \ |
902 | true ; \ | |
903 | fi | |
4d714963 | 904 | |
c4fb14b7 | 905 | clean-emacs: force |
06a07944 | 906 | @if [ -f ./emacs/Makefile ] ; then \ |
77806c3e | 907 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 908 | (cd ./emacs; \ |
2198e4ba | 909 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
910 | else \ |
911 | true ; \ | |
912 | fi | |
4d714963 | 913 | |
c4fb14b7 | 914 | install-emacs: force |
06a07944 | 915 | @if [ -f ./emacs/Makefile ] ; then \ |
77806c3e | 916 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 917 | (cd ./emacs; \ |
2198e4ba | 918 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
b26ff9d8 RP |
919 | else \ |
920 | true ; \ | |
921 | fi | |
23e3e7f9 | 922 | |
4d714963 | 923 | ### ispell |
c4fb14b7 | 924 | all-ispell: all-emacs |
06a07944 | 925 | @if [ -f ./ispell/Makefile ] ; then \ |
77806c3e | 926 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 927 | (cd ./ispell; \ |
2198e4ba | 928 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
b26ff9d8 RP |
929 | else \ |
930 | true ; \ | |
931 | fi | |
4d714963 | 932 | |
c4fb14b7 | 933 | clean-ispell: force |
06a07944 | 934 | @if [ -f ./ispell/Makefile ] ; then \ |
77806c3e | 935 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 936 | (cd ./ispell; \ |
2198e4ba | 937 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
b26ff9d8 RP |
938 | else \ |
939 | true ; \ | |
940 | fi | |
4d714963 | 941 | |
c4fb14b7 | 942 | install-ispell: force |
06a07944 | 943 | @if [ -f ./ispell/Makefile ] ; then \ |
77806c3e | 944 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 945 | (cd ./ispell; \ |
2198e4ba | 946 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
079399f6 RP |
947 | else \ |
948 | true ; \ | |
949 | fi | |
23e3e7f9 | 950 | |
079b2abe | 951 | ### send_pr |
c4fb14b7 | 952 | all-send_pr: force |
06a07944 | 953 | @if [ -f ./send_pr/Makefile ] ; then \ |
079b2abe RP |
954 | rootme=`pwd` ; export rootme ; \ |
955 | (cd ./send_pr; \ | |
2198e4ba | 956 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ |
079b2abe RP |
957 | else \ |
958 | true ; \ | |
959 | fi | |
079b2abe | 960 | |
c4fb14b7 | 961 | clean-send_pr: force |
06a07944 | 962 | @if [ -f ./send_pr/Makefile ] ; then \ |
079b2abe RP |
963 | rootme=`pwd` ; export rootme ; \ |
964 | (cd ./send_pr; \ | |
2198e4ba | 965 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ |
079b2abe RP |
966 | else \ |
967 | true ; \ | |
968 | fi | |
969 | ||
c4fb14b7 | 970 | install-send_pr: force |
06a07944 | 971 | @if [ -f ./send_pr/Makefile ] ; then \ |
079b2abe RP |
972 | rootme=`pwd` ; export rootme ; \ |
973 | (cd ./send_pr; \ | |
2198e4ba | 974 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ |
079b2abe RP |
975 | else \ |
976 | true ; \ | |
977 | fi | |
978 | ||
06a07944 RP |
979 | ### libm |
980 | all-libm: force | |
98a33b6d | 981 | @if [ -f ./libm/Makefile ] ; then \ |
06a07944 RP |
982 | rootme=`pwd` ; export rootme ; \ |
983 | (cd ./libm; \ | |
984 | $(MAKE) $(FLAGS_TO_PASS) all) ; \ | |
985 | else \ | |
986 | true ; \ | |
987 | fi | |
988 | ||
989 | clean-libm: force | |
98a33b6d | 990 | @if [ -f ./libm/Makefile ] ; then \ |
06a07944 RP |
991 | rootme=`pwd` ; export rootme ; \ |
992 | (cd ./libm; \ | |
993 | $(MAKE) $(FLAGS_TO_PASS) clean) ; \ | |
994 | else \ | |
995 | true ; \ | |
996 | fi | |
997 | ||
998 | install-libm: force | |
98a33b6d | 999 | @if [ -f ./libm/Makefile ] ; then \ |
06a07944 RP |
1000 | rootme=`pwd` ; export rootme ; \ |
1001 | (cd ./libm; \ | |
1002 | $(MAKE) $(FLAGS_TO_PASS) install) ; \ | |
1003 | else \ | |
1004 | true ; \ | |
1005 | fi | |
1006 | ||
ba8abfce | 1007 | ### libg++ |
9d98d2ac | 1008 | |
c4fb14b7 | 1009 | all-libg++: all-gas all-ld all-gcc |
06a07944 | 1010 | @if [ -f ./libg++/Makefile ] ; then \ |
77806c3e | 1011 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 1012 | (cd ./libg++; \ |
f0e9ba1e | 1013 | $(MAKE) $(FLAGS_TO_PASS) "CC=${GXX}" all) ; \ |
ba8abfce JG |
1014 | else \ |
1015 | true ; \ | |
1016 | fi | |
1017 | ||
c4fb14b7 | 1018 | clean-libg++: force |
06a07944 | 1019 | @if [ -f ./libg++/Makefile ] ; then \ |
77806c3e | 1020 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 1021 | (cd ./libg++; \ |
f0e9ba1e | 1022 | $(MAKE) $(FLAGS_TO_PASS) "CC=${GXX}" clean) ; \ |
ba8abfce JG |
1023 | else \ |
1024 | true ; \ | |
1025 | fi | |
1026 | ||
c4fb14b7 | 1027 | install-libg++: force |
06a07944 | 1028 | @if [ -f ./libg++/Makefile ] ; then \ |
77806c3e | 1029 | rootme=`pwd` ; export rootme ; \ |
7fcfdcf7 | 1030 | (cd ./libg++; \ |
f0e9ba1e | 1031 | $(MAKE) $(FLAGS_TO_PASS) "CC=${GXX}" install) ; \ |
ba8abfce JG |
1032 | else \ |
1033 | true ; \ | |
1034 | fi | |
23e3e7f9 | 1035 | |
4d714963 | 1036 | ### other supporting targets |
a0f47eb7 SC |
1037 | # this is a bad hack. |
1038 | all.xclib: all.normal | |
98a33b6d | 1039 | if [ -f clib/Makefile ] ; then \ |
2198e4ba | 1040 | (cd clib ; $(MAKE) $(FLAGS_TO_PASS)) ; \ |
a0f47eb7 SC |
1041 | fi |
1042 | ||
02a7ba9a | 1043 | subdir_do: |
1dbe4d41 | 1044 | @for i in $(DODIRS); do \ |
7fcfdcf7 SC |
1045 | if [ -f ./$$i/localenv ] ; then \ |
1046 | if (rootme=`pwd` ; export rootme ; cd ./$$i; \ | |
2198e4ba | 1047 | $(MAKE) $(FLAGS_TO_PASS) $(DO)) ; then true ; \ |
a0f47eb7 | 1048 | else exit 1 ; fi ; \ |
06a07944 | 1049 | else if [ -f ./$$i/Makefile ] ; then \ |
7fcfdcf7 | 1050 | if (rootme=`pwd` ; export rootme ; cd ./$$i; \ |
2198e4ba | 1051 | $(MAKE) $(FLAGS_TO_PASS) $(DO)) ; then true ; \ |
a01bf1fb RP |
1052 | else exit 1 ; fi ; \ |
1053 | else true ; fi ; \ | |
a0f47eb7 | 1054 | fi ; \ |
a01bf1fb | 1055 | done |
eb02fd64 | 1056 | |
abc52b80 JG |
1057 | # The "else true" stuff is for Ultrix; the shell returns the exit code |
1058 | # of the "if" command, if no commands are run in the "then" or "else" part, | |
1059 | # causing Make to quit. | |
4c27527f RP |
1060 | |
1061 | MAKEDIRS= \ | |
4d714963 | 1062 | $(prefix) \ |
7fcfdcf7 | 1063 | $(exec_prefix) \ |
8b361a95 SEF |
1064 | $(tooldir) |
1065 | ||
1066 | # $(bindir) \ | |
1067 | # $(libdir) \ | |
1068 | # $(includedir) \ | |
1069 | # $(datadir) \ | |
1070 | # $(docdir) \ | |
1071 | # $(mandir) \ | |
1072 | # $(man1dir) \ | |
1073 | # $(man5dir) | |
4d714963 RP |
1074 | |
1075 | # $(man2dir) \ | |
1076 | # $(man3dir) \ | |
1077 | # $(man4dir) \ | |
1078 | # $(man6dir) \ | |
1079 | # $(man7dir) \ | |
1080 | # $(man8dir) | |
4c27527f | 1081 | |
02a7ba9a | 1082 | install-dirs: |
4c27527f | 1083 | for i in $(MAKEDIRS) ; do \ |
cd49a4dc | 1084 | echo Making $$i... ; \ |
8b361a95 SEF |
1085 | parent=`echo $$i|sed -e 's@/[^/]*$$@@'`; \ |
1086 | if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi ; \ | |
06a07944 RP |
1087 | if [ ! -d $$i ] ; then \ |
1088 | if mkdir $$i ; then \ | |
1089 | true ; \ | |
1090 | else \ | |
1091 | exit 1 ; \ | |
1092 | fi ; \ | |
1093 | else \ | |
1094 | true ; \ | |
1095 | fi ; \ | |
4c27527f | 1096 | done |
0ec776a5 | 1097 | |
c5f94070 | 1098 | MAKEINFODIRS= \ |
8b361a95 SEF |
1099 | $(prefix) |
1100 | ||
1101 | # $(infodir) | |
c5f94070 | 1102 | |
02a7ba9a | 1103 | install-info-dirs: |
9a9e8e7f | 1104 | if [ -d $(prefix) ] ; then true ; else mkdir $(prefix) ; fi |
8b361a95 SEF |
1105 | # if [ -d $(datadir) ] ; then true ; else mkdir $(datadir) ; fi |
1106 | # if [ -d $(infodir) ] ; then true ; else mkdir $(infodir) ; fi | |
c5f94070 | 1107 | |
02a7ba9a | 1108 | dir.info: |
8b361a95 | 1109 | $(srcdir)/texinfo/gen-info-dir $(infodir) $(srcdir)/texinfo/dir.info-template > dir.info.new |
c466cfab | 1110 | mv -f dir.info.new dir.info |
6b7e5998 | 1111 | |
eb02fd64 RP |
1112 | etags tags: TAGS |
1113 | ||
02a7ba9a | 1114 | TAGS: |
eb02fd64 RP |
1115 | etags `$(MAKE) ls` |
1116 | ||
1117 | ls: | |
1118 | @echo Makefile | |
1119 | @for i in $(SUBDIRS); \ | |
1120 | do \ | |
1121 | (cd $$i; \ | |
1122 | pwd=`pwd`; \ | |
1123 | wd=`basename $$pwd`; \ | |
1124 | for j in `$(MAKE) ls`; \ | |
1125 | do \ | |
1126 | echo $$wd/$$j; \ | |
1127 | done) \ | |
1128 | done | |
1129 | ||
3c81fef5 | 1130 | force: |
eb02fd64 RP |
1131 | |
1132 | # with the gnu make, this is done automatically. | |
1133 | ||
f1eb48b6 | 1134 | Makefile: $(srcdir)/Makefile.in $(host_makefile_frag) $(target_makefile_frag) |
a26878d1 | 1135 | $(SHELL) ./config.status |
eb02fd64 | 1136 | |
11954bf1 JG |
1137 | # |
1138 | # Build GDB distributions that contain BFD, Include, Libiberty, Readline, etc | |
1139 | ||
23e3e7f9 | 1140 | DEVO_SUPPORT= README cfg-paper.texi Makefile.in configure configure.in \ |
be2becc7 | 1141 | config.sub config configure.man move-if-change |
66cfe047 | 1142 | GDB_SUPPORT_DIRS= bfd include libiberty mmalloc readline glob |
abc52b80 | 1143 | GDB_SUPPORT_FILES= $(GDB_SUPPORT_DIRS) texinfo/fsf/texinfo.tex |
11954bf1 | 1144 | |
abc52b80 | 1145 | setup-dirs: force_update |
11954bf1 JG |
1146 | ./configure sun4 |
1147 | make clean | |
1148 | ./configure -rm sun4 | |
905bb120 | 1149 | chmod og=u `find $(DEVO_SUPPORT) $(GDB_SUPPORT_FILES) -print` |
abc52b80 JG |
1150 | |
1151 | bfd.ilrt.tar.Z: setup-dirs | |
11954bf1 | 1152 | rm -f bfd.ilrt.tar.Z |
abc52b80 | 1153 | tar cf - $(DEVO_SUPPORT) $(GDB_SUPPORT_FILES) \ |
11954bf1 JG |
1154 | | compress -v >bfd.ilrt.tar.Z |
1155 | ||
abc52b80 JG |
1156 | gdb.tar.Z: setup-dirs |
1157 | (cd gdb; $(MAKE) -f Makefile.in make-proto-gdb.dir) | |
1158 | $(MAKE) $(MFLAGS) -f Makefile.in make-gdb.tar.Z | |
1159 | ||
1160 | make-gdb.tar.Z: $(DEVO_SUPPORT) $(GDB_SUPPORT_DIRS) gdb texinfo/fsf/texinfo.tex | |
1161 | rm -rf proto-toplev; mkdir proto-toplev | |
1162 | ln -s ../gdb/proto-gdb.dir proto-toplev/gdb | |
1163 | (cd proto-toplev; for i in $(DEVO_SUPPORT) $(GDB_SUPPORT_DIRS); do \ | |
1164 | ln -s ../$$i . ; \ | |
1165 | done) | |
7c9feeb7 RP |
1166 | # Put only one copy (four hard links) of COPYING in the tar file. |
1167 | rm proto-toplev/bfd/COPYING | |
1168 | ln proto-toplev/gdb/COPYING proto-toplev/bfd/COPYING | |
1169 | rm proto-toplev/include/COPYING | |
1170 | ln proto-toplev/gdb/COPYING proto-toplev/include/COPYING | |
1171 | rm proto-toplev/readline/COPYING | |
1172 | ln proto-toplev/gdb/COPYING proto-toplev/readline/COPYING | |
a3a063a9 JG |
1173 | # Take out texinfo from configurable dirs |
1174 | rm proto-toplev/configure.in | |
1175 | sed '/^configdirs=/s/texinfo //' <configure.in >proto-toplev/configure.in | |
4d714963 RP |
1176 | # Take out glob from buildable dirs |
1177 | rm proto-toplev/Makefile.in | |
6995fe83 SG |
1178 | |
1179 | sed -e '/^SUBDIRS =/s/glob //' \ | |
1180 | -e '/^all\.normal: /s/\all-texinfo //' \ | |
1181 | -e '/^clean: /s/clean-texinfo //' \ | |
1182 | -e '/^install\.all: /s/install-texinfo //' \ | |
1183 | <Makefile.in >proto-toplev/Makefile.in | |
1184 | ||
abc52b80 JG |
1185 | mkdir proto-toplev/texinfo |
1186 | mkdir proto-toplev/texinfo/fsf | |
1187 | ln -s ../../../texinfo/fsf/texinfo.tex proto-toplev/texinfo/fsf/ | |
905bb120 | 1188 | chmod og=u `find proto-toplev -print` |
abc52b80 JG |
1189 | (VER=`sed <gdb/Makefile.in -n 's/VERSION = //p'`; \ |
1190 | echo "==> Making gdb-$$VER.tar.Z"; \ | |
1191 | ln -s proto-toplev gdb-$$VER; \ | |
1192 | tar cfh - gdb-$$VER \ | |
1193 | | compress -v >gdb-$$VER.tar.Z) | |
1194 | ||
11954bf1 JG |
1195 | force_update: |
1196 | ||
0ec776a5 SC |
1197 | nothing: |
1198 | ||
eb02fd64 | 1199 | # end of Makefile.in |