Changeset 4075af6f in rtems
- Timestamp:
- 10/05/99 13:49:54 (24 years ago)
- Branches:
- 4.10, 4.11, 4.8, 4.9, 5, master
- Children:
- 133dcd92
- Parents:
- d83c39dc
- Files:
-
- 90 edited
Legend:
- Unmodified
- Added
- Removed
-
aclocal.m4
rd83c39dc r4075af6f 20 20 AC_DEFUN(RTEMS_TOP, 21 21 [dnl 22 AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl 23 AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl 24 22 25 AC_ARG_WITH(target-subdir, 23 26 [ --with-target-subdir=DIR], … … 44 47 AC_MSG_RESULT($RTEMS_VERSION) 45 48 ])dnl 46 47 dnl48 dnl $Id$49 dnl50 51 dnl canonicalize target cpu52 dnl NOTE: Most rtems targets do not fullfil autoconf's53 dnl target naming conventions "processor-vendor-os"54 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them55 dnl and we have to fix it for rtems ourselves56 57 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,58 [59 AC_CANONICAL_SYSTEM60 AC_MSG_CHECKING(rtems target cpu)61 changequote(,)dnl62 case "${target}" in63 # hpux unix port should go here64 i[3456]86-go32-rtems*)65 RTEMS_CPU=i38666 ;;67 i[3456]86-pc-linux*) # unix "simulator" port68 RTEMS_CPU=unix69 ;;70 i[3456]86-*freebsd2*) # unix "simulator" port71 RTEMS_CPU=unix72 ;;73 no_cpu-*rtems*)74 RTEMS_CPU=no_cpu75 ;;76 sparc-sun-solaris*) # unix "simulator" port77 RTEMS_CPU=unix78 ;;79 *)80 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`81 ;;82 esac83 changequote([,])dnl84 AC_SUBST(RTEMS_CPU)85 AC_MSG_RESULT($RTEMS_CPU)86 ])87 49 88 50 # Do all the work for Automake. This macro actually does too much -- … … 180 142 AC_SUBST($1)]) 181 143 144 dnl 145 dnl $Id$ 146 dnl 147 148 dnl canonicalize target cpu 149 dnl NOTE: Most rtems targets do not fullfil autoconf's 150 dnl target naming conventions "processor-vendor-os" 151 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them 152 dnl and we have to fix it for rtems ourselves 153 154 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU, 155 [ 156 AC_CANONICAL_SYSTEM 157 AC_MSG_CHECKING(rtems target cpu) 158 changequote(,)dnl 159 case "${target}" in 160 # hpux unix port should go here 161 i[3456]86-go32-rtems*) 162 RTEMS_CPU=i386 163 ;; 164 i[3456]86-pc-linux*) # unix "simulator" port 165 RTEMS_CPU=unix 166 ;; 167 i[3456]86-*freebsd2*) # unix "simulator" port 168 RTEMS_CPU=unix 169 ;; 170 no_cpu-*rtems*) 171 RTEMS_CPU=no_cpu 172 ;; 173 sparc-sun-solaris*) # unix "simulator" port 174 RTEMS_CPU=unix 175 ;; 176 *) 177 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'` 178 ;; 179 esac 180 changequote([,])dnl 181 AC_SUBST(RTEMS_CPU) 182 AC_MSG_RESULT($RTEMS_CPU) 183 ]) 184 182 185 # Add --enable-maintainer-mode option to configure. 183 186 # From Jim Meyering … … 231 234 AC_DEFUN(RTEMS_ENABLE_POSIX, 232 235 [ 236 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 237 233 238 AC_ARG_ENABLE(posix, 234 239 [ --enable-posix enable posix interface], … … 266 271 267 272 dnl $Id$ 273 dnl 274 AC_DEFUN(RTEMS_CHECK_POSIX_API, 275 [dnl 276 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 277 AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl 278 279 AC_CACHE_CHECK([whether BSP supports libposix], 280 rtems_cv_HAS_POSIX_API, 281 [dnl 282 case "$RTEMS_CPU" in 283 unix*) 284 rtems_cv_HAS_POSIX_API="no" 285 ;; 286 *) 287 if test "${RTEMS_HAS_POSIX_API}" = "yes"; then 288 rtems_cv_HAS_POSIX_API="yes"; 289 else 290 rtems_cv_HAS_POSIX_API="disabled"; 291 fi 292 ;; 293 esac]) 294 if test "$rtems_cv_HAS_POSIX_API" = "yes"; then 295 HAS_POSIX_API="yes"; 296 else 297 HAS_POSIX_API="no"; 298 fi 299 AC_SUBST(HAS_POSIX_API)dnl 300 ]) 301 302 dnl $Id$ 303 304 dnl check if RTEMS support a cpu 305 AC_DEFUN(RTEMS_CHECK_CPU, 306 [dnl 307 AC_REQUIRE([RTEMS_TOP]) 308 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU]) 309 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 310 311 # Is this a supported CPU? 312 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported]) 313 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 314 AC_MSG_RESULT(yes) 315 else 316 AC_MSG_ERROR(no) 317 fi 318 ])dnl 319 320 321 dnl $Id$ 268 322 269 323 AC_DEFUN(RTEMS_ENABLE_NETWORKING, 270 324 [ 325 AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl 326 271 327 AC_ARG_ENABLE(networking, 272 328 [ --enable-networking enable TCP/IP stack], … … 280 336 281 337 dnl $Id$ 338 dnl 339 AC_DEFUN(RTEMS_CHECK_NETWORKING, 340 [dnl 341 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 342 AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl 343 AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl 344 345 AC_CACHE_CHECK([whether BSP supports networking], 346 rtems_cv_HAS_NETWORKING, 347 [dnl 348 case "$RTEMS_CPU" in 349 unix*) 350 rtems_cv_HAS_NETWORKING="no" 351 ;; 352 *) 353 if test "${RTEMS_HAS_NETWORKING}" = "yes"; then 354 rtems_cv_HAS_NETWORKING="yes"; 355 else 356 rtems_cv_HAS_NETWORKING="disabled"; 357 fi 358 ;; 359 esac]) 360 if test "$rtems_cv_HAS_NETWORKING" = "yes"; then 361 HAS_NETWORKING="yes"; 362 else 363 HAS_NETWORKING="no"; 364 fi 365 AC_SUBST(HAS_NETWORKING)dnl 366 ]) 367 368 dnl $Id$ 369 dnl 370 AC_DEFUN(RTEMS_CHECK_RDBG, 371 [dnl 372 AC_REQUIRE([RTEMS_TOP])dnl 373 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 374 AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl 375 AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl 376 AC_CACHE_CHECK([whether BSP supports librdbg], 377 rtems_cv_HAS_RDBG, 378 [ 379 if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then 380 rtems_cv_HAS_RDBG="yes" ; 381 else 382 rtems_cv_HAS_RDBG="no"; 383 fi 384 ]) 385 HAS_RDBG="$rtems_cv_HAS_RDBG" 386 AC_SUBST(HAS_RDBG) 387 ]) 388 389 dnl $Id$ 282 390 283 391 AC_DEFUN(RTEMS_ENABLE_RDBG, 284 392 [ 393 AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl 394 285 395 AC_ARG_ENABLE(rdbg, 286 396 [ --enable-rdbg enable remote debugger], … … 376 486 AC_SUBST(RTEMS_HAS_HWAPI)dnl 377 487 ])dnl 378 379 dnl $Id$380 381 dnl check if RTEMS support a cpu382 AC_DEFUN(RTEMS_CHECK_CPU,383 [dnl384 AC_REQUIRE([RTEMS_TOP])385 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])386 # Is this a supported CPU?387 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])388 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then389 AC_MSG_RESULT(yes)390 else391 AC_MSG_ERROR(no)392 fi393 ])dnl394 395 488 396 489 dnl $Id$ -
c/aclocal.m4
rd83c39dc r4075af6f 20 20 AC_DEFUN(RTEMS_TOP, 21 21 [dnl 22 AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl 23 AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl 24 22 25 AC_ARG_WITH(target-subdir, 23 26 [ --with-target-subdir=DIR], … … 44 47 AC_MSG_RESULT($RTEMS_VERSION) 45 48 ])dnl 46 47 dnl48 dnl $Id$49 dnl50 51 dnl canonicalize target cpu52 dnl NOTE: Most rtems targets do not fullfil autoconf's53 dnl target naming conventions "processor-vendor-os"54 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them55 dnl and we have to fix it for rtems ourselves56 57 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,58 [59 AC_CANONICAL_SYSTEM60 AC_MSG_CHECKING(rtems target cpu)61 changequote(,)dnl62 case "${target}" in63 # hpux unix port should go here64 i[3456]86-go32-rtems*)65 RTEMS_CPU=i38666 ;;67 i[3456]86-pc-linux*) # unix "simulator" port68 RTEMS_CPU=unix69 ;;70 i[3456]86-*freebsd2*) # unix "simulator" port71 RTEMS_CPU=unix72 ;;73 no_cpu-*rtems*)74 RTEMS_CPU=no_cpu75 ;;76 sparc-sun-solaris*) # unix "simulator" port77 RTEMS_CPU=unix78 ;;79 *)80 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`81 ;;82 esac83 changequote([,])dnl84 AC_SUBST(RTEMS_CPU)85 AC_MSG_RESULT($RTEMS_CPU)86 ])87 49 88 50 # Do all the work for Automake. This macro actually does too much -- … … 180 142 AC_SUBST($1)]) 181 143 144 dnl 145 dnl $Id$ 146 dnl 147 148 dnl canonicalize target cpu 149 dnl NOTE: Most rtems targets do not fullfil autoconf's 150 dnl target naming conventions "processor-vendor-os" 151 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them 152 dnl and we have to fix it for rtems ourselves 153 154 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU, 155 [ 156 AC_CANONICAL_SYSTEM 157 AC_MSG_CHECKING(rtems target cpu) 158 changequote(,)dnl 159 case "${target}" in 160 # hpux unix port should go here 161 i[3456]86-go32-rtems*) 162 RTEMS_CPU=i386 163 ;; 164 i[3456]86-pc-linux*) # unix "simulator" port 165 RTEMS_CPU=unix 166 ;; 167 i[3456]86-*freebsd2*) # unix "simulator" port 168 RTEMS_CPU=unix 169 ;; 170 no_cpu-*rtems*) 171 RTEMS_CPU=no_cpu 172 ;; 173 sparc-sun-solaris*) # unix "simulator" port 174 RTEMS_CPU=unix 175 ;; 176 *) 177 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'` 178 ;; 179 esac 180 changequote([,])dnl 181 AC_SUBST(RTEMS_CPU) 182 AC_MSG_RESULT($RTEMS_CPU) 183 ]) 184 182 185 # Add --enable-maintainer-mode option to configure. 183 186 # From Jim Meyering … … 242 245 AC_DEFUN(RTEMS_ENABLE_RTEMSBSP, 243 246 [ 247 AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl 244 248 AC_ARG_ENABLE(rtemsbsp, 245 249 [ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build], … … 254 258 AC_DEFUN(RTEMS_ENV_RTEMSBSP, 255 259 [dnl 260 AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl 261 AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl 262 AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl 263 AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl 264 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 265 256 266 AC_MSG_CHECKING([for RTEMS_BSP]) 257 267 AC_CACHE_VAL(rtems_cv_RTEMS_BSP, … … 267 277 ]) 268 278 269 dnl $Id$ 270 271 dnl check if RTEMS support a cpu 272 AC_DEFUN(RTEMS_CHECK_CPU, 279 dnl 280 dnl $Id$ 281 dnl 282 283 AC_DEFUN(RTEMS_PROJECT_ROOT, 273 284 [dnl 274 285 AC_REQUIRE([RTEMS_TOP]) 275 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU]) 276 # Is this a supported CPU? 277 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported]) 278 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 279 AC_MSG_RESULT(yes) 280 else 281 AC_MSG_ERROR(no) 282 fi 283 ])dnl 284 285 286 dnl $Id$ 287 288 AC_DEFUN(RTEMS_CANONICAL_HOST, 289 [dnl 290 AC_REQUIRE([AC_CANONICAL_HOST]) 291 RTEMS_HOST=$host_os 292 changequote(,)dnl 293 case "${target}" in 294 # hpux unix port should go here 295 i[3456]86-pc-linux*) # unix "simulator" port 296 RTEMS_HOST=Linux 297 ;; 298 i[3456]86-*freebsd2*) # unix "simulator" port 299 RTEMS_HOST=FreeBSD 300 ;; 301 sparc-sun-solaris*) # unix "simulator" port 302 RTEMS_HOST=Solaris 303 ;; 304 *) 305 ;; 306 esac 307 changequote([,])dnl 308 AC_SUBST(RTEMS_HOST) 309 ])dnl 286 if test "$TARGET_SUBDIR" = "." ; then 287 PROJECT_ROOT=$RTEMS_TOPdir/'$(top_builddir)'; 288 else 289 PROJECT_ROOT=../$RTEMS_TOPdir/'$(top_builddir)' 290 fi 291 AC_SUBST(PROJECT_ROOT) 292 293 RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP 294 AC_SUBST(RTEMS_ROOT) 295 296 INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change" 297 AC_SUBST(INSTALL_CHANGE) 298 299 PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex" 300 AC_SUBST(PACKHEX) 301 ]) 302 310 303 311 304 dnl $Id$ … … 350 343 AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP, 351 344 [dnl 345 AC_REQUIRE([RTEMS_TOP]) 346 352 347 AC_MSG_CHECKING([for make/custom/[$]$1.cfg]) 353 348 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then … … 356 351 AC_MSG_ERROR([no]) 357 352 fi 353 ])dnl 354 355 dnl $Id$ 356 357 dnl check if RTEMS support a cpu 358 AC_DEFUN(RTEMS_CHECK_CPU, 359 [dnl 360 AC_REQUIRE([RTEMS_TOP]) 361 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU]) 362 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 363 364 # Is this a supported CPU? 365 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported]) 366 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 367 AC_MSG_RESULT(yes) 368 else 369 AC_MSG_ERROR(no) 370 fi 371 ])dnl 372 373 374 dnl $Id$ 375 dnl 376 AC_DEFUN(RTEMS_CHECK_POSIX_API, 377 [dnl 378 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 379 AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl 380 381 AC_CACHE_CHECK([whether BSP supports libposix], 382 rtems_cv_HAS_POSIX_API, 383 [dnl 384 case "$RTEMS_CPU" in 385 unix*) 386 rtems_cv_HAS_POSIX_API="no" 387 ;; 388 *) 389 if test "${RTEMS_HAS_POSIX_API}" = "yes"; then 390 rtems_cv_HAS_POSIX_API="yes"; 391 else 392 rtems_cv_HAS_POSIX_API="disabled"; 393 fi 394 ;; 395 esac]) 396 if test "$rtems_cv_HAS_POSIX_API" = "yes"; then 397 HAS_POSIX_API="yes"; 398 else 399 HAS_POSIX_API="no"; 400 fi 401 AC_SUBST(HAS_POSIX_API)dnl 402 ]) 403 404 dnl $Id$ 405 406 AC_DEFUN(RTEMS_ENABLE_POSIX, 407 [ 408 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 409 410 AC_ARG_ENABLE(posix, 411 [ --enable-posix enable posix interface], 412 [case "${enableval}" in 413 yes) RTEMS_HAS_POSIX_API=yes ;; 414 no) RTEMS_HAS_POSIX_API=no ;; 415 *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;; 416 esac],[RTEMS_HAS_POSIX_API=yes]) 417 AC_SUBST(RTEMS_HAS_POSIX_API) 418 419 changequote(,)dnl 420 case "${target}" in 421 # hpux unix port should go here 422 i[3456]86-go32-rtems*) 423 RTEMS_HAS_POSIX_API=no 424 ;; 425 i[3456]86-pc-linux*) # unix "simulator" port 426 RTEMS_HAS_POSIX_API=no 427 ;; 428 i[3456]86-*freebsd2*) # unix "simulator" port 429 RTEMS_HAS_POSIX_API=no 430 ;; 431 no_cpu-*rtems*) 432 RTEMS_HAS_POSIX_API=no 433 ;; 434 sparc-sun-solaris*) # unix "simulator" port 435 RTEMS_HAS_POSIX_API=no 436 ;; 437 *) 438 ;; 439 esac 440 changequote([,])dnl 441 AC_SUBST(RTEMS_HAS_POSIX_API) 442 ]) 443 444 dnl 445 dnl $Id$ 446 dnl 447 448 AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING, 449 [dnl 450 AC_REQUIRE([RTEMS_TOP])dnl 451 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 452 AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl 453 454 AC_CACHE_CHECK([whether BSP supports multiprocessing], 455 rtems_cv_HAS_MP, 456 [dnl 457 if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then 458 if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then 459 rtems_cv_HAS_MP="yes" ; 460 else 461 rtems_cv_HAS_MP="disabled"; 462 fi 463 else 464 rtems_cv_HAS_MP="no"; 465 fi]) 466 if test "$rtems_cv_HAS_MP" = "yes"; then 467 HAS_MP="yes" 468 else 469 HAS_MP="no" 470 fi 471 AC_SUBST(HAS_MP) 472 ]) 473 474 dnl $Id$ 475 476 AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING, 477 [ 478 AC_ARG_ENABLE(multiprocessing, 479 [ --enable-multiprocessing enable multiprocessing interface], 480 [case "${enableval}" in 481 yes) RTEMS_HAS_MULTIPROCESSING=yes ;; 482 no) RTEMS_HAS_MULTIPROCESSING=no ;; 483 *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;; 484 esac],[RTEMS_HAS_MULTIPROCESSING=no]) 485 AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl 486 ]) 487 488 dnl $Id$ 489 490 AC_DEFUN(RTEMS_CANONICAL_HOST, 491 [dnl 492 AC_REQUIRE([AC_CANONICAL_HOST]) 493 RTEMS_HOST=$host_os 494 changequote(,)dnl 495 case "${target}" in 496 # hpux unix port should go here 497 i[3456]86-pc-linux*) # unix "simulator" port 498 RTEMS_HOST=Linux 499 ;; 500 i[3456]86-*freebsd2*) # unix "simulator" port 501 RTEMS_HOST=FreeBSD 502 ;; 503 sparc-sun-solaris*) # unix "simulator" port 504 RTEMS_HOST=Solaris 505 ;; 506 *) 507 ;; 508 esac 509 changequote([,])dnl 510 AC_SUBST(RTEMS_HOST) 358 511 ])dnl 359 512 -
c/configure
rd83c39dc r4075af6f 535 535 536 536 537 537 538 # Check whether --with-target-subdir or --without-target-subdir was given. 538 539 if test "${with_target_subdir+set}" = set; then … … 548 549 549 550 echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6 550 echo "configure:55 1: checking for RTEMS Version" >&5551 echo "configure:552: checking for RTEMS Version" >&5 551 552 if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then 552 553 RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \ … … 609 610 610 611 echo $ac_n "checking host system type""... $ac_c" 1>&6 611 echo "configure:61 2: checking host system type" >&5612 echo "configure:613: checking host system type" >&5 612 613 613 614 host_alias=$host … … 630 631 631 632 echo $ac_n "checking target system type""... $ac_c" 1>&6 632 echo "configure:63 3: checking target system type" >&5633 echo "configure:634: checking target system type" >&5 633 634 634 635 target_alias=$target … … 648 649 649 650 echo $ac_n "checking build system type""... $ac_c" 1>&6 650 echo "configure:65 1: checking build system type" >&5651 echo "configure:652: checking build system type" >&5 651 652 652 653 build_alias=$build … … 671 672 672 673 echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6 673 echo "configure:67 4: checking rtems target cpu" >&5674 echo "configure:675: checking rtems target cpu" >&5 674 675 case "${target}" in 675 676 # hpux unix port should go here … … 709 710 # ./install, which can be erroneously created by make from ./install.sh. 710 711 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 711 echo "configure:71 2: checking for a BSD compatible install" >&5712 echo "configure:713: checking for a BSD compatible install" >&5 712 713 if test -z "$INSTALL"; then 713 714 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then … … 762 763 763 764 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6 764 echo "configure:76 5: checking whether build environment is sane" >&5765 echo "configure:766: checking whether build environment is sane" >&5 765 766 # Just in case 766 767 sleep 1 … … 819 820 820 821 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 821 echo "configure:82 2: checking whether ${MAKE-make} sets \${MAKE}" >&5822 echo "configure:823: checking whether ${MAKE-make} sets \${MAKE}" >&5 822 823 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` 823 824 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then … … 859 860 missing_dir=`cd $ac_aux_dir && pwd` 860 861 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6 861 echo "configure:86 2: checking for working aclocal" >&5862 echo "configure:863: checking for working aclocal" >&5 862 863 # Run test in a subshell; some versions of sh will print an error if 863 864 # an executable is not found, even if stderr is redirected. … … 872 873 873 874 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6 874 echo "configure:87 5: checking for working autoconf" >&5875 echo "configure:876: checking for working autoconf" >&5 875 876 # Run test in a subshell; some versions of sh will print an error if 876 877 # an executable is not found, even if stderr is redirected. … … 885 886 886 887 echo $ac_n "checking for working automake""... $ac_c" 1>&6 887 echo "configure:88 8: checking for working automake" >&5888 echo "configure:889: checking for working automake" >&5 888 889 # Run test in a subshell; some versions of sh will print an error if 889 890 # an executable is not found, even if stderr is redirected. … … 898 899 899 900 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6 900 echo "configure:90 1: checking for working autoheader" >&5901 echo "configure:902: checking for working autoheader" >&5 901 902 # Run test in a subshell; some versions of sh will print an error if 902 903 # an executable is not found, even if stderr is redirected. … … 911 912 912 913 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6 913 echo "configure:91 4: checking for working makeinfo" >&5914 echo "configure:915: checking for working makeinfo" >&5 914 915 # Run test in a subshell; some versions of sh will print an error if 915 916 # an executable is not found, even if stderr is redirected. … … 925 926 926 927 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 927 echo "configure:92 8: checking whether to enable maintainer-specific portions of Makefiles" >&5928 echo "configure:929: checking whether to enable maintainer-specific portions of Makefiles" >&5 928 929 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. 929 930 if test "${enable_maintainer_mode+set}" = set; then … … 989 990 990 991 992 991 993 # Is this a supported CPU? 992 994 echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6 993 echo "configure:99 4: checking if cpu $RTEMS_CPU is supported" >&5995 echo "configure:996: checking if cpu $RTEMS_CPU is supported" >&5 994 996 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 995 997 echo "$ac_t""yes" 1>&6 … … 1020 1022 1021 1023 echo $ac_n "checking for bsps""... $ac_c" 1>&6 1022 echo "configure:102 3: checking for bsps" >&51024 echo "configure:1025: checking for bsps" >&5 1023 1025 case "${target}" in 1024 1026 i[3456]86-go32-rtems*) … … 1051 1053 1052 1054 # make sure there is a make/custom file for the bsp 1053 echo $ac_n "checking for make/custom/$i.cfg""... $ac_c" 1>&6 1054 echo "configure:1055: checking for make/custom/$i.cfg" >&5 1055 1056 1057 echo $ac_n "checking for make/custom/$i.cfg""... $ac_c" 1>&6 1058 echo "configure:1059: checking for make/custom/$i.cfg" >&5 1055 1059 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$i.cfg"; then 1056 1060 echo "$ac_t""yes" 1>&6 … … 1074 1078 # Is there code where there should be for this BSP? 1075 1079 # The bare bsp is a special case as it is not under the RTEMS_CPU path 1076 case $ iin1080 case $bspdir in 1077 1081 bare) 1078 1082 bspcpudir= -
c/src/aclocal.m4
rd83c39dc r4075af6f 20 20 AC_DEFUN(RTEMS_TOP, 21 21 [dnl 22 AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl 23 AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl 24 22 25 AC_ARG_WITH(target-subdir, 23 26 [ --with-target-subdir=DIR], … … 44 47 AC_MSG_RESULT($RTEMS_VERSION) 45 48 ])dnl 46 47 dnl $Id$48 49 AC_DEFUN(RTEMS_ENABLE_CXX,50 [51 AC_ARG_ENABLE(cxx,52 [ --enable-cxx enable C++ support,]53 [ and build the rtems++ library],54 [case "${enableval}" in55 yes) RTEMS_HAS_CPLUSPLUS=yes ;;56 no) RTEMS_HAS_CPLUSPLUS=no ;;57 *) AC_MSG_ERROR(bad value ${enableval} for enable-cxx option) ;;58 esac], [RTEMS_HAS_CPLUSPLUS=no])59 ])60 61 dnl62 dnl $Id$63 dnl64 65 dnl canonicalize target cpu66 dnl NOTE: Most rtems targets do not fullfil autoconf's67 dnl target naming conventions "processor-vendor-os"68 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them69 dnl and we have to fix it for rtems ourselves70 71 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,72 [73 AC_CANONICAL_SYSTEM74 AC_MSG_CHECKING(rtems target cpu)75 changequote(,)dnl76 case "${target}" in77 # hpux unix port should go here78 i[3456]86-go32-rtems*)79 RTEMS_CPU=i38680 ;;81 i[3456]86-pc-linux*) # unix "simulator" port82 RTEMS_CPU=unix83 ;;84 i[3456]86-*freebsd2*) # unix "simulator" port85 RTEMS_CPU=unix86 ;;87 no_cpu-*rtems*)88 RTEMS_CPU=no_cpu89 ;;90 sparc-sun-solaris*) # unix "simulator" port91 RTEMS_CPU=unix92 ;;93 *)94 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`95 ;;96 esac97 changequote([,])dnl98 AC_SUBST(RTEMS_CPU)99 AC_MSG_RESULT($RTEMS_CPU)100 ])101 49 102 50 # Do all the work for Automake. This macro actually does too much -- … … 194 142 AC_SUBST($1)]) 195 143 144 dnl $Id$ 145 146 AC_DEFUN(RTEMS_ENABLE_CXX, 147 [ 148 AC_ARG_ENABLE(cxx, 149 [ --enable-cxx enable C++ support,] 150 [ and build the rtems++ library], 151 [case "${enableval}" in 152 yes) RTEMS_HAS_CPLUSPLUS=yes ;; 153 no) RTEMS_HAS_CPLUSPLUS=no ;; 154 *) AC_MSG_ERROR(bad value ${enableval} for enable-cxx option) ;; 155 esac], [RTEMS_HAS_CPLUSPLUS=no]) 156 ]) 157 158 dnl $Id$ 159 160 AC_DEFUN(RTEMS_ENABLE_NETWORKING, 161 [ 162 AC_BEFORE([$0], [RTEMS_CHECK_NETWORKING])dnl 163 164 AC_ARG_ENABLE(networking, 165 [ --enable-networking enable TCP/IP stack], 166 [case "${enableval}" in 167 yes) RTEMS_HAS_NETWORKING=yes ;; 168 no) RTEMS_HAS_NETWORKING=no ;; 169 *) AC_MSG_ERROR(bad value ${enableval} for enable-networking option) ;; 170 esac],[RTEMS_HAS_NETWORKING=yes]) 171 AC_SUBST(RTEMS_HAS_NETWORKING)dnl 172 ]) 173 174 dnl $Id$ 175 dnl 176 AC_DEFUN(RTEMS_CHECK_NETWORKING, 177 [dnl 178 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 179 AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl 180 AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl 181 182 AC_CACHE_CHECK([whether BSP supports networking], 183 rtems_cv_HAS_NETWORKING, 184 [dnl 185 case "$RTEMS_CPU" in 186 unix*) 187 rtems_cv_HAS_NETWORKING="no" 188 ;; 189 *) 190 if test "${RTEMS_HAS_NETWORKING}" = "yes"; then 191 rtems_cv_HAS_NETWORKING="yes"; 192 else 193 rtems_cv_HAS_NETWORKING="disabled"; 194 fi 195 ;; 196 esac]) 197 if test "$rtems_cv_HAS_NETWORKING" = "yes"; then 198 HAS_NETWORKING="yes"; 199 else 200 HAS_NETWORKING="no"; 201 fi 202 AC_SUBST(HAS_NETWORKING)dnl 203 ]) 204 205 dnl $Id$ 206 207 dnl check if RTEMS support a cpu 208 AC_DEFUN(RTEMS_CHECK_CPU, 209 [dnl 210 AC_REQUIRE([RTEMS_TOP]) 211 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU]) 212 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 213 214 # Is this a supported CPU? 215 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported]) 216 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 217 AC_MSG_RESULT(yes) 218 else 219 AC_MSG_ERROR(no) 220 fi 221 ])dnl 222 223 224 dnl 225 dnl $Id$ 226 dnl 227 228 dnl canonicalize target cpu 229 dnl NOTE: Most rtems targets do not fullfil autoconf's 230 dnl target naming conventions "processor-vendor-os" 231 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them 232 dnl and we have to fix it for rtems ourselves 233 234 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU, 235 [ 236 AC_CANONICAL_SYSTEM 237 AC_MSG_CHECKING(rtems target cpu) 238 changequote(,)dnl 239 case "${target}" in 240 # hpux unix port should go here 241 i[3456]86-go32-rtems*) 242 RTEMS_CPU=i386 243 ;; 244 i[3456]86-pc-linux*) # unix "simulator" port 245 RTEMS_CPU=unix 246 ;; 247 i[3456]86-*freebsd2*) # unix "simulator" port 248 RTEMS_CPU=unix 249 ;; 250 no_cpu-*rtems*) 251 RTEMS_CPU=no_cpu 252 ;; 253 sparc-sun-solaris*) # unix "simulator" port 254 RTEMS_CPU=unix 255 ;; 256 *) 257 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'` 258 ;; 259 esac 260 changequote([,])dnl 261 AC_SUBST(RTEMS_CPU) 262 AC_MSG_RESULT($RTEMS_CPU) 263 ]) 264 265 dnl $Id$ 266 dnl 267 AC_DEFUN(RTEMS_CHECK_POSIX_API, 268 [dnl 269 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 270 AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl 271 272 AC_CACHE_CHECK([whether BSP supports libposix], 273 rtems_cv_HAS_POSIX_API, 274 [dnl 275 case "$RTEMS_CPU" in 276 unix*) 277 rtems_cv_HAS_POSIX_API="no" 278 ;; 279 *) 280 if test "${RTEMS_HAS_POSIX_API}" = "yes"; then 281 rtems_cv_HAS_POSIX_API="yes"; 282 else 283 rtems_cv_HAS_POSIX_API="disabled"; 284 fi 285 ;; 286 esac]) 287 if test "$rtems_cv_HAS_POSIX_API" = "yes"; then 288 HAS_POSIX_API="yes"; 289 else 290 HAS_POSIX_API="no"; 291 fi 292 AC_SUBST(HAS_POSIX_API)dnl 293 ]) 294 295 dnl $Id$ 296 297 AC_DEFUN(RTEMS_ENABLE_POSIX, 298 [ 299 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 300 301 AC_ARG_ENABLE(posix, 302 [ --enable-posix enable posix interface], 303 [case "${enableval}" in 304 yes) RTEMS_HAS_POSIX_API=yes ;; 305 no) RTEMS_HAS_POSIX_API=no ;; 306 *) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;; 307 esac],[RTEMS_HAS_POSIX_API=yes]) 308 AC_SUBST(RTEMS_HAS_POSIX_API) 309 310 changequote(,)dnl 311 case "${target}" in 312 # hpux unix port should go here 313 i[3456]86-go32-rtems*) 314 RTEMS_HAS_POSIX_API=no 315 ;; 316 i[3456]86-pc-linux*) # unix "simulator" port 317 RTEMS_HAS_POSIX_API=no 318 ;; 319 i[3456]86-*freebsd2*) # unix "simulator" port 320 RTEMS_HAS_POSIX_API=no 321 ;; 322 no_cpu-*rtems*) 323 RTEMS_HAS_POSIX_API=no 324 ;; 325 sparc-sun-solaris*) # unix "simulator" port 326 RTEMS_HAS_POSIX_API=no 327 ;; 328 *) 329 ;; 330 esac 331 changequote([,])dnl 332 AC_SUBST(RTEMS_HAS_POSIX_API) 333 ]) 334 335 dnl $Id$ 336 dnl 337 AC_DEFUN(RTEMS_CHECK_RDBG, 338 [dnl 339 AC_REQUIRE([RTEMS_TOP])dnl 340 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 341 AC_REQUIRE([RTEMS_CHECK_NETWORKING])dnl 342 AC_REQUIRE([RTEMS_ENABLE_RDBG])dnl 343 AC_CACHE_CHECK([whether BSP supports librdbg], 344 rtems_cv_HAS_RDBG, 345 [ 346 if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/librdbg/${RTEMS_CPU}/${$1}"; then 347 rtems_cv_HAS_RDBG="yes" ; 348 else 349 rtems_cv_HAS_RDBG="no"; 350 fi 351 ]) 352 HAS_RDBG="$rtems_cv_HAS_RDBG" 353 AC_SUBST(HAS_RDBG) 354 ]) 355 356 dnl $Id$ 357 358 AC_DEFUN(RTEMS_ENABLE_RDBG, 359 [ 360 AC_BEFORE([$0], [RTEMS_CHECK_RDBG])dnl 361 362 AC_ARG_ENABLE(rdbg, 363 [ --enable-rdbg enable remote debugger], 364 [case "${enableval}" in 365 yes) RTEMS_HAS_RDBG=yes ;; 366 no) RTEMS_HAS_RDBG=no ;; 367 *) AC_MSG_ERROR(bad value ${enableval} for enable-rdbg option) ;; 368 esac],[RTEMS_HAS_RDBG=no]) 369 AC_SUBST(RTEMS_HAS_RDBG)dnl 370 ]) 371 372 dnl $Id$ 373 374 AC_DEFUN(RTEMS_CANONICAL_HOST, 375 [dnl 376 AC_REQUIRE([AC_CANONICAL_HOST]) 377 RTEMS_HOST=$host_os 378 changequote(,)dnl 379 case "${target}" in 380 # hpux unix port should go here 381 i[3456]86-pc-linux*) # unix "simulator" port 382 RTEMS_HOST=Linux 383 ;; 384 i[3456]86-*freebsd2*) # unix "simulator" port 385 RTEMS_HOST=FreeBSD 386 ;; 387 sparc-sun-solaris*) # unix "simulator" port 388 RTEMS_HOST=Solaris 389 ;; 390 *) 391 ;; 392 esac 393 changequote([,])dnl 394 AC_SUBST(RTEMS_HOST) 395 ])dnl 396 196 397 # Add --enable-maintainer-mode option to configure. 197 398 # From Jim Meyering … … 234 435 AC_DEFUN(RTEMS_ENABLE_RTEMSBSP, 235 436 [ 437 AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl 236 438 AC_ARG_ENABLE(rtemsbsp, 237 439 [ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build], … … 246 448 AC_DEFUN(RTEMS_ENV_RTEMSBSP, 247 449 [dnl 450 AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl 451 AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl 452 AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl 453 AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl 454 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 455 248 456 AC_MSG_CHECKING([for RTEMS_BSP]) 249 457 AC_CACHE_VAL(rtems_cv_RTEMS_BSP, … … 258 466 AC_SUBST(RTEMS_BSP) 259 467 ]) 260 261 dnl $Id$262 263 dnl check if RTEMS support a cpu264 AC_DEFUN(RTEMS_CHECK_CPU,265 [dnl266 AC_REQUIRE([RTEMS_TOP])267 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])268 # Is this a supported CPU?269 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])270 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then271 AC_MSG_RESULT(yes)272 else273 AC_MSG_ERROR(no)274 fi275 ])dnl276 277 278 dnl $Id$279 280 AC_DEFUN(RTEMS_CANONICAL_HOST,281 [dnl282 AC_REQUIRE([AC_CANONICAL_HOST])283 RTEMS_HOST=$host_os284 changequote(,)dnl285 case "${target}" in286 # hpux unix port should go here287 i[3456]86-pc-linux*) # unix "simulator" port288 RTEMS_HOST=Linux289 ;;290 i[3456]86-*freebsd2*) # unix "simulator" port291 RTEMS_HOST=FreeBSD292 ;;293 sparc-sun-solaris*) # unix "simulator" port294 RTEMS_HOST=Solaris295 ;;296 *)297 ;;298 esac299 changequote([,])dnl300 AC_SUBST(RTEMS_HOST)301 ])dnl302 468 303 469 dnl … … 367 533 AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP, 368 534 [dnl 535 AC_REQUIRE([RTEMS_TOP]) 536 369 537 AC_MSG_CHECKING([for make/custom/[$]$1.cfg]) 370 538 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then … … 375 543 ])dnl 376 544 545 dnl 546 dnl $Id$ 547 dnl 548 549 AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING, 550 [dnl 551 AC_REQUIRE([RTEMS_TOP])dnl 552 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 553 AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl 554 555 AC_CACHE_CHECK([whether BSP supports multiprocessing], 556 rtems_cv_HAS_MP, 557 [dnl 558 if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${$1}/shmsupp"; then 559 if test "$RTEMS_HAS_MULTIPROCESSING" = "yes"; then 560 rtems_cv_HAS_MP="yes" ; 561 else 562 rtems_cv_HAS_MP="disabled"; 563 fi 564 else 565 rtems_cv_HAS_MP="no"; 566 fi]) 567 if test "$rtems_cv_HAS_MP" = "yes"; then 568 HAS_MP="yes" 569 else 570 HAS_MP="no" 571 fi 572 AC_SUBST(HAS_MP) 573 ]) 574 575 dnl $Id$ 576 577 AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING, 578 [ 579 AC_ARG_ENABLE(multiprocessing, 580 [ --enable-multiprocessing enable multiprocessing interface], 581 [case "${enableval}" in 582 yes) RTEMS_HAS_MULTIPROCESSING=yes ;; 583 no) RTEMS_HAS_MULTIPROCESSING=no ;; 584 *) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;; 585 esac],[RTEMS_HAS_MULTIPROCESSING=no]) 586 AC_SUBST(RTEMS_HAS_MULTIPROCESSING)dnl 587 ]) 588 -
c/src/configure
rd83c39dc r4075af6f 17 17 --enable-cxx enable C++ support, 18 18 and build the rtems++ library" 19 ac_help="$ac_help 20 --enable-networking enable TCP/IP stack" 19 21 ac_help="$ac_help 20 22 --enable-maintainer-mode enable make rules and dependencies not useful … … 530 532 531 533 534 532 535 # Check whether --with-target-subdir or --without-target-subdir was given. 533 536 if test "${with_target_subdir+set}" = set; then … … 543 546 544 547 echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6 545 echo "configure:54 6: checking for RTEMS Version" >&5548 echo "configure:549: checking for RTEMS Version" >&5 546 549 if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then 547 550 RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \ … … 591 594 592 595 596 # Check whether --enable-networking or --disable-networking was given. 597 if test "${enable_networking+set}" = set; then 598 enableval="$enable_networking" 599 case "${enableval}" in 600 yes) RTEMS_HAS_NETWORKING=yes ;; 601 no) RTEMS_HAS_NETWORKING=no ;; 602 *) { echo "configure: error: bad value ${enableval} for enable-networking option" 1>&2; exit 1; } ;; 603 esac 604 else 605 RTEMS_HAS_NETWORKING=yes 606 fi 607 608 609 610 593 611 594 612 # Do some error checking and defaulting for the host and target type. … … 619 637 620 638 echo $ac_n "checking host system type""... $ac_c" 1>&6 621 echo "configure:6 22: checking host system type" >&5639 echo "configure:640: checking host system type" >&5 622 640 623 641 host_alias=$host … … 640 658 641 659 echo $ac_n "checking target system type""... $ac_c" 1>&6 642 echo "configure:6 43: checking target system type" >&5660 echo "configure:661: checking target system type" >&5 643 661 644 662 target_alias=$target … … 658 676 659 677 echo $ac_n "checking build system type""... $ac_c" 1>&6 660 echo "configure:6 61: checking build system type" >&5678 echo "configure:679: checking build system type" >&5 661 679 662 680 build_alias=$build … … 681 699 682 700 echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6 683 echo "configure: 684: checking rtems target cpu" >&5701 echo "configure:702: checking rtems target cpu" >&5 684 702 case "${target}" in 685 703 # hpux unix port should go here … … 707 725 708 726 727 RTEMS_HOST=$host_os 728 case "${target}" in 729 # hpux unix port should go here 730 i[3456]86-pc-linux*) # unix "simulator" port 731 RTEMS_HOST=Linux 732 ;; 733 i[3456]86-*freebsd2*) # unix "simulator" port 734 RTEMS_HOST=FreeBSD 735 ;; 736 sparc-sun-solaris*) # unix "simulator" port 737 RTEMS_HOST=Solaris 738 ;; 739 *) 740 ;; 741 esac 742 743 744 709 745 # Find a good install program. We prefer a C program (faster), 710 746 # so one script is as good as another. But avoid the broken or … … 719 755 # ./install, which can be erroneously created by make from ./install.sh. 720 756 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 721 echo "configure:7 22: checking for a BSD compatible install" >&5757 echo "configure:758: checking for a BSD compatible install" >&5 722 758 if test -z "$INSTALL"; then 723 759 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then … … 772 808 773 809 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6 774 echo "configure: 775: checking whether build environment is sane" >&5810 echo "configure:811: checking whether build environment is sane" >&5 775 811 # Just in case 776 812 sleep 1 … … 829 865 830 866 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 831 echo "configure:8 32: checking whether ${MAKE-make} sets \${MAKE}" >&5867 echo "configure:868: checking whether ${MAKE-make} sets \${MAKE}" >&5 832 868 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` 833 869 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then … … 869 905 missing_dir=`cd $ac_aux_dir && pwd` 870 906 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6 871 echo "configure: 872: checking for working aclocal" >&5907 echo "configure:908: checking for working aclocal" >&5 872 908 # Run test in a subshell; some versions of sh will print an error if 873 909 # an executable is not found, even if stderr is redirected. … … 882 918 883 919 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6 884 echo "configure: 885: checking for working autoconf" >&5920 echo "configure:921: checking for working autoconf" >&5 885 921 # Run test in a subshell; some versions of sh will print an error if 886 922 # an executable is not found, even if stderr is redirected. … … 895 931 896 932 echo $ac_n "checking for working automake""... $ac_c" 1>&6 897 echo "configure: 898: checking for working automake" >&5933 echo "configure:934: checking for working automake" >&5 898 934 # Run test in a subshell; some versions of sh will print an error if 899 935 # an executable is not found, even if stderr is redirected. … … 908 944 909 945 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6 910 echo "configure:9 11: checking for working autoheader" >&5946 echo "configure:947: checking for working autoheader" >&5 911 947 # Run test in a subshell; some versions of sh will print an error if 912 948 # an executable is not found, even if stderr is redirected. … … 921 957 922 958 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6 923 echo "configure:9 24: checking for working makeinfo" >&5959 echo "configure:960: checking for working makeinfo" >&5 924 960 # Run test in a subshell; some versions of sh will print an error if 925 961 # an executable is not found, even if stderr is redirected. … … 935 971 936 972 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 937 echo "configure:9 38: checking whether to enable maintainer-specific portions of Makefiles" >&5973 echo "configure:974: checking whether to enable maintainer-specific portions of Makefiles" >&5 938 974 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. 939 975 if test "${enable_maintainer_mode+set}" = set; then … … 958 994 959 995 996 960 997 echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6 961 echo "configure:9 62: checking for RTEMS_BSP" >&5998 echo "configure:999: checking for RTEMS_BSP" >&5 962 999 if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then 963 1000 echo $ac_n "(cached) $ac_c" 1>&6 … … 975 1012 976 1013 1014 977 1015 # Is this a supported CPU? 978 1016 echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6 979 echo "configure: 980: checking if cpu $RTEMS_CPU is supported" >&51017 echo "configure:1018: checking if cpu $RTEMS_CPU is supported" >&5 980 1018 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 981 1019 echo "$ac_t""yes" 1>&6 … … 985 1023 986 1024 987 RTEMS_HOST=$host_os 988 case "${target}" in 989 # hpux unix port should go here 990 i[3456]86-pc-linux*) # unix "simulator" port 991 RTEMS_HOST=Linux 992 ;; 993 i[3456]86-*freebsd2*) # unix "simulator" port 994 RTEMS_HOST=FreeBSD 995 ;; 996 sparc-sun-solaris*) # unix "simulator" port 997 RTEMS_HOST=Solaris 998 ;; 999 *) 1000 ;; 1001 esac 1002 1025 1026 echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6 1027 echo "configure:1028: checking for make/custom/$RTEMS_BSP.cfg" >&5 1028 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then 1029 echo "$ac_t""yes" 1>&6 1030 else 1031 { echo "configure: error: no" 1>&2; exit 1; } 1032 fi 1033 1034 1035 1036 echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6 1037 echo "configure:1038: checking whether BSP supports networking" >&5 1038 if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then 1039 echo $ac_n "(cached) $ac_c" 1>&6 1040 else 1041 case "$RTEMS_CPU" in 1042 unix*) 1043 rtems_cv_HAS_NETWORKING="no" 1044 ;; 1045 *) 1046 if test "${RTEMS_HAS_NETWORKING}" = "yes"; then 1047 rtems_cv_HAS_NETWORKING="yes"; 1048 else 1049 rtems_cv_HAS_NETWORKING="disabled"; 1050 fi 1051 ;; 1052 esac 1053 fi 1054 1055 echo "$ac_t""$rtems_cv_HAS_NETWORKING" 1>&6 1056 if test "$rtems_cv_HAS_NETWORKING" = "yes"; then 1057 HAS_NETWORKING="yes"; 1058 else 1059 HAS_NETWORKING="no"; 1060 fi 1061 1062 1063 ## Note: the order of the directories below is essential 1064 subdirs="make" 1065 1066 subdirs="make exec" 1067 1068 subdirs="make exec lib" 1069 1070 if test "$HAS_NETWORKING" = "yes"; then 1071 cfg_subdirs="libnetworking librpc" 1072 fi 1073 if test "$RTEMS_HAS_CPLUSPLUS" = "yes"; then 1074 cfg_subdirs="$cfg_subdirs librtems++"; 1075 fi 1076 subdirs="make exec lib $cfg_subdirs" 1077 1078 subdirs="make exec lib $cfg_subdirs wrapup" 1079 1080 1081 subdirs="make exec lib $cfg_subdirs wrapup tests" 1003 1082 1004 1083 … … 1019 1098 PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex" 1020 1099 1021 1022 1023 echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&61024 echo "configure:1025: checking for make/custom/$RTEMS_BSP.cfg" >&51025 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then1026 echo "$ac_t""yes" 1>&61027 else1028 { echo "configure: error: no" 1>&2; exit 1; }1029 fi1030 1031 1032 ## Note: the order of the directories below is essential1033 subdirs="make"1034 1035 subdirs="make exec"1036 1037 subdirs="make exec lib"1038 1039 if test "$RTEMS_HAS_CPLUSPLUS" = "yes"; then1040 cfg_subdirs="librtems++";1041 fi1042 subdirs="make exec lib $cfg_subdirs"1043 1044 subdirs="make exec lib $cfg_subdirs tests"1045 1100 1046 1101 … … 1159 1214 1160 1215 trap 'rm -fr `echo "Makefile 1216 wrapup/Makefile 1161 1217 " | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 1162 1218 EOF … … 1192 1248 s%@mandir@%$mandir%g 1193 1249 s%@RTEMS_TOPdir@%$RTEMS_TOPdir%g 1250 s%@RTEMS_HAS_NETWORKING@%$RTEMS_HAS_NETWORKING%g 1194 1251 s%@host@%$host%g 1195 1252 s%@host_alias@%$host_alias%g … … 1208 1265 s%@build_os@%$build_os%g 1209 1266 s%@RTEMS_CPU@%$RTEMS_CPU%g 1267 s%@RTEMS_HOST@%$RTEMS_HOST%g 1210 1268 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g 1211 1269 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g … … 1223 1281 s%@MAINT@%$MAINT%g 1224 1282 s%@RTEMS_BSP@%$RTEMS_BSP%g 1225 s%@RTEMS_HOST@%$RTEMS_HOST%g 1283 s%@HAS_NETWORKING@%$HAS_NETWORKING%g 1284 s%@subdirs@%$subdirs%g 1285 s%@cfg_subdirs@%$cfg_subdirs%g 1226 1286 s%@PROJECT_ROOT@%$PROJECT_ROOT%g 1227 1287 s%@RTEMS_ROOT@%$RTEMS_ROOT%g 1228 1288 s%@INSTALL_CHANGE@%$INSTALL_CHANGE%g 1229 1289 s%@PACKHEX@%$PACKHEX%g 1230 s%@subdirs@%$subdirs%g1231 1290 1232 1291 CEOF … … 1271 1330 1272 1331 CONFIG_FILES=\${CONFIG_FILES-"Makefile 1332 wrapup/Makefile 1273 1333 "} 1274 1334 EOF … … 1367 1427 done 1368 1428 1369 for ac_config_dir in make exec lib $cfg_subdirs tests; do1429 for ac_config_dir in make exec lib $cfg_subdirs wrapup tests; do 1370 1430 1371 1431 # Do not complain, so a configure script can configure whichever -
c/src/exec/aclocal.m4
rd83c39dc r4075af6f 20 20 AC_DEFUN(RTEMS_TOP, 21 21 [dnl 22 AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl 23 AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl 24 22 25 AC_ARG_WITH(target-subdir, 23 26 [ --with-target-subdir=DIR], … … 44 47 AC_MSG_RESULT($RTEMS_VERSION) 45 48 ])dnl 46 47 dnl48 dnl $Id$49 dnl50 51 dnl canonicalize target cpu52 dnl NOTE: Most rtems targets do not fullfil autoconf's53 dnl target naming conventions "processor-vendor-os"54 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them55 dnl and we have to fix it for rtems ourselves56 57 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,58 [59 AC_CANONICAL_SYSTEM60 AC_MSG_CHECKING(rtems target cpu)61 changequote(,)dnl62 case "${target}" in63 # hpux unix port should go here64 i[3456]86-go32-rtems*)65 RTEMS_CPU=i38666 ;;67 i[3456]86-pc-linux*) # unix "simulator" port68 RTEMS_CPU=unix69 ;;70 i[3456]86-*freebsd2*) # unix "simulator" port71 RTEMS_CPU=unix72 ;;73 no_cpu-*rtems*)74 RTEMS_CPU=no_cpu75 ;;76 sparc-sun-solaris*) # unix "simulator" port77 RTEMS_CPU=unix78 ;;79 *)80 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`81 ;;82 esac83 changequote([,])dnl84 AC_SUBST(RTEMS_CPU)85 AC_MSG_RESULT($RTEMS_CPU)86 ])87 49 88 50 # Do all the work for Automake. This macro actually does too much -- … … 180 142 AC_SUBST($1)]) 181 143 144 dnl 145 dnl $Id$ 146 dnl 147 148 dnl canonicalize target cpu 149 dnl NOTE: Most rtems targets do not fullfil autoconf's 150 dnl target naming conventions "processor-vendor-os" 151 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them 152 dnl and we have to fix it for rtems ourselves 153 154 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU, 155 [ 156 AC_CANONICAL_SYSTEM 157 AC_MSG_CHECKING(rtems target cpu) 158 changequote(,)dnl 159 case "${target}" in 160 # hpux unix port should go here 161 i[3456]86-go32-rtems*) 162 RTEMS_CPU=i386 163 ;; 164 i[3456]86-pc-linux*) # unix "simulator" port 165 RTEMS_CPU=unix 166 ;; 167 i[3456]86-*freebsd2*) # unix "simulator" port 168 RTEMS_CPU=unix 169 ;; 170 no_cpu-*rtems*) 171 RTEMS_CPU=no_cpu 172 ;; 173 sparc-sun-solaris*) # unix "simulator" port 174 RTEMS_CPU=unix 175 ;; 176 *) 177 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'` 178 ;; 179 esac 180 changequote([,])dnl 181 AC_SUBST(RTEMS_CPU) 182 AC_MSG_RESULT($RTEMS_CPU) 183 ]) 184 182 185 # Add --enable-maintainer-mode option to configure. 183 186 # From Jim Meyering … … 231 234 AC_DEFUN(RTEMS_ENABLE_POSIX, 232 235 [ 236 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 237 233 238 AC_ARG_ENABLE(posix, 234 239 [ --enable-posix enable posix interface], … … 264 269 AC_SUBST(RTEMS_HAS_POSIX_API) 265 270 ]) 271 272 dnl $Id$ 273 dnl 274 AC_DEFUN(RTEMS_CHECK_POSIX_API, 275 [dnl 276 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 277 AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl 278 279 AC_CACHE_CHECK([whether BSP supports libposix], 280 rtems_cv_HAS_POSIX_API, 281 [dnl 282 case "$RTEMS_CPU" in 283 unix*) 284 rtems_cv_HAS_POSIX_API="no" 285 ;; 286 *) 287 if test "${RTEMS_HAS_POSIX_API}" = "yes"; then 288 rtems_cv_HAS_POSIX_API="yes"; 289 else 290 rtems_cv_HAS_POSIX_API="disabled"; 291 fi 292 ;; 293 esac]) 294 if test "$rtems_cv_HAS_POSIX_API" = "yes"; then 295 HAS_POSIX_API="yes"; 296 else 297 HAS_POSIX_API="no"; 298 fi 299 AC_SUBST(HAS_POSIX_API)dnl 300 ]) 301 302 dnl $Id$ 303 304 dnl check if RTEMS support a cpu 305 AC_DEFUN(RTEMS_CHECK_CPU, 306 [dnl 307 AC_REQUIRE([RTEMS_TOP]) 308 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU]) 309 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 310 311 # Is this a supported CPU? 312 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported]) 313 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 314 AC_MSG_RESULT(yes) 315 else 316 AC_MSG_ERROR(no) 317 fi 318 ])dnl 319 266 320 267 321 dnl $Id$ … … 310 364 AC_DEFUN(RTEMS_ENABLE_RTEMSBSP, 311 365 [ 366 AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl 312 367 AC_ARG_ENABLE(rtemsbsp, 313 368 [ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build], … … 322 377 AC_DEFUN(RTEMS_ENV_RTEMSBSP, 323 378 [dnl 379 AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl 380 AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl 381 AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl 382 AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl 383 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 384 324 385 AC_MSG_CHECKING([for RTEMS_BSP]) 325 386 AC_CACHE_VAL(rtems_cv_RTEMS_BSP, … … 335 396 ]) 336 397 337 dnl $Id$338 339 dnl check if RTEMS support a cpu340 AC_DEFUN(RTEMS_CHECK_CPU,341 [dnl342 AC_REQUIRE([RTEMS_TOP])343 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])344 # Is this a supported CPU?345 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])346 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then347 AC_MSG_RESULT(yes)348 else349 AC_MSG_ERROR(no)350 fi351 ])dnl352 353 354 dnl $Id$355 356 AC_DEFUN(RTEMS_CANONICAL_HOST,357 [dnl358 AC_REQUIRE([AC_CANONICAL_HOST])359 RTEMS_HOST=$host_os360 changequote(,)dnl361 case "${target}" in362 # hpux unix port should go here363 i[3456]86-pc-linux*) # unix "simulator" port364 RTEMS_HOST=Linux365 ;;366 i[3456]86-*freebsd2*) # unix "simulator" port367 RTEMS_HOST=FreeBSD368 ;;369 sparc-sun-solaris*) # unix "simulator" port370 RTEMS_HOST=Solaris371 ;;372 *)373 ;;374 esac375 changequote([,])dnl376 AC_SUBST(RTEMS_HOST)377 ])dnl378 379 398 dnl 380 399 dnl $Id$ … … 399 418 PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex" 400 419 AC_SUBST(PACKHEX) 401 ])402 403 404 dnl405 dnl $Id$406 dnl407 dnl Check for target gcc408 dnl409 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)410 dnl Completely reworked411 412 AC_DEFUN(RTEMS_PROG_CC,413 [414 AC_BEFORE([$0], [AC_PROG_CPP])dnl415 AC_BEFORE([$0], [AC_PROG_CC])dnl416 AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl417 418 dnl Only accept gcc and cc419 dnl NOTE: This might be too restrictive for native compilation420 AC_PATH_PROGS(CC_FOR_TARGET, "$program_prefix"gcc "$program_prefix"cc )421 test -z "$CC_FOR_TARGET" \422 && AC_MSG_ERROR([no acceptable cc found in \$PATH])423 424 dnl backup425 rtems_save_CC=$CC426 rtems_save_CFLAGS=$CFLAGS427 428 dnl temporarily set CC429 CC=$CC_FOR_TARGET430 431 AC_PROG_CC_WORKS432 AC_PROG_CC_GNU433 434 if test $ac_cv_prog_gcc = yes; then435 GCC=yes436 dnl Check whether -g works, even if CFLAGS is set, in case the package437 dnl plays around with CFLAGS (such as to build both debugging and438 dnl normal versions of a library), tasteless as that idea is.439 ac_test_CFLAGS="${CFLAGS+set}"440 ac_save_CFLAGS="$CFLAGS"441 CFLAGS=442 AC_PROG_CC_G443 if test "$ac_test_CFLAGS" = set; then444 CFLAGS="$ac_save_CFLAGS"445 elif test $ac_cv_prog_cc_g = yes; then446 CFLAGS="-g -O2"447 else448 CFLAGS="-O2"449 fi450 else451 GCC=452 test "${CFLAGS+set}" = set || CFLAGS="-g"453 fi454 455 rtems_cv_prog_gcc=$ac_cv_prog_gcc456 rtems_cv_prog_cc_g=$ac_cv_prog_cc_g457 rtems_cv_prog_cc_works=$ac_cv_prog_cc_works458 rtems_cv_prog_cc_cross=$ac_cv_prog_cc_cross459 460 dnl restore initial values461 CC=$rtems_save_CC462 CFLAGS=$rtems_save_CFLAGS463 464 unset ac_cv_prog_gcc465 unset ac_cv_prog_cc_g466 unset ac_cv_prog_cc_works467 unset ac_cv_prog_cc_cross468 ])469 470 AC_DEFUN(RTEMS_PROG_CC_FOR_TARGET,471 [472 dnl check target cc473 RTEMS_PROG_CC474 dnl check if the compiler supports --specs475 RTEMS_GCC_SPECS476 dnl check if the target compiler may use --pipe477 RTEMS_GCC_PIPE478 dnl check if the compiler supports --specs if gcc28 is requested479 if test "$RTEMS_USE_GCC272" != "yes" ; then480 if test "$rtems_cv_gcc_specs" = "no"; then481 AC_MSG_WARN([*** disabling --enable-gcc28])482 RTEMS_USE_GCC272=yes483 fi484 fi485 test "$rtems_cv_gcc_pipe" = "yes" && CC_FOR_TARGET="$CC_FOR_TARGET --pipe"486 487 dnl FIXME: HACK for egcs/cygwin mixing '\\' and '/' in gcc -print-*488 case $host_os in489 *cygwin*) GCCSED="| sed 's%\\\\%/%g'" ;;490 *) ;;491 esac492 AC_SUBST(GCCSED)493 ])494 495 dnl496 dnl $Id$497 dnl498 dnl Set program_prefix499 dnl500 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)501 dnl Extracted from configure502 503 AC_DEFUN(RTEMS_TOOL_PREFIX,504 [AC_REQUIRE([AC_CANONICAL_TARGET])dnl505 AC_REQUIRE([AC_CANONICAL_BUILD])dnl506 507 changequote(,)dnl508 if [ "${program_prefix}" = "NONE" ] ; then509 if [ "${target}" = "${host}" ] ; then510 program_prefix=511 else512 program_prefix=${target}-513 fi514 fi515 changequote([,])dnl516 ])517 518 dnl519 dnl $Id$520 dnl521 dnl Check whether the target compiler accepts -specs522 dnl523 dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de524 dnl525 526 AC_DEFUN(RTEMS_GCC_SPECS,527 [AC_REQUIRE([RTEMS_PROG_CC])528 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,529 [530 rtems_cv_gcc_specs=no531 if test "$rtems_cv_prog_gcc" = "yes"; then532 touch confspec533 echo 'void f(){}' >conftest.c534 if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then535 rtems_cv_gcc_specs=yes536 fi537 fi538 rm -f confspec conftest*539 ])])540 541 dnl542 dnl $Id$543 dnl544 dnl Check whether the target compiler accepts -pipe545 dnl546 dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de547 dnl548 549 AC_DEFUN(RTEMS_GCC_PIPE,550 [AC_REQUIRE([RTEMS_PROG_CC])551 AC_REQUIRE([AC_CANONICAL_HOST])552 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,553 [554 rtems_cv_gcc_pipe=no555 if test "$rtems_cv_prog_gcc" = "yes"; then556 case "$host_os" in557 cygwin*)558 ;;559 *)560 echo 'void f(){}' >conftest.c561 if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then562 rtems_cv_gcc_pipe=yes563 fi564 rm -f conftest*565 ;;566 esac567 fi568 ])569 ])570 571 dnl572 dnl $Id$573 dnl574 dnl Set target tools575 dnl576 dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)577 dnl fixing cache/environment variable handling578 dnl adding checks for cygwin/egcs '\\'-bug579 dnl adding checks for ranlib/ar -s problem580 dnl581 dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)582 dnl583 584 AC_DEFUN(RTEMS_GCC_PRINT,585 [ case $host_os in586 *cygwin*)587 dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'588 dnl Should be removed once cygwin/egcs reports '/' only589 $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `590 ;;591 *)592 $1=`$CC_FOR_TARGET --print-prog-name=$2`593 ;;594 esac595 ])596 597 AC_DEFUN(RTEMS_PATH_TOOL,598 [599 AC_MSG_CHECKING([target's $2])600 AC_CACHE_VAL(ac_cv_path_$1,:)601 AC_MSG_RESULT([$ac_cv_path_$1])602 603 if test -n "$ac_cv_path_$1"; then604 dnl retrieve the value from the cache605 $1=$ac_cv_path_$1606 else607 dnl the cache was not set608 if test -z "[$]$1" ; then609 if test "$rtems_cv_prog_gcc" = "yes"; then610 # We are using gcc, ask it about its tool611 # NOTE: Necessary if gcc was configured to use the target's612 # native tools or uses prefixes for gnutools (e.g. gas instead of as)613 RTEMS_GCC_PRINT($1,$2)614 fi615 else616 # The user set an environment variable.617 # Check whether it is an absolute path, otherwise AC_PATH_PROG618 # will override the environment variable, which isn't what the user619 # intends620 AC_MSG_CHECKING([whether environment variable $1 is an absolute path])621 case "[$]$1" in622 /*) # valid623 AC_MSG_RESULT("yes")624 ;;625 *) # invalid for AC_PATH_PROG626 AC_MSG_RESULT("no")627 AC_MSG_ERROR([***]628 [Environment variable $1 should either]629 [be unset (preferred) or contain an absolute path])630 ;;631 esac632 fi633 634 AC_PATH_PROG($1,"$program_prefix"$2,$3)635 fi636 ])637 638 AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,639 [AC_REQUIRE([RTEMS_PROG_CC])dnl640 641 dnl FIXME: What shall be done if these tools are not available?642 RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)643 RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)644 RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)645 RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)646 647 dnl special treatment of ranlib648 RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)649 if test "$RANLIB_FOR_TARGET" = "no"; then650 # ranlib wasn't found; check if ar -s is available651 RTEMS_AR_FOR_TARGET_S652 if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then653 dnl override RANLIB_FOR_TARGET's cache654 ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"655 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET656 else657 AC_MSG_ERROR([***]658 [Can't figure out how to build a library index]659 [Neither ranlib nor ar -s seem to be available] )660 fi661 fi662 663 dnl NOTE: These may not be available if not using gnutools664 RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)665 RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)666 RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)667 ])668 669 dnl670 dnl $Id$671 dnl672 673 AC_DEFUN(RTEMS_AR_FOR_TARGET_S,674 [675 AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,676 rtems_cv_AR_FOR_TARGET_S,677 [678 cat > conftest.$ac_ext <<EOF679 int foo( int b )680 { return b; }681 EOF682 if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \683 && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \684 && test -s conftest.a ; \685 then686 rtems_cv_AR_FOR_TARGET_S="yes"687 else688 rtems_cv_AR_FOR_TARGET_S="no"689 fi690 rm -f conftest*691 ])692 ])693 694 695 dnl $Id$696 697 AC_DEFUN(RTEMS_CHECK_NEWLIB,698 [dnl699 AC_REQUIRE([RTEMS_PROG_CC_FOR_TARGET])dnl700 AC_REQUIRE([RTEMS_CANONICALIZE_TOOLS])dnl701 AC_CACHE_CHECK([for newlib],702 rtems_cv_use_newlib,703 [704 rtems_save_CC=$CC705 CC=$CC_FOR_TARGET706 707 dnl some versions of newlib provide not_required_by_rtems708 AC_TRY_LINK(709 [extern int not_required_by_rtems() ;],710 [not_required_by_rtems()],711 rtems_cv_use_newlib="yes")712 713 dnl older versions of newlib provided rtems_provides_crt0714 if test -z "$rtems_cv_use_newlib"; then715 AC_TRY_LINK(716 [extern int rtems_provides_crt0 ;],717 [rtems_provides_crt0 = 0],718 rtems_cv_use_newlib="yes",719 rtems_cv_use_newlib="no")720 fi721 CC=$rtems_save_CC])722 RTEMS_USE_NEWLIB="$rtems_cv_use_newlib"723 AC_SUBST(RTEMS_USE_NEWLIB)724 420 ]) 725 421 … … 766 462 AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP, 767 463 [dnl 464 AC_REQUIRE([RTEMS_TOP]) 465 768 466 AC_MSG_CHECKING([for make/custom/[$]$1.cfg]) 769 467 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then … … 782 480 AC_REQUIRE([RTEMS_TOP])dnl 783 481 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 482 AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl 483 784 484 AC_CACHE_CHECK([whether BSP supports multiprocessing], 785 485 rtems_cv_HAS_MP, … … 803 503 804 504 dnl $Id$ 805 dnl 806 AC_DEFUN(RTEMS_CHECK_POSIX_API, 807 [dnl 808 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 809 AC_CACHE_CHECK([whether BSP supports libposix], 810 rtems_cv_HAS_POSIX_API, 811 [dnl 812 case "$RTEMS_CPU" in 813 unix*) 814 rtems_cv_HAS_POSIX_API="no" 815 ;; 816 *) 817 if test "${RTEMS_HAS_POSIX_API}" = "yes"; then 818 rtems_cv_HAS_POSIX_API="yes"; 819 else 820 rtems_cv_HAS_POSIX_API="disabled"; 821 fi 822 ;; 823 esac]) 824 if test "$rtems_cv_HAS_POSIX_API" = "yes"; then 825 HAS_POSIX_API="yes"; 826 else 827 HAS_POSIX_API="no"; 828 fi 829 AC_SUBST(HAS_POSIX_API)dnl 830 ]) 831 505 506 AC_DEFUN(RTEMS_CANONICAL_HOST, 507 [dnl 508 AC_REQUIRE([AC_CANONICAL_HOST]) 509 RTEMS_HOST=$host_os 510 changequote(,)dnl 511 case "${target}" in 512 # hpux unix port should go here 513 i[3456]86-pc-linux*) # unix "simulator" port 514 RTEMS_HOST=Linux 515 ;; 516 i[3456]86-*freebsd2*) # unix "simulator" port 517 RTEMS_HOST=FreeBSD 518 ;; 519 sparc-sun-solaris*) # unix "simulator" port 520 RTEMS_HOST=Solaris 521 ;; 522 *) 523 ;; 524 esac 525 changequote([,])dnl 526 AC_SUBST(RTEMS_HOST) 527 ])dnl 528 529 dnl 530 dnl $Id$ 531 dnl 532 dnl Check for target gcc 533 dnl 534 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 535 dnl Completely reworked 536 537 AC_DEFUN(RTEMS_PROG_CC, 538 [ 539 AC_BEFORE([$0], [AC_PROG_CPP])dnl 540 AC_BEFORE([$0], [AC_PROG_CC])dnl 541 AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl 542 AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl 543 544 dnl Only accept gcc and cc 545 dnl NOTE: This might be too restrictive for native compilation 546 AC_PATH_PROGS(CC_FOR_TARGET, "$program_prefix"gcc "$program_prefix"cc ) 547 test -z "$CC_FOR_TARGET" \ 548 && AC_MSG_ERROR([no acceptable cc found in \$PATH]) 549 550 dnl backup 551 rtems_save_CC=$CC 552 rtems_save_CFLAGS=$CFLAGS 553 554 dnl temporarily set CC 555 CC=$CC_FOR_TARGET 556 557 AC_PROG_CC_WORKS 558 AC_PROG_CC_GNU 559 560 if test $ac_cv_prog_gcc = yes; then 561 GCC=yes 562 dnl Check whether -g works, even if CFLAGS is set, in case the package 563 dnl plays around with CFLAGS (such as to build both debugging and 564 dnl normal versions of a library), tasteless as that idea is. 565 ac_test_CFLAGS="${CFLAGS+set}" 566 ac_save_CFLAGS="$CFLAGS" 567 CFLAGS= 568 AC_PROG_CC_G 569 if test "$ac_test_CFLAGS" = set; then 570 CFLAGS="$ac_save_CFLAGS" 571 elif test $ac_cv_prog_cc_g = yes; then 572 CFLAGS="-g -O2" 573 else 574 CFLAGS="-O2" 575 fi 576 else 577 GCC= 578 test "${CFLAGS+set}" = set || CFLAGS="-g" 579 fi 580 581 rtems_cv_prog_gcc=$ac_cv_prog_gcc 582 rtems_cv_prog_cc_g=$ac_cv_prog_cc_g 583 rtems_cv_prog_cc_works=$ac_cv_prog_cc_works 584 rtems_cv_prog_cc_cross=$ac_cv_prog_cc_cross 585 586 dnl restore initial values 587 CC=$rtems_save_CC 588 CFLAGS=$rtems_save_CFLAGS 589 590 unset ac_cv_prog_gcc 591 unset ac_cv_prog_cc_g 592 unset ac_cv_prog_cc_works 593 unset ac_cv_prog_cc_cross 594 ]) 595 596 AC_DEFUN(RTEMS_PROG_CC_FOR_TARGET, 597 [ 598 dnl check target cc 599 RTEMS_PROG_CC 600 dnl check if the compiler supports --specs 601 RTEMS_GCC_SPECS 602 dnl check if the target compiler may use --pipe 603 RTEMS_GCC_PIPE 604 dnl check if the compiler supports --specs if gcc28 is requested 605 if test "$RTEMS_USE_GCC272" != "yes" ; then 606 if test "$rtems_cv_gcc_specs" = "no"; then 607 AC_MSG_WARN([*** disabling --enable-gcc28]) 608 RTEMS_USE_GCC272=yes 609 fi 610 fi 611 test "$rtems_cv_gcc_pipe" = "yes" && CC_FOR_TARGET="$CC_FOR_TARGET --pipe" 612 613 dnl FIXME: HACK for egcs/cygwin mixing '\\' and '/' in gcc -print-* 614 case $host_os in 615 *cygwin*) GCCSED="| sed 's%\\\\%/%g'" ;; 616 *) ;; 617 esac 618 AC_SUBST(GCCSED) 619 ]) 620 621 dnl 622 dnl $Id$ 623 dnl 624 dnl Set target tools 625 dnl 626 dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 627 dnl fixing cache/environment variable handling 628 dnl adding checks for cygwin/egcs '\\'-bug 629 dnl adding checks for ranlib/ar -s problem 630 dnl 631 dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 632 dnl 633 634 AC_DEFUN(RTEMS_GCC_PRINT, 635 [ case $host_os in 636 *cygwin*) 637 dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/' 638 dnl Should be removed once cygwin/egcs reports '/' only 639 $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' ` 640 ;; 641 *) 642 $1=`$CC_FOR_TARGET --print-prog-name=$2` 643 ;; 644 esac 645 ]) 646 647 AC_DEFUN(RTEMS_PATH_TOOL, 648 [ 649 AC_MSG_CHECKING([target's $2]) 650 AC_CACHE_VAL(ac_cv_path_$1,:) 651 AC_MSG_RESULT([$ac_cv_path_$1]) 652 653 if test -n "$ac_cv_path_$1"; then 654 dnl retrieve the value from the cache 655 $1=$ac_cv_path_$1 656 else 657 dnl the cache was not set 658 if test -z "[$]$1" ; then 659 if test "$rtems_cv_prog_gcc" = "yes"; then 660 # We are using gcc, ask it about its tool 661 # NOTE: Necessary if gcc was configured to use the target's 662 # native tools or uses prefixes for gnutools (e.g. gas instead of as) 663 RTEMS_GCC_PRINT($1,$2) 664 fi 665 else 666 # The user set an environment variable. 667 # Check whether it is an absolute path, otherwise AC_PATH_PROG 668 # will override the environment variable, which isn't what the user 669 # intends 670 AC_MSG_CHECKING([whether environment variable $1 is an absolute path]) 671 case "[$]$1" in 672 /*) # valid 673 AC_MSG_RESULT("yes") 674 ;; 675 *) # invalid for AC_PATH_PROG 676 AC_MSG_RESULT("no") 677 AC_MSG_ERROR([***] 678 [Environment variable $1 should either] 679 [be unset (preferred) or contain an absolute path]) 680 ;; 681 esac 682 fi 683 684 AC_PATH_PROG($1,"$program_prefix"$2,$3) 685 fi 686 ]) 687 688 AC_DEFUN(RTEMS_CANONICALIZE_TOOLS, 689 [AC_REQUIRE([RTEMS_PROG_CC])dnl 690 691 dnl FIXME: What shall be done if these tools are not available? 692 RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no) 693 RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no) 694 RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no) 695 RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no) 696 697 dnl special treatment of ranlib 698 RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no) 699 if test "$RANLIB_FOR_TARGET" = "no"; then 700 # ranlib wasn't found; check if ar -s is available 701 RTEMS_AR_FOR_TARGET_S 702 if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then 703 dnl override RANLIB_FOR_TARGET's cache 704 ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s" 705 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET 706 else 707 AC_MSG_ERROR([***] 708 [Can't figure out how to build a library index] 709 [Neither ranlib nor ar -s seem to be available] ) 710 fi 711 fi 712 713 dnl NOTE: These may not be available if not using gnutools 714 RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no) 715 RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no) 716 RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no) 717 ]) 718 719 dnl 720 dnl $Id$ 721 dnl 722 723 AC_DEFUN(RTEMS_AR_FOR_TARGET_S, 724 [ 725 AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works, 726 rtems_cv_AR_FOR_TARGET_S, 727 [ 728 cat > conftest.$ac_ext <<EOF 729 int foo( int b ) 730 { return b; } 731 EOF 732 if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \ 733 && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \ 734 && test -s conftest.a ; \ 735 then 736 rtems_cv_AR_FOR_TARGET_S="yes" 737 else 738 rtems_cv_AR_FOR_TARGET_S="no" 739 fi 740 rm -f conftest* 741 ]) 742 ]) 743 744 745 dnl 746 dnl $Id$ 747 dnl 748 dnl Set program_prefix 749 dnl 750 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 751 dnl Extracted from configure 752 753 AC_DEFUN(RTEMS_TOOL_PREFIX, 754 [AC_REQUIRE([AC_CANONICAL_TARGET])dnl 755 AC_REQUIRE([AC_CANONICAL_BUILD])dnl 756 757 changequote(,)dnl 758 if [ "${program_prefix}" = "NONE" ] ; then 759 if [ "${target}" = "${host}" ] ; then 760 program_prefix= 761 else 762 program_prefix=${target}- 763 fi 764 fi 765 changequote([,])dnl 766 ]) 767 768 dnl 769 dnl $Id$ 770 dnl 771 dnl Check whether the target compiler accepts -specs 772 dnl 773 774 AC_DEFUN(RTEMS_GCC_SPECS, 775 [AC_REQUIRE([RTEMS_PROG_CC]) 776 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs, 777 [ 778 rtems_cv_gcc_specs=no 779 if test "$rtems_cv_prog_gcc" = "yes"; then 780 touch confspec 781 echo 'void f(){}' >conftest.c 782 if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then 783 rtems_cv_gcc_specs=yes 784 fi 785 fi 786 rm -f confspec conftest* 787 ])]) 788 789 dnl 790 dnl $Id$ 791 dnl 792 dnl Check whether the target compiler accepts -pipe 793 dnl 794 dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de 795 dnl 796 797 AC_DEFUN(RTEMS_GCC_PIPE, 798 [AC_REQUIRE([RTEMS_PROG_CC]) 799 AC_REQUIRE([AC_CANONICAL_HOST]) 800 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe, 801 [ 802 rtems_cv_gcc_pipe=no 803 if test "$rtems_cv_prog_gcc" = "yes"; then 804 case "$host_os" in 805 cygwin*) 806 ;; 807 *) 808 echo 'void f(){}' >conftest.c 809 if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then 810 rtems_cv_gcc_pipe=yes 811 fi 812 rm -f conftest* 813 ;; 814 esac 815 fi 816 ]) 817 ]) 818 819 dnl $Id$ 820 821 AC_DEFUN(RTEMS_CHECK_NEWLIB, 822 [dnl 823 AC_REQUIRE([RTEMS_PROG_CC_FOR_TARGET])dnl 824 AC_REQUIRE([RTEMS_CANONICALIZE_TOOLS])dnl 825 AC_CACHE_CHECK([for newlib], 826 rtems_cv_use_newlib, 827 [ 828 rtems_save_CC=$CC 829 CC=$CC_FOR_TARGET 830 831 dnl some versions of newlib provide not_required_by_rtems 832 AC_TRY_LINK( 833 [extern int not_required_by_rtems() ;], 834 [not_required_by_rtems()], 835 rtems_cv_use_newlib="yes") 836 837 dnl older versions of newlib provided rtems_provides_crt0 838 if test -z "$rtems_cv_use_newlib"; then 839 AC_TRY_LINK( 840 [extern int rtems_provides_crt0 ;], 841 [rtems_provides_crt0 = 0], 842 rtems_cv_use_newlib="yes", 843 rtems_cv_use_newlib="no") 844 fi 845 CC=$rtems_save_CC]) 846 RTEMS_USE_NEWLIB="$rtems_cv_use_newlib" 847 AC_SUBST(RTEMS_USE_NEWLIB) 848 ]) 849 850 -
c/src/exec/configure
rd83c39dc r4075af6f 538 538 539 539 540 540 541 # Check whether --with-target-subdir or --without-target-subdir was given. 541 542 if test "${with_target_subdir+set}" = set; then … … 551 552 552 553 echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6 553 echo "configure:55 4: checking for RTEMS Version" >&5554 echo "configure:555: checking for RTEMS Version" >&5 554 555 if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then 555 556 RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \ … … 612 613 613 614 echo $ac_n "checking host system type""... $ac_c" 1>&6 614 echo "configure:61 5: checking host system type" >&5615 echo "configure:616: checking host system type" >&5 615 616 616 617 host_alias=$host … … 633 634 634 635 echo $ac_n "checking target system type""... $ac_c" 1>&6 635 echo "configure:63 6: checking target system type" >&5636 echo "configure:637: checking target system type" >&5 636 637 637 638 target_alias=$target … … 651 652 652 653 echo $ac_n "checking build system type""... $ac_c" 1>&6 653 echo "configure:65 4: checking build system type" >&5654 echo "configure:655: checking build system type" >&5 654 655 655 656 build_alias=$build … … 674 675 675 676 echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6 676 echo "configure:67 7: checking rtems target cpu" >&5677 echo "configure:678: checking rtems target cpu" >&5 677 678 case "${target}" in 678 679 # hpux unix port should go here … … 712 713 # ./install, which can be erroneously created by make from ./install.sh. 713 714 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 714 echo "configure:71 5: checking for a BSD compatible install" >&5715 echo "configure:716: checking for a BSD compatible install" >&5 715 716 if test -z "$INSTALL"; then 716 717 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then … … 765 766 766 767 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6 767 echo "configure:76 8: checking whether build environment is sane" >&5768 echo "configure:769: checking whether build environment is sane" >&5 768 769 # Just in case 769 770 sleep 1 … … 822 823 823 824 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 824 echo "configure:82 5: checking whether ${MAKE-make} sets \${MAKE}" >&5825 echo "configure:826: checking whether ${MAKE-make} sets \${MAKE}" >&5 825 826 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` 826 827 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then … … 862 863 missing_dir=`cd $ac_aux_dir && pwd` 863 864 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6 864 echo "configure:86 5: checking for working aclocal" >&5865 echo "configure:866: checking for working aclocal" >&5 865 866 # Run test in a subshell; some versions of sh will print an error if 866 867 # an executable is not found, even if stderr is redirected. … … 875 876 876 877 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6 877 echo "configure:87 8: checking for working autoconf" >&5878 echo "configure:879: checking for working autoconf" >&5 878 879 # Run test in a subshell; some versions of sh will print an error if 879 880 # an executable is not found, even if stderr is redirected. … … 888 889 889 890 echo $ac_n "checking for working automake""... $ac_c" 1>&6 890 echo "configure:89 1: checking for working automake" >&5891 echo "configure:892: checking for working automake" >&5 891 892 # Run test in a subshell; some versions of sh will print an error if 892 893 # an executable is not found, even if stderr is redirected. … … 901 902 902 903 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6 903 echo "configure:90 4: checking for working autoheader" >&5904 echo "configure:905: checking for working autoheader" >&5 904 905 # Run test in a subshell; some versions of sh will print an error if 905 906 # an executable is not found, even if stderr is redirected. … … 914 915 915 916 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6 916 echo "configure:91 7: checking for working makeinfo" >&5917 echo "configure:918: checking for working makeinfo" >&5 917 918 # Run test in a subshell; some versions of sh will print an error if 918 919 # an executable is not found, even if stderr is redirected. … … 928 929 929 930 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 930 echo "configure:93 1: checking whether to enable maintainer-specific portions of Makefiles" >&5931 echo "configure:932: checking whether to enable maintainer-specific portions of Makefiles" >&5 931 932 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. 932 933 if test "${enable_maintainer_mode+set}" = set; then … … 962 963 RTEMS_HAS_MULTIPROCESSING=no 963 964 fi 965 964 966 965 967 … … 1038 1040 1039 1041 1042 1040 1043 echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6 1041 echo "configure:104 2: checking for RTEMS_BSP" >&51044 echo "configure:1045: checking for RTEMS_BSP" >&5 1042 1045 if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then 1043 1046 echo $ac_n "(cached) $ac_c" 1>&6 … … 1056 1059 1057 1060 1061 1058 1062 # Is this a supported CPU? 1059 1063 echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6 1060 echo "configure:106 1: checking if cpu $RTEMS_CPU is supported" >&51064 echo "configure:1065: checking if cpu $RTEMS_CPU is supported" >&5 1061 1065 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 1062 1066 echo "$ac_t""yes" 1>&6 … … 1119 1123 set dummy $ac_prog; ac_word=$2 1120 1124 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1121 echo "configure:112 2: checking for $ac_word" >&51125 echo "configure:1126: checking for $ac_word" >&5 1122 1126 if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then 1123 1127 echo $ac_n "(cached) $ac_c" 1>&6 … … 1163 1167 1164 1168 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 1165 echo "configure:11 66: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&51169 echo "configure:1170: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 1166 1170 1167 1171 ac_ext=c … … 1174 1178 cat > conftest.$ac_ext << EOF 1175 1179 1176 #line 11 77"configure"1180 #line 1181 "configure" 1177 1181 #include "confdefs.h" 1178 1182 1179 1183 main(){return(0);} 1180 1184 EOF 1181 if { (eval echo configure:118 2: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then1185 if { (eval echo configure:1186: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1182 1186 ac_cv_prog_cc_works=yes 1183 1187 # If we can't run a trivial program, we are probably using a cross compiler. … … 1205 1209 fi 1206 1210 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 1207 echo "configure:12 08: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&51211 echo "configure:1212: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 1208 1212 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 1209 1213 cross_compiling=$ac_cv_prog_cc_cross 1210 1214 1211 1215 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 1212 echo "configure:121 3: checking whether we are using GNU C" >&51216 echo "configure:1217: checking whether we are using GNU C" >&5 1213 1217 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then 1214 1218 echo $ac_n "(cached) $ac_c" 1>&6 … … 1219 1223 #endif 1220 1224 EOF 1221 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:122 2: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then1225 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1226: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then 1222 1226 ac_cv_prog_gcc=yes 1223 1227 else … … 1234 1238 CFLAGS= 1235 1239 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 1236 echo "configure:12 37: checking whether ${CC-cc} accepts -g" >&51240 echo "configure:1241: checking whether ${CC-cc} accepts -g" >&5 1237 1241 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then 1238 1242 echo $ac_n "(cached) $ac_c" 1>&6 … … 1276 1280 1277 1281 echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6 1278 echo "configure:12 79: checking whether $CC_FOR_TARGET accepts -specs" >&51282 echo "configure:1283: checking whether $CC_FOR_TARGET accepts -specs" >&5 1279 1283 if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then 1280 1284 echo $ac_n "(cached) $ac_c" 1>&6 … … 1297 1301 1298 1302 echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6 1299 echo "configure:130 0: checking whether $CC_FOR_TARGET accepts --pipe" >&51303 echo "configure:1304: checking whether $CC_FOR_TARGET accepts --pipe" >&5 1300 1304 if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then 1301 1305 echo $ac_n "(cached) $ac_c" 1>&6 … … 1338 1342 1339 1343 echo $ac_n "checking target's ar""... $ac_c" 1>&6 1340 echo "configure:134 1: checking target's ar" >&51344 echo "configure:1345: checking target's ar" >&5 1341 1345 if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then 1342 1346 echo $ac_n "(cached) $ac_c" 1>&6 … … 1371 1375 # intends 1372 1376 echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1373 echo "configure:137 4: checking whether environment variable AR_FOR_TARGET is an absolute path" >&51377 echo "configure:1378: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5 1374 1378 case "$AR_FOR_TARGET" in 1375 1379 /*) # valid … … 1388 1392 set dummy "$program_prefix"ar; ac_word=$2 1389 1393 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1390 echo "configure:139 1: checking for $ac_word" >&51394 echo "configure:1395: checking for $ac_word" >&5 1391 1395 if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then 1392 1396 echo $ac_n "(cached) $ac_c" 1>&6 … … 1425 1429 1426 1430 echo $ac_n "checking target's as""... $ac_c" 1>&6 1427 echo "configure:14 28: checking target's as" >&51431 echo "configure:1432: checking target's as" >&5 1428 1432 if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then 1429 1433 echo $ac_n "(cached) $ac_c" 1>&6 … … 1458 1462 # intends 1459 1463 echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1460 echo "configure:146 1: checking whether environment variable AS_FOR_TARGET is an absolute path" >&51464 echo "configure:1465: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5 1461 1465 case "$AS_FOR_TARGET" in 1462 1466 /*) # valid … … 1475 1479 set dummy "$program_prefix"as; ac_word=$2 1476 1480 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1477 echo "configure:14 78: checking for $ac_word" >&51481 echo "configure:1482: checking for $ac_word" >&5 1478 1482 if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then 1479 1483 echo $ac_n "(cached) $ac_c" 1>&6 … … 1512 1516 1513 1517 echo $ac_n "checking target's ld""... $ac_c" 1>&6 1514 echo "configure:151 5: checking target's ld" >&51518 echo "configure:1519: checking target's ld" >&5 1515 1519 if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then 1516 1520 echo $ac_n "(cached) $ac_c" 1>&6 … … 1545 1549 # intends 1546 1550 echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1547 echo "configure:15 48: checking whether environment variable LD_FOR_TARGET is an absolute path" >&51551 echo "configure:1552: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5 1548 1552 case "$LD_FOR_TARGET" in 1549 1553 /*) # valid … … 1562 1566 set dummy "$program_prefix"ld; ac_word=$2 1563 1567 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1564 echo "configure:156 5: checking for $ac_word" >&51568 echo "configure:1569: checking for $ac_word" >&5 1565 1569 if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then 1566 1570 echo $ac_n "(cached) $ac_c" 1>&6 … … 1599 1603 1600 1604 echo $ac_n "checking target's nm""... $ac_c" 1>&6 1601 echo "configure:160 2: checking target's nm" >&51605 echo "configure:1606: checking target's nm" >&5 1602 1606 if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then 1603 1607 echo $ac_n "(cached) $ac_c" 1>&6 … … 1632 1636 # intends 1633 1637 echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1634 echo "configure:163 5: checking whether environment variable NM_FOR_TARGET is an absolute path" >&51638 echo "configure:1639: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5 1635 1639 case "$NM_FOR_TARGET" in 1636 1640 /*) # valid … … 1649 1653 set dummy "$program_prefix"nm; ac_word=$2 1650 1654 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1651 echo "configure:165 2: checking for $ac_word" >&51655 echo "configure:1656: checking for $ac_word" >&5 1652 1656 if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then 1653 1657 echo $ac_n "(cached) $ac_c" 1>&6 … … 1687 1691 1688 1692 echo $ac_n "checking target's ranlib""... $ac_c" 1>&6 1689 echo "configure:169 0: checking target's ranlib" >&51693 echo "configure:1694: checking target's ranlib" >&5 1690 1694 if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then 1691 1695 echo $ac_n "(cached) $ac_c" 1>&6 … … 1720 1724 # intends 1721 1725 echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1722 echo "configure:172 3: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&51726 echo "configure:1727: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5 1723 1727 case "$RANLIB_FOR_TARGET" in 1724 1728 /*) # valid … … 1737 1741 set dummy "$program_prefix"ranlib; ac_word=$2 1738 1742 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1739 echo "configure:174 0: checking for $ac_word" >&51743 echo "configure:1744: checking for $ac_word" >&5 1740 1744 if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then 1741 1745 echo $ac_n "(cached) $ac_c" 1>&6 … … 1776 1780 1777 1781 echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6 1778 echo "configure:17 79: checking whether $AR_FOR_TARGET -s works" >&51782 echo "configure:1783: checking whether $AR_FOR_TARGET -s works" >&5 1779 1783 if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then 1780 1784 echo $ac_n "(cached) $ac_c" 1>&6 … … 1785 1789 { return b; } 1786 1790 EOF 1787 if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:17 88: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \1788 && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:17 89: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \1791 if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1792: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \ 1792 && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1793: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \ 1789 1793 && test -s conftest.a ; \ 1790 1794 then … … 1811 1815 1812 1816 echo $ac_n "checking target's objcopy""... $ac_c" 1>&6 1813 echo "configure:181 4: checking target's objcopy" >&51817 echo "configure:1818: checking target's objcopy" >&5 1814 1818 if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then 1815 1819 echo $ac_n "(cached) $ac_c" 1>&6 … … 1844 1848 # intends 1845 1849 echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1846 echo "configure:18 47: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&51850 echo "configure:1851: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5 1847 1851 case "$OBJCOPY_FOR_TARGET" in 1848 1852 /*) # valid … … 1861 1865 set dummy "$program_prefix"objcopy; ac_word=$2 1862 1866 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1863 echo "configure:186 4: checking for $ac_word" >&51867 echo "configure:1868: checking for $ac_word" >&5 1864 1868 if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then 1865 1869 echo $ac_n "(cached) $ac_c" 1>&6 … … 1898 1902 1899 1903 echo $ac_n "checking target's size""... $ac_c" 1>&6 1900 echo "configure:190 1: checking target's size" >&51904 echo "configure:1905: checking target's size" >&5 1901 1905 if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then 1902 1906 echo $ac_n "(cached) $ac_c" 1>&6 … … 1931 1935 # intends 1932 1936 echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1933 echo "configure:193 4: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&51937 echo "configure:1938: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5 1934 1938 case "$SIZE_FOR_TARGET" in 1935 1939 /*) # valid … … 1948 1952 set dummy "$program_prefix"size; ac_word=$2 1949 1953 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1950 echo "configure:195 1: checking for $ac_word" >&51954 echo "configure:1955: checking for $ac_word" >&5 1951 1955 if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then 1952 1956 echo $ac_n "(cached) $ac_c" 1>&6 … … 1985 1989 1986 1990 echo $ac_n "checking target's strip""... $ac_c" 1>&6 1987 echo "configure:19 88: checking target's strip" >&51991 echo "configure:1992: checking target's strip" >&5 1988 1992 if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then 1989 1993 echo $ac_n "(cached) $ac_c" 1>&6 … … 2018 2022 # intends 2019 2023 echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6 2020 echo "configure:202 1: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&52024 echo "configure:2025: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5 2021 2025 case "$STRIP_FOR_TARGET" in 2022 2026 /*) # valid … … 2035 2039 set dummy "$program_prefix"strip; ac_word=$2 2036 2040 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 2037 echo "configure:20 38: checking for $ac_word" >&52041 echo "configure:2042: checking for $ac_word" >&5 2038 2042 if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then 2039 2043 echo $ac_n "(cached) $ac_c" 1>&6 … … 2073 2077 2074 2078 echo $ac_n "checking for newlib""... $ac_c" 1>&6 2075 echo "configure:20 76: checking for newlib" >&52079 echo "configure:2080: checking for newlib" >&5 2076 2080 if eval "test \"`echo '$''{'rtems_cv_use_newlib'+set}'`\" = set"; then 2077 2081 echo $ac_n "(cached) $ac_c" 1>&6 … … 2082 2086 2083 2087 cat > conftest.$ac_ext <<EOF 2084 #line 208 5"configure"2088 #line 2089 "configure" 2085 2089 #include "confdefs.h" 2086 2090 extern int not_required_by_rtems() ; … … 2089 2093 ; return 0; } 2090 2094 EOF 2091 if { (eval echo configure:209 2: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then2095 if { (eval echo configure:2096: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 2092 2096 rm -rf conftest* 2093 2097 rtems_cv_use_newlib="yes" … … 2100 2104 if test -z "$rtems_cv_use_newlib"; then 2101 2105 cat > conftest.$ac_ext <<EOF 2102 #line 210 3"configure"2106 #line 2107 "configure" 2103 2107 #include "confdefs.h" 2104 2108 extern int rtems_provides_crt0 ; … … 2107 2111 ; return 0; } 2108 2112 EOF 2109 if { (eval echo configure:211 0: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then2113 if { (eval echo configure:2114: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 2110 2114 rm -rf conftest* 2111 2115 rtems_cv_use_newlib="yes" … … 2127 2131 2128 2132 # Check if there is custom/*.cfg for this BSP 2133 2134 2129 2135 echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6 2130 echo "configure:213 1: checking for make/custom/$RTEMS_BSP.cfg" >&52136 echo "configure:2137: checking for make/custom/$RTEMS_BSP.cfg" >&5 2131 2137 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then 2132 2138 echo "$ac_t""yes" 1>&6 … … 2135 2141 fi 2136 2142 2143 2137 2144 echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6 2138 echo "configure:21 39: checking whether BSP supports multiprocessing" >&52145 echo "configure:2146: checking whether BSP supports multiprocessing" >&5 2139 2146 if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then 2140 2147 echo $ac_n "(cached) $ac_c" 1>&6 … … 2159 2166 2160 2167 2168 2161 2169 echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6 2162 echo "configure:21 63: checking whether BSP supports libposix" >&52170 echo "configure:2171: checking whether BSP supports libposix" >&5 2163 2171 if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then 2164 2172 echo $ac_n "(cached) $ac_c" 1>&6 -
c/src/exec/posix/aclocal.m4
rd83c39dc r4075af6f 20 20 AC_DEFUN(RTEMS_TOP, 21 21 [dnl 22 AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl 23 AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl 24 22 25 AC_ARG_WITH(target-subdir, 23 26 [ --with-target-subdir=DIR], … … 44 47 AC_MSG_RESULT($RTEMS_VERSION) 45 48 ])dnl 46 47 dnl48 dnl $Id$49 dnl50 51 dnl canonicalize target cpu52 dnl NOTE: Most rtems targets do not fullfil autoconf's53 dnl target naming conventions "processor-vendor-os"54 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them55 dnl and we have to fix it for rtems ourselves56 57 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,58 [59 AC_CANONICAL_SYSTEM60 AC_MSG_CHECKING(rtems target cpu)61 changequote(,)dnl62 case "${target}" in63 # hpux unix port should go here64 i[3456]86-go32-rtems*)65 RTEMS_CPU=i38666 ;;67 i[3456]86-pc-linux*) # unix "simulator" port68 RTEMS_CPU=unix69 ;;70 i[3456]86-*freebsd2*) # unix "simulator" port71 RTEMS_CPU=unix72 ;;73 no_cpu-*rtems*)74 RTEMS_CPU=no_cpu75 ;;76 sparc-sun-solaris*) # unix "simulator" port77 RTEMS_CPU=unix78 ;;79 *)80 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'`81 ;;82 esac83 changequote([,])dnl84 AC_SUBST(RTEMS_CPU)85 AC_MSG_RESULT($RTEMS_CPU)86 ])87 49 88 50 # Do all the work for Automake. This macro actually does too much -- … … 180 142 AC_SUBST($1)]) 181 143 144 dnl 145 dnl $Id$ 146 dnl 147 148 dnl canonicalize target cpu 149 dnl NOTE: Most rtems targets do not fullfil autoconf's 150 dnl target naming conventions "processor-vendor-os" 151 dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them 152 dnl and we have to fix it for rtems ourselves 153 154 AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU, 155 [ 156 AC_CANONICAL_SYSTEM 157 AC_MSG_CHECKING(rtems target cpu) 158 changequote(,)dnl 159 case "${target}" in 160 # hpux unix port should go here 161 i[3456]86-go32-rtems*) 162 RTEMS_CPU=i386 163 ;; 164 i[3456]86-pc-linux*) # unix "simulator" port 165 RTEMS_CPU=unix 166 ;; 167 i[3456]86-*freebsd2*) # unix "simulator" port 168 RTEMS_CPU=unix 169 ;; 170 no_cpu-*rtems*) 171 RTEMS_CPU=no_cpu 172 ;; 173 sparc-sun-solaris*) # unix "simulator" port 174 RTEMS_CPU=unix 175 ;; 176 *) 177 RTEMS_CPU=`echo $target | sed 's%^\([^-]*\)-\(.*\)$%\1%'` 178 ;; 179 esac 180 changequote([,])dnl 181 AC_SUBST(RTEMS_CPU) 182 AC_MSG_RESULT($RTEMS_CPU) 183 ]) 184 182 185 # Add --enable-maintainer-mode option to configure. 183 186 # From Jim Meyering … … 231 234 AC_DEFUN(RTEMS_ENABLE_POSIX, 232 235 [ 236 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 237 233 238 AC_ARG_ENABLE(posix, 234 239 [ --enable-posix enable posix interface], … … 264 269 AC_SUBST(RTEMS_HAS_POSIX_API) 265 270 ]) 271 272 dnl $Id$ 273 dnl 274 AC_DEFUN(RTEMS_CHECK_POSIX_API, 275 [dnl 276 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 277 AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl 278 279 AC_CACHE_CHECK([whether BSP supports libposix], 280 rtems_cv_HAS_POSIX_API, 281 [dnl 282 case "$RTEMS_CPU" in 283 unix*) 284 rtems_cv_HAS_POSIX_API="no" 285 ;; 286 *) 287 if test "${RTEMS_HAS_POSIX_API}" = "yes"; then 288 rtems_cv_HAS_POSIX_API="yes"; 289 else 290 rtems_cv_HAS_POSIX_API="disabled"; 291 fi 292 ;; 293 esac]) 294 if test "$rtems_cv_HAS_POSIX_API" = "yes"; then 295 HAS_POSIX_API="yes"; 296 else 297 HAS_POSIX_API="no"; 298 fi 299 AC_SUBST(HAS_POSIX_API)dnl 300 ]) 301 302 dnl $Id$ 303 304 dnl check if RTEMS support a cpu 305 AC_DEFUN(RTEMS_CHECK_CPU, 306 [dnl 307 AC_REQUIRE([RTEMS_TOP]) 308 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU]) 309 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 310 311 # Is this a supported CPU? 312 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported]) 313 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 314 AC_MSG_RESULT(yes) 315 else 316 AC_MSG_ERROR(no) 317 fi 318 ])dnl 319 266 320 267 321 dnl $Id$ … … 286 340 AC_DEFUN(RTEMS_ENABLE_RTEMSBSP, 287 341 [ 342 AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl 288 343 AC_ARG_ENABLE(rtemsbsp, 289 344 [ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build], … … 298 353 AC_DEFUN(RTEMS_ENV_RTEMSBSP, 299 354 [dnl 355 AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl 356 AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl 357 AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl 358 AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl 359 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 360 300 361 AC_MSG_CHECKING([for RTEMS_BSP]) 301 362 AC_CACHE_VAL(rtems_cv_RTEMS_BSP, … … 311 372 ]) 312 373 313 dnl $Id$314 315 dnl check if RTEMS support a cpu316 AC_DEFUN(RTEMS_CHECK_CPU,317 [dnl318 AC_REQUIRE([RTEMS_TOP])319 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])320 # Is this a supported CPU?321 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])322 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then323 AC_MSG_RESULT(yes)324 else325 AC_MSG_ERROR(no)326 fi327 ])dnl328 329 330 dnl $Id$331 332 AC_DEFUN(RTEMS_CANONICAL_HOST,333 [dnl334 AC_REQUIRE([AC_CANONICAL_HOST])335 RTEMS_HOST=$host_os336 changequote(,)dnl337 case "${target}" in338 # hpux unix port should go here339 i[3456]86-pc-linux*) # unix "simulator" port340 RTEMS_HOST=Linux341 ;;342 i[3456]86-*freebsd2*) # unix "simulator" port343 RTEMS_HOST=FreeBSD344 ;;345 sparc-sun-solaris*) # unix "simulator" port346 RTEMS_HOST=Solaris347 ;;348 *)349 ;;350 esac351 changequote([,])dnl352 AC_SUBST(RTEMS_HOST)353 ])dnl354 355 374 dnl 356 375 dnl $Id$ … … 375 394 PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex" 376 395 AC_SUBST(PACKHEX) 377 ])378 379 380 dnl $Id$381 382 AC_DEFUN(RTEMS_PATH_KSH,383 [384 dnl NOTE: prefer bash over ksh over sh385 AC_PATH_PROGS(KSH,bash ksh sh)386 if test -z "$KSH"; then387 dnl NOTE: This cannot happen -- /bin/sh must always exist388 AC_MSG_ERROR(389 [***]390 [ Cannot determine a usable shell bash/ksh/sh]391 [ Please contact your system administrator] );392 fi393 ])394 395 dnl396 dnl $Id$397 dnl398 dnl Check for target gcc399 dnl400 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)401 dnl Completely reworked402 403 AC_DEFUN(RTEMS_PROG_CC,404 [405 AC_BEFORE([$0], [AC_PROG_CPP])dnl406 AC_BEFORE([$0], [AC_PROG_CC])dnl407 AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl408 409 dnl Only accept gcc and cc410 dnl NOTE: This might be too restrictive for native compilation411 AC_PATH_PROGS(CC_FOR_TARGET, "$program_prefix"gcc "$program_prefix"cc )412 test -z "$CC_FOR_TARGET" \413 && AC_MSG_ERROR([no acceptable cc found in \$PATH])414 415 dnl backup416 rtems_save_CC=$CC417 rtems_save_CFLAGS=$CFLAGS418 419 dnl temporarily set CC420 CC=$CC_FOR_TARGET421 422 AC_PROG_CC_WORKS423 AC_PROG_CC_GNU424 425 if test $ac_cv_prog_gcc = yes; then426 GCC=yes427 dnl Check whether -g works, even if CFLAGS is set, in case the package428 dnl plays around with CFLAGS (such as to build both debugging and429 dnl normal versions of a library), tasteless as that idea is.430 ac_test_CFLAGS="${CFLAGS+set}"431 ac_save_CFLAGS="$CFLAGS"432 CFLAGS=433 AC_PROG_CC_G434 if test "$ac_test_CFLAGS" = set; then435 CFLAGS="$ac_save_CFLAGS"436 elif test $ac_cv_prog_cc_g = yes; then437 CFLAGS="-g -O2"438 else439 CFLAGS="-O2"440 fi441 else442 GCC=443 test "${CFLAGS+set}" = set || CFLAGS="-g"444 fi445 446 rtems_cv_prog_gcc=$ac_cv_prog_gcc447 rtems_cv_prog_cc_g=$ac_cv_prog_cc_g448 rtems_cv_prog_cc_works=$ac_cv_prog_cc_works449 rtems_cv_prog_cc_cross=$ac_cv_prog_cc_cross450 451 dnl restore initial values452 CC=$rtems_save_CC453 CFLAGS=$rtems_save_CFLAGS454 455 unset ac_cv_prog_gcc456 unset ac_cv_prog_cc_g457 unset ac_cv_prog_cc_works458 unset ac_cv_prog_cc_cross459 ])460 461 AC_DEFUN(RTEMS_PROG_CC_FOR_TARGET,462 [463 dnl check target cc464 RTEMS_PROG_CC465 dnl check if the compiler supports --specs466 RTEMS_GCC_SPECS467 dnl check if the target compiler may use --pipe468 RTEMS_GCC_PIPE469 dnl check if the compiler supports --specs if gcc28 is requested470 if test "$RTEMS_USE_GCC272" != "yes" ; then471 if test "$rtems_cv_gcc_specs" = "no"; then472 AC_MSG_WARN([*** disabling --enable-gcc28])473 RTEMS_USE_GCC272=yes474 fi475 fi476 test "$rtems_cv_gcc_pipe" = "yes" && CC_FOR_TARGET="$CC_FOR_TARGET --pipe"477 478 dnl FIXME: HACK for egcs/cygwin mixing '\\' and '/' in gcc -print-*479 case $host_os in480 *cygwin*) GCCSED="| sed 's%\\\\%/%g'" ;;481 *) ;;482 esac483 AC_SUBST(GCCSED)484 ])485 486 dnl487 dnl $Id$488 dnl489 dnl Set program_prefix490 dnl491 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)492 dnl Extracted from configure493 494 AC_DEFUN(RTEMS_TOOL_PREFIX,495 [AC_REQUIRE([AC_CANONICAL_TARGET])dnl496 AC_REQUIRE([AC_CANONICAL_BUILD])dnl497 498 changequote(,)dnl499 if [ "${program_prefix}" = "NONE" ] ; then500 if [ "${target}" = "${host}" ] ; then501 program_prefix=502 else503 program_prefix=${target}-504 fi505 fi506 changequote([,])dnl507 ])508 509 dnl510 dnl $Id$511 dnl512 dnl Check whether the target compiler accepts -specs513 dnl514 dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de515 dnl516 517 AC_DEFUN(RTEMS_GCC_SPECS,518 [AC_REQUIRE([RTEMS_PROG_CC])519 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,520 [521 rtems_cv_gcc_specs=no522 if test "$rtems_cv_prog_gcc" = "yes"; then523 touch confspec524 echo 'void f(){}' >conftest.c525 if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then526 rtems_cv_gcc_specs=yes527 fi528 fi529 rm -f confspec conftest*530 ])])531 532 dnl533 dnl $Id$534 dnl535 dnl Check whether the target compiler accepts -pipe536 dnl537 dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de538 dnl539 540 AC_DEFUN(RTEMS_GCC_PIPE,541 [AC_REQUIRE([RTEMS_PROG_CC])542 AC_REQUIRE([AC_CANONICAL_HOST])543 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,544 [545 rtems_cv_gcc_pipe=no546 if test "$rtems_cv_prog_gcc" = "yes"; then547 case "$host_os" in548 cygwin*)549 ;;550 *)551 echo 'void f(){}' >conftest.c552 if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then553 rtems_cv_gcc_pipe=yes554 fi555 rm -f conftest*556 ;;557 esac558 fi559 ])560 ])561 562 dnl563 dnl $Id$564 dnl565 dnl Set target tools566 dnl567 dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)568 dnl fixing cache/environment variable handling569 dnl adding checks for cygwin/egcs '\\'-bug570 dnl adding checks for ranlib/ar -s problem571 dnl572 dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)573 dnl574 575 AC_DEFUN(RTEMS_GCC_PRINT,576 [ case $host_os in577 *cygwin*)578 dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'579 dnl Should be removed once cygwin/egcs reports '/' only580 $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `581 ;;582 *)583 $1=`$CC_FOR_TARGET --print-prog-name=$2`584 ;;585 esac586 ])587 588 AC_DEFUN(RTEMS_PATH_TOOL,589 [590 AC_MSG_CHECKING([target's $2])591 AC_CACHE_VAL(ac_cv_path_$1,:)592 AC_MSG_RESULT([$ac_cv_path_$1])593 594 if test -n "$ac_cv_path_$1"; then595 dnl retrieve the value from the cache596 $1=$ac_cv_path_$1597 else598 dnl the cache was not set599 if test -z "[$]$1" ; then600 if test "$rtems_cv_prog_gcc" = "yes"; then601 # We are using gcc, ask it about its tool602 # NOTE: Necessary if gcc was configured to use the target's603 # native tools or uses prefixes for gnutools (e.g. gas instead of as)604 RTEMS_GCC_PRINT($1,$2)605 fi606 else607 # The user set an environment variable.608 # Check whether it is an absolute path, otherwise AC_PATH_PROG609 # will override the environment variable, which isn't what the user610 # intends611 AC_MSG_CHECKING([whether environment variable $1 is an absolute path])612 case "[$]$1" in613 /*) # valid614 AC_MSG_RESULT("yes")615 ;;616 *) # invalid for AC_PATH_PROG617 AC_MSG_RESULT("no")618 AC_MSG_ERROR([***]619 [Environment variable $1 should either]620 [be unset (preferred) or contain an absolute path])621 ;;622 esac623 fi624 625 AC_PATH_PROG($1,"$program_prefix"$2,$3)626 fi627 ])628 629 AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,630 [AC_REQUIRE([RTEMS_PROG_CC])dnl631 632 dnl FIXME: What shall be done if these tools are not available?633 RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)634 RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)635 RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)636 RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)637 638 dnl special treatment of ranlib639 RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)640 if test "$RANLIB_FOR_TARGET" = "no"; then641 # ranlib wasn't found; check if ar -s is available642 RTEMS_AR_FOR_TARGET_S643 if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then644 dnl override RANLIB_FOR_TARGET's cache645 ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"646 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET647 else648 AC_MSG_ERROR([***]649 [Can't figure out how to build a library index]650 [Neither ranlib nor ar -s seem to be available] )651 fi652 fi653 654 dnl NOTE: These may not be available if not using gnutools655 RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)656 RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)657 RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)658 ])659 660 dnl661 dnl $Id$662 dnl663 664 AC_DEFUN(RTEMS_AR_FOR_TARGET_S,665 [666 AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,667 rtems_cv_AR_FOR_TARGET_S,668 [669 cat > conftest.$ac_ext <<EOF670 int foo( int b )671 { return b; }672 EOF673 if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \674 && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \675 && test -s conftest.a ; \676 then677 rtems_cv_AR_FOR_TARGET_S="yes"678 else679 rtems_cv_AR_FOR_TARGET_S="no"680 fi681 rm -f conftest*682 ])683 396 ]) 684 397 … … 725 438 AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP, 726 439 [dnl 440 AC_REQUIRE([RTEMS_TOP]) 441 727 442 AC_MSG_CHECKING([for make/custom/[$]$1.cfg]) 728 443 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then … … 741 456 AC_REQUIRE([RTEMS_TOP])dnl 742 457 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 458 AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl 459 743 460 AC_CACHE_CHECK([whether BSP supports multiprocessing], 744 461 rtems_cv_HAS_MP, … … 762 479 763 480 dnl $Id$ 764 dnl 765 AC_DEFUN(RTEMS_CHECK_POSIX_API, 766 [dnl 767 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 768 AC_CACHE_CHECK([whether BSP supports libposix], 769 rtems_cv_HAS_POSIX_API, 770 [dnl 771 case "$RTEMS_CPU" in 772 unix*) 773 rtems_cv_HAS_POSIX_API="no" 774 ;; 775 *) 776 if test "${RTEMS_HAS_POSIX_API}" = "yes"; then 777 rtems_cv_HAS_POSIX_API="yes"; 778 else 779 rtems_cv_HAS_POSIX_API="disabled"; 780 fi 781 ;; 782 esac]) 783 if test "$rtems_cv_HAS_POSIX_API" = "yes"; then 784 HAS_POSIX_API="yes"; 785 else 786 HAS_POSIX_API="no"; 787 fi 788 AC_SUBST(HAS_POSIX_API)dnl 481 482 AC_DEFUN(RTEMS_CANONICAL_HOST, 483 [dnl 484 AC_REQUIRE([AC_CANONICAL_HOST]) 485 RTEMS_HOST=$host_os 486 changequote(,)dnl 487 case "${target}" in 488 # hpux unix port should go here 489 i[3456]86-pc-linux*) # unix "simulator" port 490 RTEMS_HOST=Linux 491 ;; 492 i[3456]86-*freebsd2*) # unix "simulator" port 493 RTEMS_HOST=FreeBSD 494 ;; 495 sparc-sun-solaris*) # unix "simulator" port 496 RTEMS_HOST=Solaris 497 ;; 498 *) 499 ;; 500 esac 501 changequote([,])dnl 502 AC_SUBST(RTEMS_HOST) 503 ])dnl 504 505 dnl $Id$ 506 507 AC_DEFUN(RTEMS_PATH_KSH, 508 [ 509 dnl NOTE: prefer bash over ksh over sh 510 AC_PATH_PROGS(KSH,bash ksh sh) 511 if test -z "$KSH"; then 512 dnl NOTE: This cannot happen -- /bin/sh must always exist 513 AC_MSG_ERROR( 514 [***] 515 [ Cannot determine a usable shell bash/ksh/sh] 516 [ Please contact your system administrator] ); 517 fi 518 ]) 519 520 dnl 521 dnl $Id$ 522 dnl 523 dnl Check for target gcc 524 dnl 525 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 526 dnl Completely reworked 527 528 AC_DEFUN(RTEMS_PROG_CC, 529 [ 530 AC_BEFORE([$0], [AC_PROG_CPP])dnl 531 AC_BEFORE([$0], [AC_PROG_CC])dnl 532 AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl 533 AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl 534 535 dnl Only accept gcc and cc 536 dnl NOTE: This might be too restrictive for native compilation 537 AC_PATH_PROGS(CC_FOR_TARGET, "$program_prefix"gcc "$program_prefix"cc ) 538 test -z "$CC_FOR_TARGET" \ 539 && AC_MSG_ERROR([no acceptable cc found in \$PATH]) 540 541 dnl backup 542 rtems_save_CC=$CC 543 rtems_save_CFLAGS=$CFLAGS 544 545 dnl temporarily set CC 546 CC=$CC_FOR_TARGET 547 548 AC_PROG_CC_WORKS 549 AC_PROG_CC_GNU 550 551 if test $ac_cv_prog_gcc = yes; then 552 GCC=yes 553 dnl Check whether -g works, even if CFLAGS is set, in case the package 554 dnl plays around with CFLAGS (such as to build both debugging and 555 dnl normal versions of a library), tasteless as that idea is. 556 ac_test_CFLAGS="${CFLAGS+set}" 557 ac_save_CFLAGS="$CFLAGS" 558 CFLAGS= 559 AC_PROG_CC_G 560 if test "$ac_test_CFLAGS" = set; then 561 CFLAGS="$ac_save_CFLAGS" 562 elif test $ac_cv_prog_cc_g = yes; then 563 CFLAGS="-g -O2" 564 else 565 CFLAGS="-O2" 566 fi 567 else 568 GCC= 569 test "${CFLAGS+set}" = set || CFLAGS="-g" 570 fi 571 572 rtems_cv_prog_gcc=$ac_cv_prog_gcc 573 rtems_cv_prog_cc_g=$ac_cv_prog_cc_g 574 rtems_cv_prog_cc_works=$ac_cv_prog_cc_works 575 rtems_cv_prog_cc_cross=$ac_cv_prog_cc_cross 576 577 dnl restore initial values 578 CC=$rtems_save_CC 579 CFLAGS=$rtems_save_CFLAGS 580 581 unset ac_cv_prog_gcc 582 unset ac_cv_prog_cc_g 583 unset ac_cv_prog_cc_works 584 unset ac_cv_prog_cc_cross 585 ]) 586 587 AC_DEFUN(RTEMS_PROG_CC_FOR_TARGET, 588 [ 589 dnl check target cc 590 RTEMS_PROG_CC 591 dnl check if the compiler supports --specs 592 RTEMS_GCC_SPECS 593 dnl check if the target compiler may use --pipe 594 RTEMS_GCC_PIPE 595 dnl check if the compiler supports --specs if gcc28 is requested 596 if test "$RTEMS_USE_GCC272" != "yes" ; then 597 if test "$rtems_cv_gcc_specs" = "no"; then 598 AC_MSG_WARN([*** disabling --enable-gcc28]) 599 RTEMS_USE_GCC272=yes 600 fi 601 fi 602 test "$rtems_cv_gcc_pipe" = "yes" && CC_FOR_TARGET="$CC_FOR_TARGET --pipe" 603 604 dnl FIXME: HACK for egcs/cygwin mixing '\\' and '/' in gcc -print-* 605 case $host_os in 606 *cygwin*) GCCSED="| sed 's%\\\\%/%g'" ;; 607 *) ;; 608 esac 609 AC_SUBST(GCCSED) 610 ]) 611 612 dnl 613 dnl $Id$ 614 dnl 615 dnl Set target tools 616 dnl 617 dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 618 dnl fixing cache/environment variable handling 619 dnl adding checks for cygwin/egcs '\\'-bug 620 dnl adding checks for ranlib/ar -s problem 621 dnl 622 dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 623 dnl 624 625 AC_DEFUN(RTEMS_GCC_PRINT, 626 [ case $host_os in 627 *cygwin*) 628 dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/' 629 dnl Should be removed once cygwin/egcs reports '/' only 630 $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' ` 631 ;; 632 *) 633 $1=`$CC_FOR_TARGET --print-prog-name=$2` 634 ;; 635 esac 636 ]) 637 638 AC_DEFUN(RTEMS_PATH_TOOL, 639 [ 640 AC_MSG_CHECKING([target's $2]) 641 AC_CACHE_VAL(ac_cv_path_$1,:) 642 AC_MSG_RESULT([$ac_cv_path_$1]) 643 644 if test -n "$ac_cv_path_$1"; then 645 dnl retrieve the value from the cache 646 $1=$ac_cv_path_$1 647 else 648 dnl the cache was not set 649 if test -z "[$]$1" ; then 650 if test "$rtems_cv_prog_gcc" = "yes"; then 651 # We are using gcc, ask it about its tool 652 # NOTE: Necessary if gcc was configured to use the target's 653 # native tools or uses prefixes for gnutools (e.g. gas instead of as) 654 RTEMS_GCC_PRINT($1,$2) 655 fi 656 else 657 # The user set an environment variable. 658 # Check whether it is an absolute path, otherwise AC_PATH_PROG 659 # will override the environment variable, which isn't what the user 660 # intends 661 AC_MSG_CHECKING([whether environment variable $1 is an absolute path]) 662 case "[$]$1" in 663 /*) # valid 664 AC_MSG_RESULT("yes") 665 ;; 666 *) # invalid for AC_PATH_PROG 667 AC_MSG_RESULT("no") 668 AC_MSG_ERROR([***] 669 [Environment variable $1 should either] 670 [be unset (preferred) or contain an absolute path]) 671 ;; 672 esac 673 fi 674 675 AC_PATH_PROG($1,"$program_prefix"$2,$3) 676 fi 677 ]) 678 679 AC_DEFUN(RTEMS_CANONICALIZE_TOOLS, 680 [AC_REQUIRE([RTEMS_PROG_CC])dnl 681 682 dnl FIXME: What shall be done if these tools are not available? 683 RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no) 684 RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no) 685 RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no) 686 RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no) 687 688 dnl special treatment of ranlib 689 RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no) 690 if test "$RANLIB_FOR_TARGET" = "no"; then 691 # ranlib wasn't found; check if ar -s is available 692 RTEMS_AR_FOR_TARGET_S 693 if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then 694 dnl override RANLIB_FOR_TARGET's cache 695 ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s" 696 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET 697 else 698 AC_MSG_ERROR([***] 699 [Can't figure out how to build a library index] 700 [Neither ranlib nor ar -s seem to be available] ) 701 fi 702 fi 703 704 dnl NOTE: These may not be available if not using gnutools 705 RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no) 706 RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no) 707 RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no) 708 ]) 709 710 dnl 711 dnl $Id$ 712 dnl 713 714 AC_DEFUN(RTEMS_AR_FOR_TARGET_S, 715 [ 716 AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works, 717 rtems_cv_AR_FOR_TARGET_S, 718 [ 719 cat > conftest.$ac_ext <<EOF 720 int foo( int b ) 721 { return b; } 722 EOF 723 if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \ 724 && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \ 725 && test -s conftest.a ; \ 726 then 727 rtems_cv_AR_FOR_TARGET_S="yes" 728 else 729 rtems_cv_AR_FOR_TARGET_S="no" 730 fi 731 rm -f conftest* 732 ]) 733 ]) 734 735 736 dnl 737 dnl $Id$ 738 dnl 739 dnl Set program_prefix 740 dnl 741 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 742 dnl Extracted from configure 743 744 AC_DEFUN(RTEMS_TOOL_PREFIX, 745 [AC_REQUIRE([AC_CANONICAL_TARGET])dnl 746 AC_REQUIRE([AC_CANONICAL_BUILD])dnl 747 748 changequote(,)dnl 749 if [ "${program_prefix}" = "NONE" ] ; then 750 if [ "${target}" = "${host}" ] ; then 751 program_prefix= 752 else 753 program_prefix=${target}- 754 fi 755 fi 756 changequote([,])dnl 757 ]) 758 759 dnl 760 dnl $Id$ 761 dnl 762 dnl Check whether the target compiler accepts -specs 763 dnl 764 765 AC_DEFUN(RTEMS_GCC_SPECS, 766 [AC_REQUIRE([RTEMS_PROG_CC]) 767 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs, 768 [ 769 rtems_cv_gcc_specs=no 770 if test "$rtems_cv_prog_gcc" = "yes"; then 771 touch confspec 772 echo 'void f(){}' >conftest.c 773 if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then 774 rtems_cv_gcc_specs=yes 775 fi 776 fi 777 rm -f confspec conftest* 778 ])]) 779 780 dnl 781 dnl $Id$ 782 dnl 783 dnl Check whether the target compiler accepts -pipe 784 dnl 785 dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de 786 dnl 787 788 AC_DEFUN(RTEMS_GCC_PIPE, 789 [AC_REQUIRE([RTEMS_PROG_CC]) 790 AC_REQUIRE([AC_CANONICAL_HOST]) 791 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe, 792 [ 793 rtems_cv_gcc_pipe=no 794 if test "$rtems_cv_prog_gcc" = "yes"; then 795 case "$host_os" in 796 cygwin*) 797 ;; 798 *) 799 echo 'void f(){}' >conftest.c 800 if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then 801 rtems_cv_gcc_pipe=yes 802 fi 803 rm -f conftest* 804 ;; 805 esac 806 fi 807 ]) 789 808 ]) 790 809 -
c/src/exec/posix/configure
rd83c39dc r4075af6f 534 534 535 535 536 536 537 # Check whether --with-target-subdir or --without-target-subdir was given. 537 538 if test "${with_target_subdir+set}" = set; then … … 547 548 548 549 echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6 549 echo "configure:55 0: checking for RTEMS Version" >&5550 echo "configure:551: checking for RTEMS Version" >&5 550 551 if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then 551 552 RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \ … … 608 609 609 610 echo $ac_n "checking host system type""... $ac_c" 1>&6 610 echo "configure:61 1: checking host system type" >&5611 echo "configure:612: checking host system type" >&5 611 612 612 613 host_alias=$host … … 629 630 630 631 echo $ac_n "checking target system type""... $ac_c" 1>&6 631 echo "configure:63 2: checking target system type" >&5632 echo "configure:633: checking target system type" >&5 632 633 633 634 target_alias=$target … … 647 648 648 649 echo $ac_n "checking build system type""... $ac_c" 1>&6 649 echo "configure:65 0: checking build system type" >&5650 echo "configure:651: checking build system type" >&5 650 651 651 652 build_alias=$build … … 670 671 671 672 echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6 672 echo "configure:67 3: checking rtems target cpu" >&5673 echo "configure:674: checking rtems target cpu" >&5 673 674 case "${target}" in 674 675 # hpux unix port should go here … … 708 709 # ./install, which can be erroneously created by make from ./install.sh. 709 710 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 710 echo "configure:71 1: checking for a BSD compatible install" >&5711 echo "configure:712: checking for a BSD compatible install" >&5 711 712 if test -z "$INSTALL"; then 712 713 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then … … 761 762 762 763 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6 763 echo "configure:76 4: checking whether build environment is sane" >&5764 echo "configure:765: checking whether build environment is sane" >&5 764 765 # Just in case 765 766 sleep 1 … … 818 819 819 820 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 820 echo "configure:82 1: checking whether ${MAKE-make} sets \${MAKE}" >&5821 echo "configure:822: checking whether ${MAKE-make} sets \${MAKE}" >&5 821 822 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` 822 823 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then … … 858 859 missing_dir=`cd $ac_aux_dir && pwd` 859 860 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6 860 echo "configure:86 1: checking for working aclocal" >&5861 echo "configure:862: checking for working aclocal" >&5 861 862 # Run test in a subshell; some versions of sh will print an error if 862 863 # an executable is not found, even if stderr is redirected. … … 871 872 872 873 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6 873 echo "configure:87 4: checking for working autoconf" >&5874 echo "configure:875: checking for working autoconf" >&5 874 875 # Run test in a subshell; some versions of sh will print an error if 875 876 # an executable is not found, even if stderr is redirected. … … 884 885 885 886 echo $ac_n "checking for working automake""... $ac_c" 1>&6 886 echo "configure:88 7: checking for working automake" >&5887 echo "configure:888: checking for working automake" >&5 887 888 # Run test in a subshell; some versions of sh will print an error if 888 889 # an executable is not found, even if stderr is redirected. … … 897 898 898 899 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6 899 echo "configure:90 0: checking for working autoheader" >&5900 echo "configure:901: checking for working autoheader" >&5 900 901 # Run test in a subshell; some versions of sh will print an error if 901 902 # an executable is not found, even if stderr is redirected. … … 910 911 911 912 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6 912 echo "configure:91 3: checking for working makeinfo" >&5913 echo "configure:914: checking for working makeinfo" >&5 913 914 # Run test in a subshell; some versions of sh will print an error if 914 915 # an executable is not found, even if stderr is redirected. … … 924 925 925 926 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 926 echo "configure:92 7: checking whether to enable maintainer-specific portions of Makefiles" >&5927 echo "configure:928: checking whether to enable maintainer-specific portions of Makefiles" >&5 927 928 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. 928 929 if test "${enable_maintainer_mode+set}" = set; then … … 959 960 RTEMS_HAS_MULTIPROCESSING=no 960 961 fi 962 961 963 962 964 … … 1012 1014 1013 1015 1016 1014 1017 echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6 1015 echo "configure:101 6: checking for RTEMS_BSP" >&51018 echo "configure:1019: checking for RTEMS_BSP" >&5 1016 1019 if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then 1017 1020 echo $ac_n "(cached) $ac_c" 1>&6 … … 1030 1033 1031 1034 1035 1032 1036 # Is this a supported CPU? 1033 1037 echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6 1034 echo "configure:103 5: checking if cpu $RTEMS_CPU is supported" >&51038 echo "configure:1039: checking if cpu $RTEMS_CPU is supported" >&5 1035 1039 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 1036 1040 echo "$ac_t""yes" 1>&6 … … 1083 1087 set dummy $ac_prog; ac_word=$2 1084 1088 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1085 echo "configure:10 86: checking for $ac_word" >&51089 echo "configure:1090: checking for $ac_word" >&5 1086 1090 if eval "test \"`echo '$''{'ac_cv_path_KSH'+set}'`\" = set"; then 1087 1091 echo $ac_n "(cached) $ac_c" 1>&6 … … 1142 1146 set dummy $ac_prog; ac_word=$2 1143 1147 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1144 echo "configure:114 5: checking for $ac_word" >&51148 echo "configure:1149: checking for $ac_word" >&5 1145 1149 if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then 1146 1150 echo $ac_n "(cached) $ac_c" 1>&6 … … 1186 1190 1187 1191 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 1188 echo "configure:11 89: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&51192 echo "configure:1193: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 1189 1193 1190 1194 ac_ext=c … … 1197 1201 cat > conftest.$ac_ext << EOF 1198 1202 1199 #line 120 0"configure"1203 #line 1204 "configure" 1200 1204 #include "confdefs.h" 1201 1205 1202 1206 main(){return(0);} 1203 1207 EOF 1204 if { (eval echo configure:120 5: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then1208 if { (eval echo configure:1209: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1205 1209 ac_cv_prog_cc_works=yes 1206 1210 # If we can't run a trivial program, we are probably using a cross compiler. … … 1228 1232 fi 1229 1233 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 1230 echo "configure:123 1: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&51234 echo "configure:1235: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 1231 1235 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 1232 1236 cross_compiling=$ac_cv_prog_cc_cross 1233 1237 1234 1238 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 1235 echo "configure:12 36: checking whether we are using GNU C" >&51239 echo "configure:1240: checking whether we are using GNU C" >&5 1236 1240 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then 1237 1241 echo $ac_n "(cached) $ac_c" 1>&6 … … 1242 1246 #endif 1243 1247 EOF 1244 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:124 5: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then1248 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1249: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then 1245 1249 ac_cv_prog_gcc=yes 1246 1250 else … … 1257 1261 CFLAGS= 1258 1262 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 1259 echo "configure:126 0: checking whether ${CC-cc} accepts -g" >&51263 echo "configure:1264: checking whether ${CC-cc} accepts -g" >&5 1260 1264 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then 1261 1265 echo $ac_n "(cached) $ac_c" 1>&6 … … 1299 1303 1300 1304 echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6 1301 echo "configure:130 2: checking whether $CC_FOR_TARGET accepts -specs" >&51305 echo "configure:1306: checking whether $CC_FOR_TARGET accepts -specs" >&5 1302 1306 if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then 1303 1307 echo $ac_n "(cached) $ac_c" 1>&6 … … 1320 1324 1321 1325 echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6 1322 echo "configure:132 3: checking whether $CC_FOR_TARGET accepts --pipe" >&51326 echo "configure:1327: checking whether $CC_FOR_TARGET accepts --pipe" >&5 1323 1327 if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then 1324 1328 echo $ac_n "(cached) $ac_c" 1>&6 … … 1361 1365 1362 1366 echo $ac_n "checking target's ar""... $ac_c" 1>&6 1363 echo "configure:136 4: checking target's ar" >&51367 echo "configure:1368: checking target's ar" >&5 1364 1368 if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then 1365 1369 echo $ac_n "(cached) $ac_c" 1>&6 … … 1394 1398 # intends 1395 1399 echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1396 echo "configure:1 397: checking whether environment variable AR_FOR_TARGET is an absolute path" >&51400 echo "configure:1401: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5 1397 1401 case "$AR_FOR_TARGET" in 1398 1402 /*) # valid … … 1411 1415 set dummy "$program_prefix"ar; ac_word=$2 1412 1416 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1413 echo "configure:141 4: checking for $ac_word" >&51417 echo "configure:1418: checking for $ac_word" >&5 1414 1418 if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then 1415 1419 echo $ac_n "(cached) $ac_c" 1>&6 … … 1448 1452 1449 1453 echo $ac_n "checking target's as""... $ac_c" 1>&6 1450 echo "configure:145 1: checking target's as" >&51454 echo "configure:1455: checking target's as" >&5 1451 1455 if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then 1452 1456 echo $ac_n "(cached) $ac_c" 1>&6 … … 1481 1485 # intends 1482 1486 echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1483 echo "configure:148 4: checking whether environment variable AS_FOR_TARGET is an absolute path" >&51487 echo "configure:1488: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5 1484 1488 case "$AS_FOR_TARGET" in 1485 1489 /*) # valid … … 1498 1502 set dummy "$program_prefix"as; ac_word=$2 1499 1503 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1500 echo "configure:150 1: checking for $ac_word" >&51504 echo "configure:1505: checking for $ac_word" >&5 1501 1505 if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then 1502 1506 echo $ac_n "(cached) $ac_c" 1>&6 … … 1535 1539 1536 1540 echo $ac_n "checking target's ld""... $ac_c" 1>&6 1537 echo "configure:15 38: checking target's ld" >&51541 echo "configure:1542: checking target's ld" >&5 1538 1542 if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then 1539 1543 echo $ac_n "(cached) $ac_c" 1>&6 … … 1568 1572 # intends 1569 1573 echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1570 echo "configure:157 1: checking whether environment variable LD_FOR_TARGET is an absolute path" >&51574 echo "configure:1575: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5 1571 1575 case "$LD_FOR_TARGET" in 1572 1576 /*) # valid … … 1585 1589 set dummy "$program_prefix"ld; ac_word=$2 1586 1590 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1587 echo "configure:15 88: checking for $ac_word" >&51591 echo "configure:1592: checking for $ac_word" >&5 1588 1592 if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then 1589 1593 echo $ac_n "(cached) $ac_c" 1>&6 … … 1622 1626 1623 1627 echo $ac_n "checking target's nm""... $ac_c" 1>&6 1624 echo "configure:162 5: checking target's nm" >&51628 echo "configure:1629: checking target's nm" >&5 1625 1629 if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then 1626 1630 echo $ac_n "(cached) $ac_c" 1>&6 … … 1655 1659 # intends 1656 1660 echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1657 echo "configure:16 58: checking whether environment variable NM_FOR_TARGET is an absolute path" >&51661 echo "configure:1662: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5 1658 1662 case "$NM_FOR_TARGET" in 1659 1663 /*) # valid … … 1672 1676 set dummy "$program_prefix"nm; ac_word=$2 1673 1677 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1674 echo "configure:167 5: checking for $ac_word" >&51678 echo "configure:1679: checking for $ac_word" >&5 1675 1679 if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then 1676 1680 echo $ac_n "(cached) $ac_c" 1>&6 … … 1710 1714 1711 1715 echo $ac_n "checking target's ranlib""... $ac_c" 1>&6 1712 echo "configure:171 3: checking target's ranlib" >&51716 echo "configure:1717: checking target's ranlib" >&5 1713 1717 if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then 1714 1718 echo $ac_n "(cached) $ac_c" 1>&6 … … 1743 1747 # intends 1744 1748 echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1745 echo "configure:17 46: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&51749 echo "configure:1750: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5 1746 1750 case "$RANLIB_FOR_TARGET" in 1747 1751 /*) # valid … … 1760 1764 set dummy "$program_prefix"ranlib; ac_word=$2 1761 1765 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1762 echo "configure:176 3: checking for $ac_word" >&51766 echo "configure:1767: checking for $ac_word" >&5 1763 1767 if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then 1764 1768 echo $ac_n "(cached) $ac_c" 1>&6 … … 1799 1803 1800 1804 echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6 1801 echo "configure:180 2: checking whether $AR_FOR_TARGET -s works" >&51805 echo "configure:1806: checking whether $AR_FOR_TARGET -s works" >&5 1802 1806 if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then 1803 1807 echo $ac_n "(cached) $ac_c" 1>&6 … … 1808 1812 { return b; } 1809 1813 EOF 1810 if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:181 1: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \1811 && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:181 2: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \1814 if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1815: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \ 1815 && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1816: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \ 1812 1816 && test -s conftest.a ; \ 1813 1817 then … … 1834 1838 1835 1839 echo $ac_n "checking target's objcopy""... $ac_c" 1>&6 1836 echo "configure:18 37: checking target's objcopy" >&51840 echo "configure:1841: checking target's objcopy" >&5 1837 1841 if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then 1838 1842 echo $ac_n "(cached) $ac_c" 1>&6 … … 1867 1871 # intends 1868 1872 echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1869 echo "configure:187 0: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&51873 echo "configure:1874: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5 1870 1874 case "$OBJCOPY_FOR_TARGET" in 1871 1875 /*) # valid … … 1884 1888 set dummy "$program_prefix"objcopy; ac_word=$2 1885 1889 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1886 echo "configure:18 87: checking for $ac_word" >&51890 echo "configure:1891: checking for $ac_word" >&5 1887 1891 if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then 1888 1892 echo $ac_n "(cached) $ac_c" 1>&6 … … 1921 1925 1922 1926 echo $ac_n "checking target's size""... $ac_c" 1>&6 1923 echo "configure:192 4: checking target's size" >&51927 echo "configure:1928: checking target's size" >&5 1924 1928 if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then 1925 1929 echo $ac_n "(cached) $ac_c" 1>&6 … … 1954 1958 # intends 1955 1959 echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1956 echo "configure:19 57: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&51960 echo "configure:1961: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5 1957 1961 case "$SIZE_FOR_TARGET" in 1958 1962 /*) # valid … … 1971 1975 set dummy "$program_prefix"size; ac_word=$2 1972 1976 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1973 echo "configure:197 4: checking for $ac_word" >&51977 echo "configure:1978: checking for $ac_word" >&5 1974 1978 if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then 1975 1979 echo $ac_n "(cached) $ac_c" 1>&6 … … 2008 2012 2009 2013 echo $ac_n "checking target's strip""... $ac_c" 1>&6 2010 echo "configure:201 1: checking target's strip" >&52014 echo "configure:2015: checking target's strip" >&5 2011 2015 if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then 2012 2016 echo $ac_n "(cached) $ac_c" 1>&6 … … 2041 2045 # intends 2042 2046 echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6 2043 echo "configure:204 4: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&52047 echo "configure:2048: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5 2044 2048 case "$STRIP_FOR_TARGET" in 2045 2049 /*) # valid … … 2058 2062 set dummy "$program_prefix"strip; ac_word=$2 2059 2063 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 2060 echo "configure:206 1: checking for $ac_word" >&52064 echo "configure:2065: checking for $ac_word" >&5 2061 2065 if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then 2062 2066 echo $ac_n "(cached) $ac_c" 1>&6 … … 2096 2100 2097 2101 # Check if there is custom/*.cfg for this BSP 2102 2103 2098 2104 echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6 2099 echo "configure:210 0: checking for make/custom/$RTEMS_BSP.cfg" >&52105 echo "configure:2106: checking for make/custom/$RTEMS_BSP.cfg" >&5 2100 2106 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then 2101 2107 echo "$ac_t""yes" 1>&6 … … 2104 2110 fi 2105 2111 2112 2106 2113 echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6 2107 echo "configure:21 08: checking whether BSP supports multiprocessing" >&52114 echo "configure:2115: checking whether BSP supports multiprocessing" >&5 2108 2115 if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then 2109 2116 echo $ac_n "(cached) $ac_c" 1>&6 … … 2128 2135 2129 2136 2137 2130 2138 echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6 2131 echo "configure:21 32: checking whether BSP supports libposix" >&52139 echo "configure:2140: checking whether BSP supports libposix" >&5 2132 2140 if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then 2133 2141 echo $ac_n "(cached) $ac_c" 1>&6 … … 2186 2194 ## Needed when using automake for libs/rels 2187 2195 echo $ac_n "checking for newlib""... $ac_c" 1>&6 2188 echo "configure:21 89: checking for newlib" >&52196 echo "configure:2197: checking for newlib" >&5 2189 2197 if eval "test \"`echo '$''{'rtems_cv_use_newlib'+set}'`\" = set"; then 2190 2198 echo $ac_n "(cached) $ac_c" 1>&6 … … 2195 2203 2196 2204 cat > conftest.$ac_ext <<EOF 2197 #line 2 198"configure"2205 #line 2206 "configure" 2198 2206 #include "confdefs.h" 2199 2207 extern int not_required_by_rtems() ; … … 2202 2210 ; return 0; } 2203 2211 EOF 2204 if { (eval echo configure:22 05: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then2212 if { (eval echo configure:2213: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 2205 2213 rm -rf conftest* 2206 2214 rtems_cv_use_newlib="yes" … … 2213 2221 if test -z "$rtems_cv_use_newlib"; then 2214 2222 cat > conftest.$ac_ext <<EOF 2215 #line 22 16"configure"2223 #line 2224 "configure" 2216 2224 #include "confdefs.h" 2217 2225 extern int rtems_provides_crt0 ; … … 2220 2228 ; return 0; } 2221 2229 EOF 2222 if { (eval echo configure:22 23: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then2230 if { (eval echo configure:2231: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 2223 2231 rm -rf conftest* 2224 2232 rtems_cv_use_newlib="yes" -
c/src/exec/score/cpu/aclocal.m4
rd83c39dc r4075af6f 20 20 AC_DEFUN(RTEMS_TOP, 21 21 [dnl 22 AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl 23 AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl 24 22 25 AC_ARG_WITH(target-subdir, 23 26 [ --with-target-subdir=DIR], … … 44 47 AC_MSG_RESULT($RTEMS_VERSION) 45 48 ])dnl 49 50 # Do all the work for Automake. This macro actually does too much -- 51 # some checks are only needed if your package does certain things. 52 # But this isn't really a big deal. 53 54 # serial 1 55 56 dnl Usage: 57 dnl AM_INIT_AUTOMAKE(package,version, [no-define]) 58 59 AC_DEFUN(AM_INIT_AUTOMAKE, 60 [AC_REQUIRE([AC_PROG_INSTALL]) 61 dnl We require 2.13 because we rely on SHELL being computed by configure. 62 AC_PREREQ([2.13]) 63 PACKAGE=[$1] 64 AC_SUBST(PACKAGE) 65 VERSION=[$2] 66 AC_SUBST(VERSION) 67 dnl test to see if srcdir already configured 68 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then 69 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 70 fi 71 ifelse([$3],, 72 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 73 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])) 74 AC_REQUIRE([AM_SANITY_CHECK]) 75 AC_REQUIRE([AC_ARG_PROGRAM]) 76 dnl FIXME This is truly gross. 77 missing_dir=`cd $ac_aux_dir && pwd` 78 AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir) 79 AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir) 80 AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir) 81 AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir) 82 AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir) 83 AC_REQUIRE([AC_PROG_MAKE_SET])]) 84 85 # 86 # Check to make sure that the build environment is sane. 87 # 88 89 AC_DEFUN(AM_SANITY_CHECK, 90 [AC_MSG_CHECKING([whether build environment is sane]) 91 # Just in case 92 sleep 1 93 echo timestamp > conftestfile 94 # Do `set' in a subshell so we don't clobber the current shell's 95 # arguments. Must try -L first in case configure is actually a 96 # symlink; some systems play weird games with the mod time of symlinks 97 # (eg FreeBSD returns the mod time of the symlink's containing 98 # directory). 99 if ( 100 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null` 101 if test "[$]*" = "X"; then 102 # -L didn't work. 103 set X `ls -t $srcdir/configure conftestfile` 104 fi 105 if test "[$]*" != "X $srcdir/configure conftestfile" \ 106 && test "[$]*" != "X conftestfile $srcdir/configure"; then 107 108 # If neither matched, then we have a broken ls. This can happen 109 # if, for instance, CONFIG_SHELL is bash and it inherits a 110 # broken ls alias from the environment. This has actually 111 # happened. Such a system could not be considered "sane". 112 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 113 alias in your environment]) 114 fi 115 116 test "[$]2" = conftestfile 117 ) 118 then 119 # Ok. 120 : 121 else 122 AC_MSG_ERROR([newly created file is older than distributed files! 123 Check your system clock]) 124 fi 125 rm -f conftest* 126 AC_MSG_RESULT(yes)]) 127 128 dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY) 129 dnl The program must properly implement --version. 130 AC_DEFUN(AM_MISSING_PROG, 131 [AC_MSG_CHECKING(for working $2) 132 # Run test in a subshell; some versions of sh will print an error if 133 # an executable is not found, even if stderr is redirected. 134 # Redirect stdin to placate older versions of autoconf. Sigh. 135 if ($2 --version) < /dev/null > /dev/null 2>&1; then 136 $1=$2 137 AC_MSG_RESULT(found) 138 else 139 $1="$3/missing $2" 140 AC_MSG_RESULT(missing) 141 fi 142 AC_SUBST($1)]) 46 143 47 144 dnl … … 137 234 AC_DEFUN(RTEMS_ENABLE_POSIX, 138 235 [ 236 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 237 139 238 AC_ARG_ENABLE(posix, 140 239 [ --enable-posix enable posix interface], … … 170 269 AC_SUBST(RTEMS_HAS_POSIX_API) 171 270 ]) 271 272 dnl $Id$ 273 dnl 274 AC_DEFUN(RTEMS_CHECK_POSIX_API, 275 [dnl 276 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 277 AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl 278 279 AC_CACHE_CHECK([whether BSP supports libposix], 280 rtems_cv_HAS_POSIX_API, 281 [dnl 282 case "$RTEMS_CPU" in 283 unix*) 284 rtems_cv_HAS_POSIX_API="no" 285 ;; 286 *) 287 if test "${RTEMS_HAS_POSIX_API}" = "yes"; then 288 rtems_cv_HAS_POSIX_API="yes"; 289 else 290 rtems_cv_HAS_POSIX_API="disabled"; 291 fi 292 ;; 293 esac]) 294 if test "$rtems_cv_HAS_POSIX_API" = "yes"; then 295 HAS_POSIX_API="yes"; 296 else 297 HAS_POSIX_API="no"; 298 fi 299 AC_SUBST(HAS_POSIX_API)dnl 300 ]) 301 302 dnl $Id$ 303 304 dnl check if RTEMS support a cpu 305 AC_DEFUN(RTEMS_CHECK_CPU, 306 [dnl 307 AC_REQUIRE([RTEMS_TOP]) 308 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU]) 309 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 310 311 # Is this a supported CPU? 312 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported]) 313 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 314 AC_MSG_RESULT(yes) 315 else 316 AC_MSG_ERROR(no) 317 fi 318 ])dnl 319 172 320 173 321 dnl $Id$ … … 203 351 AC_DEFUN(RTEMS_ENABLE_RTEMSBSP, 204 352 [ 353 AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl 205 354 AC_ARG_ENABLE(rtemsbsp, 206 355 [ --enable-rtemsbsp=bsp1 bsp2 .. BSPs to include in build], … … 215 364 AC_DEFUN(RTEMS_ENV_RTEMSBSP, 216 365 [dnl 366 AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl 367 AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl 368 AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl 369 AC_BEFORE([$0], [RTEMS_CHECK_MULTIPROCESSING])dnl 370 AC_BEFORE([$0], [RTEMS_CHECK_POSIX_API])dnl 371 217 372 AC_MSG_CHECKING([for RTEMS_BSP]) 218 373 AC_CACHE_VAL(rtems_cv_RTEMS_BSP, … … 228 383 ]) 229 384 230 dnl $Id$231 232 dnl check if RTEMS support a cpu233 AC_DEFUN(RTEMS_CHECK_CPU,234 [dnl235 AC_REQUIRE([RTEMS_TOP])236 AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])237 # Is this a supported CPU?238 AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])239 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then240 AC_MSG_RESULT(yes)241 else242 AC_MSG_ERROR(no)243 fi244 ])dnl245 246 247 dnl $Id$248 249 AC_DEFUN(RTEMS_CANONICAL_HOST,250 [dnl251 AC_REQUIRE([AC_CANONICAL_HOST])252 RTEMS_HOST=$host_os253 changequote(,)dnl254 case "${target}" in255 # hpux unix port should go here256 i[3456]86-pc-linux*) # unix "simulator" port257 RTEMS_HOST=Linux258 ;;259 i[3456]86-*freebsd2*) # unix "simulator" port260 RTEMS_HOST=FreeBSD261 ;;262 sparc-sun-solaris*) # unix "simulator" port263 RTEMS_HOST=Solaris264 ;;265 *)266 ;;267 esac268 changequote([,])dnl269 AC_SUBST(RTEMS_HOST)270 ])dnl271 272 385 dnl 273 386 dnl $Id$ … … 292 405 PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex" 293 406 AC_SUBST(PACKHEX) 294 ])295 296 297 dnl298 dnl $Id$299 dnl300 dnl Check for target gcc301 dnl302 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)303 dnl Completely reworked304 305 AC_DEFUN(RTEMS_PROG_CC,306 [307 AC_BEFORE([$0], [AC_PROG_CPP])dnl308 AC_BEFORE([$0], [AC_PROG_CC])dnl309 AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl310 311 dnl Only accept gcc and cc312 dnl NOTE: This might be too restrictive for native compilation313 AC_PATH_PROGS(CC_FOR_TARGET, "$program_prefix"gcc "$program_prefix"cc )314 test -z "$CC_FOR_TARGET" \315 && AC_MSG_ERROR([no acceptable cc found in \$PATH])316 317 dnl backup318 rtems_save_CC=$CC319 rtems_save_CFLAGS=$CFLAGS320 321 dnl temporarily set CC322 CC=$CC_FOR_TARGET323 324 AC_PROG_CC_WORKS325 AC_PROG_CC_GNU326 327 if test $ac_cv_prog_gcc = yes; then328 GCC=yes329 dnl Check whether -g works, even if CFLAGS is set, in case the package330 dnl plays around with CFLAGS (such as to build both debugging and331 dnl normal versions of a library), tasteless as that idea is.332 ac_test_CFLAGS="${CFLAGS+set}"333 ac_save_CFLAGS="$CFLAGS"334 CFLAGS=335 AC_PROG_CC_G336 if test "$ac_test_CFLAGS" = set; then337 CFLAGS="$ac_save_CFLAGS"338 elif test $ac_cv_prog_cc_g = yes; then339 CFLAGS="-g -O2"340 else341 CFLAGS="-O2"342 fi343 else344 GCC=345 test "${CFLAGS+set}" = set || CFLAGS="-g"346 fi347 348 rtems_cv_prog_gcc=$ac_cv_prog_gcc349 rtems_cv_prog_cc_g=$ac_cv_prog_cc_g350 rtems_cv_prog_cc_works=$ac_cv_prog_cc_works351 rtems_cv_prog_cc_cross=$ac_cv_prog_cc_cross352 353 dnl restore initial values354 CC=$rtems_save_CC355 CFLAGS=$rtems_save_CFLAGS356 357 unset ac_cv_prog_gcc358 unset ac_cv_prog_cc_g359 unset ac_cv_prog_cc_works360 unset ac_cv_prog_cc_cross361 ])362 363 AC_DEFUN(RTEMS_PROG_CC_FOR_TARGET,364 [365 dnl check target cc366 RTEMS_PROG_CC367 dnl check if the compiler supports --specs368 RTEMS_GCC_SPECS369 dnl check if the target compiler may use --pipe370 RTEMS_GCC_PIPE371 dnl check if the compiler supports --specs if gcc28 is requested372 if test "$RTEMS_USE_GCC272" != "yes" ; then373 if test "$rtems_cv_gcc_specs" = "no"; then374 AC_MSG_WARN([*** disabling --enable-gcc28])375 RTEMS_USE_GCC272=yes376 fi377 fi378 test "$rtems_cv_gcc_pipe" = "yes" && CC_FOR_TARGET="$CC_FOR_TARGET --pipe"379 380 dnl FIXME: HACK for egcs/cygwin mixing '\\' and '/' in gcc -print-*381 case $host_os in382 *cygwin*) GCCSED="| sed 's%\\\\%/%g'" ;;383 *) ;;384 esac385 AC_SUBST(GCCSED)386 ])387 388 dnl389 dnl $Id$390 dnl391 dnl Set program_prefix392 dnl393 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de)394 dnl Extracted from configure395 396 AC_DEFUN(RTEMS_TOOL_PREFIX,397 [AC_REQUIRE([AC_CANONICAL_TARGET])dnl398 AC_REQUIRE([AC_CANONICAL_BUILD])dnl399 400 changequote(,)dnl401 if [ "${program_prefix}" = "NONE" ] ; then402 if [ "${target}" = "${host}" ] ; then403 program_prefix=404 else405 program_prefix=${target}-406 fi407 fi408 changequote([,])dnl409 ])410 411 dnl412 dnl $Id$413 dnl414 dnl Check whether the target compiler accepts -specs415 dnl416 dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de417 dnl418 419 AC_DEFUN(RTEMS_GCC_SPECS,420 [AC_REQUIRE([RTEMS_PROG_CC])421 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,422 [423 rtems_cv_gcc_specs=no424 if test "$rtems_cv_prog_gcc" = "yes"; then425 touch confspec426 echo 'void f(){}' >conftest.c427 if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then428 rtems_cv_gcc_specs=yes429 fi430 fi431 rm -f confspec conftest*432 ])])433 434 dnl435 dnl $Id$436 dnl437 dnl Check whether the target compiler accepts -pipe438 dnl439 dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de440 dnl441 442 AC_DEFUN(RTEMS_GCC_PIPE,443 [AC_REQUIRE([RTEMS_PROG_CC])444 AC_REQUIRE([AC_CANONICAL_HOST])445 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,446 [447 rtems_cv_gcc_pipe=no448 if test "$rtems_cv_prog_gcc" = "yes"; then449 case "$host_os" in450 cygwin*)451 ;;452 *)453 echo 'void f(){}' >conftest.c454 if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then455 rtems_cv_gcc_pipe=yes456 fi457 rm -f conftest*458 ;;459 esac460 fi461 ])462 ])463 464 dnl465 dnl $Id$466 dnl467 dnl Set target tools468 dnl469 dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de)470 dnl fixing cache/environment variable handling471 dnl adding checks for cygwin/egcs '\\'-bug472 dnl adding checks for ranlib/ar -s problem473 dnl474 dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de)475 dnl476 477 AC_DEFUN(RTEMS_GCC_PRINT,478 [ case $host_os in479 *cygwin*)480 dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/'481 dnl Should be removed once cygwin/egcs reports '/' only482 $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' `483 ;;484 *)485 $1=`$CC_FOR_TARGET --print-prog-name=$2`486 ;;487 esac488 ])489 490 AC_DEFUN(RTEMS_PATH_TOOL,491 [492 AC_MSG_CHECKING([target's $2])493 AC_CACHE_VAL(ac_cv_path_$1,:)494 AC_MSG_RESULT([$ac_cv_path_$1])495 496 if test -n "$ac_cv_path_$1"; then497 dnl retrieve the value from the cache498 $1=$ac_cv_path_$1499 else500 dnl the cache was not set501 if test -z "[$]$1" ; then502 if test "$rtems_cv_prog_gcc" = "yes"; then503 # We are using gcc, ask it about its tool504 # NOTE: Necessary if gcc was configured to use the target's505 # native tools or uses prefixes for gnutools (e.g. gas instead of as)506 RTEMS_GCC_PRINT($1,$2)507 fi508 else509 # The user set an environment variable.510 # Check whether it is an absolute path, otherwise AC_PATH_PROG511 # will override the environment variable, which isn't what the user512 # intends513 AC_MSG_CHECKING([whether environment variable $1 is an absolute path])514 case "[$]$1" in515 /*) # valid516 AC_MSG_RESULT("yes")517 ;;518 *) # invalid for AC_PATH_PROG519 AC_MSG_RESULT("no")520 AC_MSG_ERROR([***]521 [Environment variable $1 should either]522 [be unset (preferred) or contain an absolute path])523 ;;524 esac525 fi526 527 AC_PATH_PROG($1,"$program_prefix"$2,$3)528 fi529 ])530 531 AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,532 [AC_REQUIRE([RTEMS_PROG_CC])dnl533 534 dnl FIXME: What shall be done if these tools are not available?535 RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)536 RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)537 RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)538 RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)539 540 dnl special treatment of ranlib541 RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)542 if test "$RANLIB_FOR_TARGET" = "no"; then543 # ranlib wasn't found; check if ar -s is available544 RTEMS_AR_FOR_TARGET_S545 if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then546 dnl override RANLIB_FOR_TARGET's cache547 ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"548 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET549 else550 AC_MSG_ERROR([***]551 [Can't figure out how to build a library index]552 [Neither ranlib nor ar -s seem to be available] )553 fi554 fi555 556 dnl NOTE: These may not be available if not using gnutools557 RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)558 RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)559 RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)560 ])561 562 dnl563 dnl $Id$564 dnl565 566 AC_DEFUN(RTEMS_AR_FOR_TARGET_S,567 [568 AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,569 rtems_cv_AR_FOR_TARGET_S,570 [571 cat > conftest.$ac_ext <<EOF572 int foo( int b )573 { return b; }574 EOF575 if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \576 && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \577 && test -s conftest.a ; \578 then579 rtems_cv_AR_FOR_TARGET_S="yes"580 else581 rtems_cv_AR_FOR_TARGET_S="no"582 fi583 rm -f conftest*584 ])585 ])586 587 588 dnl $Id$589 590 AC_DEFUN(RTEMS_CHECK_NEWLIB,591 [dnl592 AC_REQUIRE([RTEMS_PROG_CC_FOR_TARGET])dnl593 AC_REQUIRE([RTEMS_CANONICALIZE_TOOLS])dnl594 AC_CACHE_CHECK([for newlib],595 rtems_cv_use_newlib,596 [597 rtems_save_CC=$CC598 CC=$CC_FOR_TARGET599 600 dnl some versions of newlib provide not_required_by_rtems601 AC_TRY_LINK(602 [extern int not_required_by_rtems() ;],603 [not_required_by_rtems()],604 rtems_cv_use_newlib="yes")605 606 dnl older versions of newlib provided rtems_provides_crt0607 if test -z "$rtems_cv_use_newlib"; then608 AC_TRY_LINK(609 [extern int rtems_provides_crt0 ;],610 [rtems_provides_crt0 = 0],611 rtems_cv_use_newlib="yes",612 rtems_cv_use_newlib="no")613 fi614 CC=$rtems_save_CC])615 RTEMS_USE_NEWLIB="$rtems_cv_use_newlib"616 AC_SUBST(RTEMS_USE_NEWLIB)617 407 ]) 618 408 … … 659 449 AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP, 660 450 [dnl 451 AC_REQUIRE([RTEMS_TOP]) 452 661 453 AC_MSG_CHECKING([for make/custom/[$]$1.cfg]) 662 454 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then … … 675 467 AC_REQUIRE([RTEMS_TOP])dnl 676 468 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 469 AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl 470 677 471 AC_CACHE_CHECK([whether BSP supports multiprocessing], 678 472 rtems_cv_HAS_MP, … … 696 490 697 491 dnl $Id$ 698 dnl 699 AC_DEFUN(RTEMS_C HECK_POSIX_API,492 493 AC_DEFUN(RTEMS_CANONICAL_HOST, 700 494 [dnl 701 AC_REQUIRE([RTEMS_CHECK_CPU])dnl 702 AC_CACHE_CHECK([whether BSP supports libposix], 703 rtems_cv_HAS_POSIX_API, 704 [dnl 705 case "$RTEMS_CPU" in 706 unix*) 707 rtems_cv_HAS_POSIX_API="no" 708 ;; 709 *) 710 if test "${RTEMS_HAS_POSIX_API}" = "yes"; then 711 rtems_cv_HAS_POSIX_API="yes"; 712 else 713 rtems_cv_HAS_POSIX_API="disabled"; 714 fi 715 ;; 716 esac]) 717 if test "$rtems_cv_HAS_POSIX_API" = "yes"; then 718 HAS_POSIX_API="yes"; 719 else 720 HAS_POSIX_API="no"; 721 fi 722 AC_SUBST(HAS_POSIX_API)dnl 723 ]) 495 AC_REQUIRE([AC_CANONICAL_HOST]) 496 RTEMS_HOST=$host_os 497 changequote(,)dnl 498 case "${target}" in 499 # hpux unix port should go here 500 i[3456]86-pc-linux*) # unix "simulator" port 501 RTEMS_HOST=Linux 502 ;; 503 i[3456]86-*freebsd2*) # unix "simulator" port 504 RTEMS_HOST=FreeBSD 505 ;; 506 sparc-sun-solaris*) # unix "simulator" port 507 RTEMS_HOST=Solaris 508 ;; 509 *) 510 ;; 511 esac 512 changequote([,])dnl 513 AC_SUBST(RTEMS_HOST) 514 ])dnl 515 516 dnl 517 dnl $Id$ 518 dnl 519 dnl Check for target gcc 520 dnl 521 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 522 dnl Completely reworked 523 524 AC_DEFUN(RTEMS_PROG_CC, 525 [ 526 AC_BEFORE([$0], [AC_PROG_CPP])dnl 527 AC_BEFORE([$0], [AC_PROG_CC])dnl 528 AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl 529 AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl 530 531 dnl Only accept gcc and cc 532 dnl NOTE: This might be too restrictive for native compilation 533 AC_PATH_PROGS(CC_FOR_TARGET, "$program_prefix"gcc "$program_prefix"cc ) 534 test -z "$CC_FOR_TARGET" \ 535 && AC_MSG_ERROR([no acceptable cc found in \$PATH]) 536 537 dnl backup 538 rtems_save_CC=$CC 539 rtems_save_CFLAGS=$CFLAGS 540 541 dnl temporarily set CC 542 CC=$CC_FOR_TARGET 543 544 AC_PROG_CC_WORKS 545 AC_PROG_CC_GNU 546 547 if test $ac_cv_prog_gcc = yes; then 548 GCC=yes 549 dnl Check whether -g works, even if CFLAGS is set, in case the package 550 dnl plays around with CFLAGS (such as to build both debugging and 551 dnl normal versions of a library), tasteless as that idea is. 552 ac_test_CFLAGS="${CFLAGS+set}" 553 ac_save_CFLAGS="$CFLAGS" 554 CFLAGS= 555 AC_PROG_CC_G 556 if test "$ac_test_CFLAGS" = set; then 557 CFLAGS="$ac_save_CFLAGS" 558 elif test $ac_cv_prog_cc_g = yes; then 559 CFLAGS="-g -O2" 560 else 561 CFLAGS="-O2" 562 fi 563 else 564 GCC= 565 test "${CFLAGS+set}" = set || CFLAGS="-g" 566 fi 567 568 rtems_cv_prog_gcc=$ac_cv_prog_gcc 569 rtems_cv_prog_cc_g=$ac_cv_prog_cc_g 570 rtems_cv_prog_cc_works=$ac_cv_prog_cc_works 571 rtems_cv_prog_cc_cross=$ac_cv_prog_cc_cross 572 573 dnl restore initial values 574 CC=$rtems_save_CC 575 CFLAGS=$rtems_save_CFLAGS 576 577 unset ac_cv_prog_gcc 578 unset ac_cv_prog_cc_g 579 unset ac_cv_prog_cc_works 580 unset ac_cv_prog_cc_cross 581 ]) 582 583 AC_DEFUN(RTEMS_PROG_CC_FOR_TARGET, 584 [ 585 dnl check target cc 586 RTEMS_PROG_CC 587 dnl check if the compiler supports --specs 588 RTEMS_GCC_SPECS 589 dnl check if the target compiler may use --pipe 590 RTEMS_GCC_PIPE 591 dnl check if the compiler supports --specs if gcc28 is requested 592 if test "$RTEMS_USE_GCC272" != "yes" ; then 593 if test "$rtems_cv_gcc_specs" = "no"; then 594 AC_MSG_WARN([*** disabling --enable-gcc28]) 595 RTEMS_USE_GCC272=yes 596 fi 597 fi 598 test "$rtems_cv_gcc_pipe" = "yes" && CC_FOR_TARGET="$CC_FOR_TARGET --pipe" 599 600 dnl FIXME: HACK for egcs/cygwin mixing '\\' and '/' in gcc -print-* 601 case $host_os in 602 *cygwin*) GCCSED="| sed 's%\\\\%/%g'" ;; 603 *) ;; 604 esac 605 AC_SUBST(GCCSED) 606 ]) 607 608 dnl 609 dnl $Id$ 610 dnl 611 dnl Set target tools 612 dnl 613 dnl 98/06/23 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 614 dnl fixing cache/environment variable handling 615 dnl adding checks for cygwin/egcs '\\'-bug 616 dnl adding checks for ranlib/ar -s problem 617 dnl 618 dnl 98/02/12 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 619 dnl 620 621 AC_DEFUN(RTEMS_GCC_PRINT, 622 [ case $host_os in 623 *cygwin*) 624 dnl FIXME: Hack for cygwin/egcs reporting mixed '\\' and '/' 625 dnl Should be removed once cygwin/egcs reports '/' only 626 $1=`$CC_FOR_TARGET --print-prog-name=$2 | sed -e 's%\\\\%/%g' ` 627 ;; 628 *) 629 $1=`$CC_FOR_TARGET --print-prog-name=$2` 630 ;; 631 esac 632 ]) 633 634 AC_DEFUN(RTEMS_PATH_TOOL, 635 [ 636 AC_MSG_CHECKING([target's $2]) 637 AC_CACHE_VAL(ac_cv_path_$1,:) 638 AC_MSG_RESULT([$ac_cv_path_$1]) 639 640 if test -n "$ac_cv_path_$1"; then 641 dnl retrieve the value from the cache 642 $1=$ac_cv_path_$1 643 else 644 dnl the cache was not set 645 if test -z "[$]$1" ; then 646 if test "$rtems_cv_prog_gcc" = "yes"; then 647 # We are using gcc, ask it about its tool 648 # NOTE: Necessary if gcc was configured to use the target's 649 # native tools or uses prefixes for gnutools (e.g. gas instead of as) 650 RTEMS_GCC_PRINT($1,$2) 651 fi 652 else 653 # The user set an environment variable. 654 # Check whether it is an absolute path, otherwise AC_PATH_PROG 655 # will override the environment variable, which isn't what the user 656 # intends 657 AC_MSG_CHECKING([whether environment variable $1 is an absolute path]) 658 case "[$]$1" in 659 /*) # valid 660 AC_MSG_RESULT("yes") 661 ;; 662 *) # invalid for AC_PATH_PROG 663 AC_MSG_RESULT("no") 664 AC_MSG_ERROR([***] 665 [Environment variable $1 should either] 666 [be unset (preferred) or contain an absolute path]) 667 ;; 668 esac 669 fi 670 671 AC_PATH_PROG($1,"$program_prefix"$2,$3) 672 fi 673 ]) 674 675 AC_DEFUN(RTEMS_CANONICALIZE_TOOLS, 676 [AC_REQUIRE([RTEMS_PROG_CC])dnl 677 678 dnl FIXME: What shall be done if these tools are not available? 679 RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no) 680 RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no) 681 RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no) 682 RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no) 683 684 dnl special treatment of ranlib 685 RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no) 686 if test "$RANLIB_FOR_TARGET" = "no"; then 687 # ranlib wasn't found; check if ar -s is available 688 RTEMS_AR_FOR_TARGET_S 689 if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then 690 dnl override RANLIB_FOR_TARGET's cache 691 ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s" 692 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET 693 else 694 AC_MSG_ERROR([***] 695 [Can't figure out how to build a library index] 696 [Neither ranlib nor ar -s seem to be available] ) 697 fi 698 fi 699 700 dnl NOTE: These may not be available if not using gnutools 701 RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no) 702 RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no) 703 RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no) 704 ]) 705 706 dnl 707 dnl $Id$ 708 dnl 709 710 AC_DEFUN(RTEMS_AR_FOR_TARGET_S, 711 [ 712 AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works, 713 rtems_cv_AR_FOR_TARGET_S, 714 [ 715 cat > conftest.$ac_ext <<EOF 716 int foo( int b ) 717 { return b; } 718 EOF 719 if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \ 720 && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \ 721 && test -s conftest.a ; \ 722 then 723 rtems_cv_AR_FOR_TARGET_S="yes" 724 else 725 rtems_cv_AR_FOR_TARGET_S="no" 726 fi 727 rm -f conftest* 728 ]) 729 ]) 730 731 732 dnl 733 dnl $Id$ 734 dnl 735 dnl Set program_prefix 736 dnl 737 dnl 98/05/20 Ralf Corsepius (corsepiu@faw.uni-ulm.de) 738 dnl Extracted from configure 739 740 AC_DEFUN(RTEMS_TOOL_PREFIX, 741 [AC_REQUIRE([AC_CANONICAL_TARGET])dnl 742 AC_REQUIRE([AC_CANONICAL_BUILD])dnl 743 744 changequote(,)dnl 745 if [ "${program_prefix}" = "NONE" ] ; then 746 if [ "${target}" = "${host}" ] ; then 747 program_prefix= 748 else 749 program_prefix=${target}- 750 fi 751 fi 752 changequote([,])dnl 753 ]) 754 755 dnl 756 dnl $Id$ 757 dnl 758 dnl Check whether the target compiler accepts -specs 759 dnl 760 761 AC_DEFUN(RTEMS_GCC_SPECS, 762 [AC_REQUIRE([RTEMS_PROG_CC]) 763 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs, 764 [ 765 rtems_cv_gcc_specs=no 766 if test "$rtems_cv_prog_gcc" = "yes"; then 767 touch confspec 768 echo 'void f(){}' >conftest.c 769 if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then 770 rtems_cv_gcc_specs=yes 771 fi 772 fi 773 rm -f confspec conftest* 774 ])]) 775 776 dnl 777 dnl $Id$ 778 dnl 779 dnl Check whether the target compiler accepts -pipe 780 dnl 781 dnl 98/02/11 Ralf Corsepius corsepiu@faw.uni-ulm.de 782 dnl 783 784 AC_DEFUN(RTEMS_GCC_PIPE, 785 [AC_REQUIRE([RTEMS_PROG_CC]) 786 AC_REQUIRE([AC_CANONICAL_HOST]) 787 AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe, 788 [ 789 rtems_cv_gcc_pipe=no 790 if test "$rtems_cv_prog_gcc" = "yes"; then 791 case "$host_os" in 792 cygwin*) 793 ;; 794 *) 795 echo 'void f(){}' >conftest.c 796 if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then 797 rtems_cv_gcc_pipe=yes 798 fi 799 rm -f conftest* 800 ;; 801 esac 802 fi 803 ]) 804 ]) 805 806 dnl $Id$ 807 808 AC_DEFUN(RTEMS_CHECK_NEWLIB, 809 [dnl 810 AC_REQUIRE([RTEMS_PROG_CC_FOR_TARGET])dnl 811 AC_REQUIRE([RTEMS_CANONICALIZE_TOOLS])dnl 812 AC_CACHE_CHECK([for newlib], 813 rtems_cv_use_newlib, 814 [ 815 rtems_save_CC=$CC 816 CC=$CC_FOR_TARGET 817 818 dnl some versions of newlib provide not_required_by_rtems 819 AC_TRY_LINK( 820 [extern int not_required_by_rtems() ;], 821 [not_required_by_rtems()], 822 rtems_cv_use_newlib="yes") 823 824 dnl older versions of newlib provided rtems_provides_crt0 825 if test -z "$rtems_cv_use_newlib"; then 826 AC_TRY_LINK( 827 [extern int rtems_provides_crt0 ;], 828 [rtems_provides_crt0 = 0], 829 rtems_cv_use_newlib="yes", 830 rtems_cv_use_newlib="no") 831 fi 832 CC=$rtems_save_CC]) 833 RTEMS_USE_NEWLIB="$rtems_cv_use_newlib" 834 AC_SUBST(RTEMS_USE_NEWLIB) 835 ]) 836 724 837 725 838 dnl -
c/src/exec/score/cpu/configure
rd83c39dc r4075af6f 536 536 537 537 538 538 539 # Check whether --with-target-subdir or --without-target-subdir was given. 539 540 if test "${with_target_subdir+set}" = set; then … … 549 550 550 551 echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6 551 echo "configure:55 2: checking for RTEMS Version" >&5552 echo "configure:553: checking for RTEMS Version" >&5 552 553 if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then 553 554 RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \ … … 582 583 583 584 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 584 echo "configure:58 5: checking whether ${MAKE-make} sets \${MAKE}" >&5585 echo "configure:586: checking whether ${MAKE-make} sets \${MAKE}" >&5 585 586 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` 586 587 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then … … 637 638 638 639 echo $ac_n "checking host system type""... $ac_c" 1>&6 639 echo "configure:64 0: checking host system type" >&5640 echo "configure:641: checking host system type" >&5 640 641 641 642 host_alias=$host … … 658 659 659 660 echo $ac_n "checking target system type""... $ac_c" 1>&6 660 echo "configure:66 1: checking target system type" >&5661 echo "configure:662: checking target system type" >&5 661 662 662 663 target_alias=$target … … 676 677 677 678 echo $ac_n "checking build system type""... $ac_c" 1>&6 678 echo "configure:6 79: checking build system type" >&5679 echo "configure:680: checking build system type" >&5 679 680 680 681 build_alias=$build … … 699 700 700 701 echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6 701 echo "configure:70 2: checking rtems target cpu" >&5702 echo "configure:703: checking rtems target cpu" >&5 702 703 case "${target}" in 703 704 # hpux unix port should go here … … 726 727 727 728 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6 728 echo "configure:7 29: checking whether to enable maintainer-specific portions of Makefiles" >&5729 echo "configure:730: checking whether to enable maintainer-specific portions of Makefiles" >&5 729 730 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. 730 731 if test "${enable_maintainer_mode+set}" = set; then … … 760 761 RTEMS_HAS_MULTIPROCESSING=no 761 762 fi 763 762 764 763 765 … … 822 824 823 825 826 824 827 echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6 825 echo "configure:82 6: checking for RTEMS_BSP" >&5828 echo "configure:829: checking for RTEMS_BSP" >&5 826 829 if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then 827 830 echo $ac_n "(cached) $ac_c" 1>&6 … … 850 853 # ./install, which can be erroneously created by make from ./install.sh. 851 854 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 852 echo "configure:85 3: checking for a BSD compatible install" >&5855 echo "configure:856: checking for a BSD compatible install" >&5 853 856 if test -z "$INSTALL"; then 854 857 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then … … 905 908 906 909 910 907 911 # Is this a supported CPU? 908 912 echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6 909 echo "configure:91 0: checking if cpu $RTEMS_CPU is supported" >&5913 echo "configure:914: checking if cpu $RTEMS_CPU is supported" >&5 910 914 if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then 911 915 echo "$ac_t""yes" 1>&6 … … 968 972 set dummy $ac_prog; ac_word=$2 969 973 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 970 echo "configure:97 1: checking for $ac_word" >&5974 echo "configure:975: checking for $ac_word" >&5 971 975 if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then 972 976 echo $ac_n "(cached) $ac_c" 1>&6 … … 1012 1016 1013 1017 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 1014 echo "configure:101 5: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&51018 echo "configure:1019: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 1015 1019 1016 1020 ac_ext=c … … 1023 1027 cat > conftest.$ac_ext << EOF 1024 1028 1025 #line 10 26"configure"1029 #line 1030 "configure" 1026 1030 #include "confdefs.h" 1027 1031 1028 1032 main(){return(0);} 1029 1033 EOF 1030 if { (eval echo configure:103 1: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then1034 if { (eval echo configure:1035: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1031 1035 ac_cv_prog_cc_works=yes 1032 1036 # If we can't run a trivial program, we are probably using a cross compiler. … … 1054 1058 fi 1055 1059 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 1056 echo "configure:10 57: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&51060 echo "configure:1061: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 1057 1061 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 1058 1062 cross_compiling=$ac_cv_prog_cc_cross 1059 1063 1060 1064 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 1061 echo "configure:106 2: checking whether we are using GNU C" >&51065 echo "configure:1066: checking whether we are using GNU C" >&5 1062 1066 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then 1063 1067 echo $ac_n "(cached) $ac_c" 1>&6 … … 1068 1072 #endif 1069 1073 EOF 1070 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:107 1: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then1074 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1075: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then 1071 1075 ac_cv_prog_gcc=yes 1072 1076 else … … 1083 1087 CFLAGS= 1084 1088 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 1085 echo "configure:10 86: checking whether ${CC-cc} accepts -g" >&51089 echo "configure:1090: checking whether ${CC-cc} accepts -g" >&5 1086 1090 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then 1087 1091 echo $ac_n "(cached) $ac_c" 1>&6 … … 1125 1129 1126 1130 echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6 1127 echo "configure:11 28: checking whether $CC_FOR_TARGET accepts -specs" >&51131 echo "configure:1132: checking whether $CC_FOR_TARGET accepts -specs" >&5 1128 1132 if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then 1129 1133 echo $ac_n "(cached) $ac_c" 1>&6 … … 1146 1150 1147 1151 echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6 1148 echo "configure:11 49: checking whether $CC_FOR_TARGET accepts --pipe" >&51152 echo "configure:1153: checking whether $CC_FOR_TARGET accepts --pipe" >&5 1149 1153 if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then 1150 1154 echo $ac_n "(cached) $ac_c" 1>&6 … … 1187 1191 1188 1192 echo $ac_n "checking target's ar""... $ac_c" 1>&6 1189 echo "configure:119 0: checking target's ar" >&51193 echo "configure:1194: checking target's ar" >&5 1190 1194 if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then 1191 1195 echo $ac_n "(cached) $ac_c" 1>&6 … … 1220 1224 # intends 1221 1225 echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1222 echo "configure:122 3: checking whether environment variable AR_FOR_TARGET is an absolute path" >&51226 echo "configure:1227: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5 1223 1227 case "$AR_FOR_TARGET" in 1224 1228 /*) # valid … … 1237 1241 set dummy "$program_prefix"ar; ac_word=$2 1238 1242 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1239 echo "configure:124 0: checking for $ac_word" >&51243 echo "configure:1244: checking for $ac_word" >&5 1240 1244 if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then 1241 1245 echo $ac_n "(cached) $ac_c" 1>&6 … … 1274 1278 1275 1279 echo $ac_n "checking target's as""... $ac_c" 1>&6 1276 echo "configure:12 77: checking target's as" >&51280 echo "configure:1281: checking target's as" >&5 1277 1281 if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then 1278 1282 echo $ac_n "(cached) $ac_c" 1>&6 … … 1307 1311 # intends 1308 1312 echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1309 echo "configure:131 0: checking whether environment variable AS_FOR_TARGET is an absolute path" >&51313 echo "configure:1314: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5 1310 1314 case "$AS_FOR_TARGET" in 1311 1315 /*) # valid … … 1324 1328 set dummy "$program_prefix"as; ac_word=$2 1325 1329 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1326 echo "configure:13 27: checking for $ac_word" >&51330 echo "configure:1331: checking for $ac_word" >&5 1327 1331 if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then 1328 1332 echo $ac_n "(cached) $ac_c" 1>&6 … … 1361 1365 1362 1366 echo $ac_n "checking target's ld""... $ac_c" 1>&6 1363 echo "configure:136 4: checking target's ld" >&51367 echo "configure:1368: checking target's ld" >&5 1364 1368 if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then 1365 1369 echo $ac_n "(cached) $ac_c" 1>&6 … … 1394 1398 # intends 1395 1399 echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1396 echo "configure:1 397: checking whether environment variable LD_FOR_TARGET is an absolute path" >&51400 echo "configure:1401: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5 1397 1401 case "$LD_FOR_TARGET" in 1398 1402 /*) # valid … … 1411 1415 set dummy "$program_prefix"ld; ac_word=$2 1412 1416 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1413 echo "configure:141 4: checking for $ac_word" >&51417 echo "configure:1418: checking for $ac_word" >&5 1414 1418 if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then 1415 1419 echo $ac_n "(cached) $ac_c" 1>&6 … … 1448 1452 1449 1453 echo $ac_n "checking target's nm""... $ac_c" 1>&6 1450 echo "configure:145 1: checking target's nm" >&51454 echo "configure:1455: checking target's nm" >&5 1451 1455 if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then 1452 1456 echo $ac_n "(cached) $ac_c" 1>&6 … … 1481 1485 # intends 1482 1486 echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1483 echo "configure:148 4: checking whether environment variable NM_FOR_TARGET is an absolute path" >&51487 echo "configure:1488: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5 1484 1488 case "$NM_FOR_TARGET" in 1485 1489 /*) # valid … … 1498 1502 set dummy "$program_prefix"nm; ac_word=$2 1499 1503 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1500 echo "configure:150 1: checking for $ac_word" >&51504 echo "configure:1505: checking for $ac_word" >&5 1501 1505 if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then 1502 1506 echo $ac_n "(cached) $ac_c" 1>&6 … … 1536 1540 1537 1541 echo $ac_n "checking target's ranlib""... $ac_c" 1>&6 1538 echo "configure:15 39: checking target's ranlib" >&51542 echo "configure:1543: checking target's ranlib" >&5 1539 1543 if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then 1540 1544 echo $ac_n "(cached) $ac_c" 1>&6 … … 1569 1573 # intends 1570 1574 echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1571 echo "configure:157 2: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&51575 echo "configure:1576: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5 1572 1576 case "$RANLIB_FOR_TARGET" in 1573 1577 /*) # valid … … 1586 1590 set dummy "$program_prefix"ranlib; ac_word=$2 1587 1591 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1588 echo "configure:15 89: checking for $ac_word" >&51592 echo "configure:1593: checking for $ac_word" >&5 1589 1593 if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then 1590 1594 echo $ac_n "(cached) $ac_c" 1>&6 … … 1625 1629 1626 1630 echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6 1627 echo "configure:16 28: checking whether $AR_FOR_TARGET -s works" >&51631 echo "configure:1632: checking whether $AR_FOR_TARGET -s works" >&5 1628 1632 if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then 1629 1633 echo $ac_n "(cached) $ac_c" 1>&6 … … 1634 1638 { return b; } 1635 1639 EOF 1636 if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:16 37: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \1637 && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:16 38: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \1640 if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1641: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \ 1641 && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1642: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \ 1638 1642 && test -s conftest.a ; \ 1639 1643 then … … 1660 1664 1661 1665 echo $ac_n "checking target's objcopy""... $ac_c" 1>&6 1662 echo "configure:166 3: checking target's objcopy" >&51666 echo "configure:1667: checking target's objcopy" >&5 1663 1667 if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then 1664 1668 echo $ac_n "(cached) $ac_c" 1>&6 … … 1693 1697 # intends 1694 1698 echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1695 echo "configure:1 696: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&51699 echo "configure:1700: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5 1696 1700 case "$OBJCOPY_FOR_TARGET" in 1697 1701 /*) # valid … … 1710 1714 set dummy "$program_prefix"objcopy; ac_word=$2 1711 1715 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1712 echo "configure:171 3: checking for $ac_word" >&51716 echo "configure:1717: checking for $ac_word" >&5 1713 1717 if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then 1714 1718 echo $ac_n "(cached) $ac_c" 1>&6 … … 1747 1751 1748 1752 echo $ac_n "checking target's size""... $ac_c" 1>&6 1749 echo "configure:175 0: checking target's size" >&51753 echo "configure:1754: checking target's size" >&5 1750 1754 if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then 1751 1755 echo $ac_n "(cached) $ac_c" 1>&6 … … 1780 1784 # intends 1781 1785 echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1782 echo "configure:178 3: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&51786 echo "configure:1787: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5 1783 1787 case "$SIZE_FOR_TARGET" in 1784 1788 /*) # valid … … 1797 1801 set dummy "$program_prefix"size; ac_word=$2 1798 1802 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1799 echo "configure:180 0: checking for $ac_word" >&51803 echo "configure:1804: checking for $ac_word" >&5 1800 1804 if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then 1801 1805 echo $ac_n "(cached) $ac_c" 1>&6 … … 1834 1838 1835 1839 echo $ac_n "checking target's strip""... $ac_c" 1>&6 1836 echo "configure:18 37: checking target's strip" >&51840 echo "configure:1841: checking target's strip" >&5 1837 1841 if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then 1838 1842 echo $ac_n "(cached) $ac_c" 1>&6 … … 1867 1871 # intends 1868 1872 echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6 1869 echo "configure:187 0: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&51873 echo "configure:1874: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5 1870 1874 case "$STRIP_FOR_TARGET" in 1871 1875 /*) # valid … … 1884 1888 set dummy "$program_prefix"strip; ac_word=$2 1885 1889 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 1886 echo "configure:18 87: checking for $ac_word" >&51890 echo "configure:1891: checking for $ac_word" >&5 1887 1891 if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then 1888 1892 echo $ac_n "(cached) $ac_c" 1>&6 … … 1922 1926 1923 1927 echo $ac_n "checking for newlib""... $ac_c" 1>&6 1924 echo "configure:192 5: checking for newlib" >&51928 echo "configure:1929: checking for newlib" >&5 1925 1929 if eval "test \"`echo '$''{'rtems_cv_use_newlib'+set}'`\" = set"; then 1926 1930 echo $ac_n "(cached) $ac_c" 1>&6 … … 1931 1935 1932 1936 cat > conftest.$ac_ext <<EOF 1933 #line 193 4"configure"1937 #line 1938 "configure" 1934 1938 #include "confdefs.h" 1935 1939 extern int not_required_by_rtems() ; … … 1938 1942 ; return 0; } 1939 1943 EOF 1940 if { (eval echo configure:194 1: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then1944 if { (eval echo configure:1945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1941 1945 rm -rf conftest* 1942 1946 rtems_cv_use_newlib="yes" … … 1949 1953 if test -z "$rtems_cv_use_newlib"; then 1950 1954 cat > conftest.$ac_ext <<EOF 1951 #line 195 2"configure"1955 #line 1956 "configure" 1952 1956 #include "confdefs.h" 1953 1957 extern int rtems_provides_crt0 ; … … 1956 1960 ; return 0; } 1957 1961 EOF 1958 if { (eval echo configure:19 59: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then1962 if { (eval echo configure:1963: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1959 1963 rm -rf conftest* 1960 1964 rtems_cv_use_newlib="yes" … … 1976 1980 1977 1981 # Check if there is custom/*.cfg for this BSP 1982 1983 1978 1984 echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6 1979 echo "configure:198 0: checking for make/custom/$RTEMS_BSP.cfg" >&51985 echo "configure:1986: checking for make/custom/$RTEMS_BSP.cfg" >&5 1980 1986 if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then 1981 1987 echo "$ac_t""yes" 1>&6 … … 1984 1990 fi 1985 1991 1992 1986 1993 echo $ac_n "checking whether BSP supports multiprocessing""... $ac_c" 1>&6 1987 echo "configure:19 88: checking whether BSP supports multiprocessing" >&51994 echo "configure:1995: checking whether BSP supports multiprocessing" >&5 1988 1995 if eval "test \"`echo '$''{'rtems_cv_HAS_MP'+set}'`\" = set"; then 1989 1996 echo $ac_n "(cached) $ac_c" 1>&6 … … 2008 2015 2009 2016 2017 2010 2018 echo $ac_n "checking whether BSP supports libposix""... $ac_c" 1>&6 2011 echo "configure:20 12: checking whether BSP supports libposix" >&52019 echo "configure:2020: checking whether BSP supports libposix" >&5 2012 2020 if eval "test \"`echo '$''{'rtems_cv_HAS_POSIX_API'+set}'`\" = set"; then 2013 2021 echo $ac_n "(cached) $ac_c" 1>&6 … … 2038 2046 set dummy gcc; ac_word=$2 2039 2047 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 2040 echo "configure:204 1: checking for $ac_word" >&52048 echo "configure:2049: checking for $ac_word" >&5 2041 2049 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then 2042 2050 echo $ac_n "(cached) $ac_c" 1>&6 … … 2068 2076 set dummy cc; ac_word=$2 2069 2077 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 2070 echo "configure:207 1: checking for $ac_word" >&52078 echo "configure:2079: checking for $ac_word" >&5 2071 2079 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then 2072 2080 echo $ac_n "(cached) $ac_c" 1>&6 … … 2119 2127 set dummy cl; ac_word=$2 2120 2128 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 2121 echo "configure:21 22: checking for $ac_word" >&52129 echo "configure:2130: checking for $ac_word" >&5 2122 2130 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then 2123 2131 echo $ac_n "(cached) $ac_c" 1>&6 … … 2151 2159 2152 2160 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 2153 echo "configure:21 54: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&52161 echo "configure:2162: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 2154 2162 2155 2163 ac_ext=c … … 2162 2170 cat > conftest.$ac_ext << EOF 2163 2171 2164 #line 21 65"configure"2172 #line 2173 "configure" 2165 2173 #include "confdefs.h" 2166 2174 2167 2175 main(){return(0);} 2168 2176 EOF 2169 if { (eval echo configure:217 0: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then2177 if { (eval echo configure:2178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 2170 2178 ac_cv_prog_cc_works=yes 2171 2179 # If we can't run a trivial program, we are probably using a cross compiler. … … 2193 2201 fi 2194 2202 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 2195 echo "configure:2 196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&52203 echo "configure:2204: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 2196 2204 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 2197 2205 cross_compiling=$ac_cv_prog_cc_cross 2198 2206 2199 2207 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 2200 echo "configure:220 1: checking whether we are using GNU C" >&52208 echo "configure:2209: checking whether we are using GNU C" >&5 2201 2209 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then 2202 2210 echo $ac_n "(cached) $ac_c" 1>&6 … … 2207 2215 #endif 2208 2216 EOF 2209 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:221 0: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then2217 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2218: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then 2210 2218 ac_cv_prog_gcc=yes 2211 2219 else … … 2226 2234 CFLAGS= 2227 2235 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 2228 echo "configure:22 29: checking whether ${CC-cc} accepts -g" >&52236 echo "configure:2237: checking whether ${CC-cc} accepts -g" >&5 2229 2237 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then 2230 2238 echo $ac_n "(cached) $ac_c" 1>&6 … … 2261 2269 2262 2270 echo $ac_n "checking whether $RTEMS_HOST defines union semun""... $ac_c" 1>&6 2263 echo "configure:22 64: checking whether $RTEMS_HOST defines union semun" >&52271 echo "configure:2272: checking whether $RTEMS_HOST defines union semun" >&5 2264 2272 if eval "test \"`echo '$''{'rtems_cv_HAS_UNION_SEMUN'+set}'`\" = set"; then 2265 2273 echo $ac_n "(cached) $ac_c" 1>&6 2266 2274 else 2267 2275 cat > conftest.$ac_ext <<EOF 2268 #line 22 69"configure"2276 #line 2277 "configure" 2269 2277 #include "confdefs.h" 2270 2278 … … 2276 2284 ; return 0; } 2277 2285 EOF 2278 if { (eval echo configure:22 79: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then2286 if { (eval echo configure:2287: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then 2279 2287 rm -rf conftest* 2280 2288 rtems_cv_HAS_UNION_SEMUN="yes" … … 2300 2308 2301 2309 echo $ac_n "checking whether $RTEMS_HOST supports System V semaphores""... $ac_c" 1>&6 2302 echo "configure:23 03: checking whether $RTEMS_HOST supports System V semaphores" >&52310 echo "configure:2311: checking whether $RTEMS_HOST supports System V semaphores" >&5 2303 2311 if eval "test \"`echo '$''{'rtems_cv_sysv_sem'+set}'`\" = set"; then 2304 2312 echo $ac_n "(cached) $ac_c" 1>&6 … … 2309 2317 else 2310 2318 cat > conftest.$ac_ext <<EOF 2311 #line 23 12"configure"2319 #line 2320 "configure" 2312 2320 #include "confdefs.h" 2313 2321 … … 2335 2343 2336 2344 EOF 2337 if { (eval echo configure:23 38: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null2345 if { (eval echo configure:2346: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null 2338 2346 then 2339 2347 rtems_cv_sysv_sem="yes" … … 2358 2366 2359 2367 echo $ac_n "checking whether $RTEMS_HOST supports System V shared memory""... $ac_c" 1>&6 2360 echo "configure:236 1: checking whether $RTEMS_HOST supports System V shared memory" >&52368 echo "configure:2369: checking whether $RTEMS_HOST supports System V shared memory" >&5 2361 2369 if eval "test \"`echo '$''{'rtems_cv_sysv_shm'+set}'`\" = set"; then 2362 2370 echo $ac_n "(cached) $ac_c" 1>&6 … … 2367 2375 else 2368 2376 cat > conftest.$ac_ext <<EOF 2369 #line 237 0"configure"2377 #line 2378 "configure" 2370 2378 #include "confdefs.h" 2371 2379 … … 2383 2391 2384 2392 EOF 2385 if { (eval echo configure:23 86: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null2393 if { (eval echo configure:2394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null 2386 2394 then 2387 2395 rtems_cv_sysv_shm="yes" … … 2406 2414 2407 2415 echo $ac_n "checking whether $RTEMS_HOST supports System V messages""... $ac_c" 1>&6 2408 echo "configure:24 09: checking whether $RTEMS_HOST supports System V messages" >&52416 echo "configure:2417: checking whether $RTEMS_HOST supports System V messages" >&5 2409 2417 if eval "test \"`echo '$''{'rtems_cv_sysv_msg'+set}'`\" = set"; then 2410 2418 echo $ac_n "(cached) $ac_c" 1>&6 … … 2415 2423 else 2416 2424 cat > conftest.$ac_ext <<EOF 2417 #line 24 18"configure"2425 #line 2426 "configure" 2418 2426 #include "confdefs.h" 2419 2427 … … 2431 2439 2432 2440 EOF 2433 if { (eval echo configure:24 34: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null2441 if { (eval echo configure:2442: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null 2434 2442 then 2435 2443 rtems_cv_sysv_msg="yes" … … 2457 2465 2458 2466 echo $ac_n "checking for Makefile.in in $RTEMS_CPU""... $ac_c" 1>&6 2459 echo "configure:246 0: checking for Makefile.in in $RTEMS_CPU" >&52467 echo "configure:2468: checking for Makefile.in in $RTEMS_CPU" >&5 2460 2468 if test -d $srcdir/$RTEMS_CPU; then 2461 2469 rtems_av_save_dir=`pwd`; -
c/src/lib/aclocal.m4
rd83c39dc r4075af6f 20 20 AC_DEFUN(RTEMS_TOP, 21 21 [dnl 22 AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl <