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