scripts/xldd: use user's sed and grep
author"Yann E. MORIN" <yann.morin.1998@free.fr>
Wed Dec 05 20:31:43 2012 +0100 (2012-12-05)
changeset 3134863723936e24
parent 3133 36aa2ae92c29
child 3135 3829050af02a
scripts/xldd: use user's sed and grep

xldd uses sed and grep as detected by ./configure. This works well if is
used on the machine that build the toolchain.

But if the user moves the toolchain to another machine where sed and grep
are not in the same directory (eg. /bin/sed vs. /usr/bin/sed), then xldd
will stop functionning.

Fix that by using ${SED} and ${GREP} if they are set in the environment.

Reported-by: Samuel Martin <s.martin49@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
scripts/xldd.in
     1.1 --- a/scripts/xldd.in	Sun Nov 25 18:22:38 2012 +0100
     1.2 +++ b/scripts/xldd.in	Wed Dec 05 20:31:43 2012 +0100
     1.3 @@ -4,8 +4,8 @@
     1.4  export LC_ALL=C
     1.5  version="@@CT_VERSION@@"
     1.6  bits="@@CT_BITS@@"
     1.7 -sed="@@CT_sed@@"
     1.8 -grep="@@CT_grep@@"
     1.9 +sed="${SED:-@@CT_sed@@}"
    1.10 +grep="${GREP:-@@CT_grep@@}"
    1.11  
    1.12  my_name="$( basename "${0}" )"
    1.13  prefix="${0%-ldd}"