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