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