grim/guifications2

Parents fc140d2c5a2f
Children 2672c10ea1e8
updated autogen to use printf since 'echo -n' isn't available everywhere
  • +22 -14
    autogen.sh
  • --- a/autogen.sh Fri Aug 07 15:06:23 2009 -0500
    +++ b/autogen.sh Fri Aug 07 15:11:54 2009 -0500
    @@ -54,12 +54,12 @@
    check () {
    CMD=$1
    - echo -n "checking for ${CMD}... "
    + printf "checking for ${CMD}... "
    BIN=`which ${CMD}`
    if [ x"${BIN}" = x"" ] ; then
    - echo "not found."
    - echo "${CMD} is required to build ${PACKAGE}!"
    + printf "not found.\n"
    + printf "${CMD} is required to build ${PACKAGE}!\n"
    exit 1;
    fi
    @@ -70,17 +70,25 @@
    CMD=$1
    shift
    - echo -n "running ${CMD} ${@}... "
    - OUTPUT=`${CMD} ${@} 2>&1`
    + OUTPUT=`mktemp autogen-XXXXXX`
    +
    + ARGS="${@}"
    + if [ x"${ARGS}" != x"" ] ; then
    + ARGS=" ${ARGS}"
    + fi
    +
    + printf "running '${CMD}${ARGS}' ... "
    + ${CMD} ${@} >${OUTPUT} 2>&1
    +
    if [ $? != 0 ] ; then
    echo "failed."
    - echo ${OUTPUT}
    + cat ${OUTPUT}
    + rm -f ${OUTPUT}
    exit 1
    else
    echo "done."
    - if [ x"${OUTPUT}" != x"" ] ; then
    - echo ${OUTPUT}
    - fi
    + cat ${OUTPUT}
    + rm -f ${OUTPUT}
    fi
    }
    @@ -98,14 +106,14 @@
    ###############################################################################
    # Look for our args file
    ###############################################################################
    -echo -n "checking for ${ARGS_FILE}: "
    +printf "checking for ${ARGS_FILE}: "
    if [ -f ${ARGS_FILE} ] ; then
    - echo "found."
    - echo -n "sourcing ${ARGS_FILE}: "
    + printf "found.\n"
    + printf "sourcing ${ARGS_FILE}: "
    . autogen.args
    - echo "done."
    + printf "done.\n"
    else
    - echo "not found."
    + printf "not found.\n"
    fi
    ###############################################################################