Changeset 9cf7774 in rtems for acinclude.m4


Ignore:
Timestamp:
Nov 5, 2002, 6:34:36 PM (17 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
83433304
Parents:
2595580
Message:

2002-11-05 Ralf Corsepius <corsepiu@…>

  • acinclude.m4: Adapations to autoconf > 2.52.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • acinclude.m4

    r2595580 r9cf7774  
    177177  # Always prepend --prefix to ensure using the same prefix
    178178  # in subdir configurations.
    179   ac_sub_configure_args="--prefix=$prefix $ac_sub_configure_args"
     179  ac_sub_configure_args="'--prefix=$prefix' $ac_sub_configure_args"
    180180
    181181  case "$$1_subdir" in
    182182  "." ) ;;
    183183  * )
    184     ac_sub_configure_args="$ac_sub_configure_args --with-target-subdir=$$1_subdir --exec-prefix=${prefix}/$$1_subdir"
     184    ac_sub_configure_args="$ac_sub_configure_args '--with-target-subdir=$$1_subdir' '--exec-prefix=${prefix}/$$1_subdir'"
    185185    ;;
    186186  esac
     
    228228      ac_sub_configure_vars=
    229229      test -n "[$]CC_FOR_$2" && \
    230         ac_sub_configure_vars="CC='[$]CC_FOR_$2'"
     230        ac_sub_configure_vars="'CC=[$]CC_FOR_$2'"
    231231      test -n "[$]CFLAGS_FOR_$2" && \
    232         ac_sub_configure_vars="$ac_sub_configure_vars CFLAGS='[$]CFLAGS_FOR_$2'"
     232        ac_sub_configure_vars="$ac_sub_configure_vars 'CFLAGS=[$]CFLAGS_FOR_$2'"
    233233      eval $ac_sub_configure_vars \
    234234        $ac_sub_configure $ac_sub_configure_args \
     
    256256])
    257257
     258AC_DEFUN([_RTEMS_CONFIGURE_ARGS_PRUNE],
     259[
     260  for ac_arg in m4_if([$3],,[$ac_configure_args],[[$]$3]); do
     261    if test -n "$ac_prev"; then
     262      ac_prev=
     263      configure
     264    fi
     265    # the eval casts away sh quotes
     266    case `eval echo $ac_arg` in
     267    -host* | --host* );;
     268    -host ) ac_prev=host_alias;;
     269    -target* | --target* );;
     270    -target | --target ) ac_prev=target_alias;;
     271    -build* | --build* );;
     272    -build | --build ) ac_prev=build_alias;;
     273    --cache* );;
     274    *_alias=* );;
     275    m4_if([$2],,,[$2])
     276    *) $1="$$1 '$ac_arg'" ;;
     277   esac
     278  done
     279])
     280
    258281AC_DEFUN(_RTEMS_BUILD_CONFIG_PREPARE,[
    259282# Record the configure arguments in Makefile.
    260283m4_ifdef([_RTEMS_BUILD_CONFIGDIRS_LIST],
    261284[
    262 buildargs=`echo "${ac_configure_args}" | \
    263         sed -e 's/--no[[^       ]]*//' \
    264             -e 's/--cache[[a-z-]]*=[[^  ]]*//' \
    265             -e 's/--ho[[a-z-]]*=[[^     ]]*//' \
    266             -e 's/--bu[[a-z-]]*=[[^     ]]*//' \
    267             -e 's/--ta[[a-z-]]*=[[^     ]]*//' \
    268             -e 's/[[^   ]]*alias=[[^    ]]*//g'` ;
    269 
    270 buildargs="--host=${build} --build=${build} --target=${target_alias} ${buildargs}"
     285_RTEMS_CONFIGURE_ARGS_PRUNE([buildargs])
     286buildargs="'--host=${build}' '--build=${build}' '--target=${target_alias}' ${buildargs}"
    271287AC_SUBST(buildargs)
    272288
     
    311327[
    312328# Record configure arguments in Makefile.
    313 hostargs=`echo "${ac_configure_args}" | \
    314         sed -e 's/--no[[^       ]]*//' \
    315             -e 's/--cache[[a-z-]]*=[[^  ]]*//' \
    316             -e 's/--ho[[a-z-]]*=[[^     ]]*//' \
    317             -e 's/--bu[[a-z-]]*=[[^     ]]*//' \
    318             -e 's/--ta[[a-z-]]*=[[^     ]]*//' \
    319             -e 's/[[^   ]]*alias=[[^    ]]*//g'` ;
    320 
    321 hostargs="--host=${host_alias} --build=${build} --target=${target_alias} ${hostargs}"
     329_RTEMS_CONFIGURE_ARGS_PRUNE([hostargs])
     330hostargs="'--host=${host_alias}' '--build=${build}' '--target=${target_alias}' ${hostargs}"
    322331AC_SUBST(hostargs)
    323332
     
    362371[
    363372# Record the configure arguments in Makefile.
    364 targetargs=`echo "${ac_configure_args}" | \
    365         sed -e 's/--no[[^       ]]*//' \
    366             -e 's/--cache[[a-z-]]*=[[^  ]]*//' \
    367             -e 's/--ho[[a-z-]]*=[[^     ]]*//' \
    368             -e 's/--bu[[a-z-]]*=[[^     ]]*//' \
    369             -e 's/--ta[[a-z-]]*=[[^     ]]*//' \
    370             -e 's/[[^   ]]*alias=[[^    ]]*//g'` ;
    371 
    372 targetargs="--host=${target_alias} --build=${build} --target=${target_alias} ${targetargs}"
     373_RTEMS_CONFIGURE_ARGS_PRUNE([targetargs])
     374targetargs="'--host=${target_alias}' '--build=${build}' '--target=${target_alias}' ${targetargs}"
    373375AC_SUBST(targetargs)
    374376
Note: See TracChangeset for help on using the changeset viewer.