diff options
author | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2007-03-09 08:33:34 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2007-03-09 08:33:34 +0000 |
commit | 1506b0cfd5708c81fe286549d63843c5030c0e8a (patch) | |
tree | 46ed27097f9ccc05feaa4e021534519a50235ee4 /toolchain/dependencies/dependencies.sh | |
parent | a9612bfdd90268cf065b09e8a0ff1b6c8a99b399 (diff) | |
download | buildroot-novena-1506b0cfd5708c81fe286549d63843c5030c0e8a.tar.gz buildroot-novena-1506b0cfd5708c81fe286549d63843c5030c0e8a.zip |
Improve the checking of sed by adding some common GNU sed installation
names (gsed/gnused), checking for a basic OS X sed feature in command
line option handling, checking the actual result of the sed run against
the expected result, and placing common code for the check under
toolchain/dependencies/. (Heikki Lindholm)
Diffstat (limited to 'toolchain/dependencies/dependencies.sh')
-rwxr-xr-x | toolchain/dependencies/dependencies.sh | 43 |
1 files changed, 19 insertions, 24 deletions
diff --git a/toolchain/dependencies/dependencies.sh b/toolchain/dependencies/dependencies.sh index 084e835cb..40bfd9a2a 100755 --- a/toolchain/dependencies/dependencies.sh +++ b/toolchain/dependencies/dependencies.sh @@ -88,30 +88,6 @@ fi; ############################################################# # -# check build system 'sed' -# -############################################################# -if test -x /usr/bin/sed ; then - SED="/usr/bin/sed" -else - if test -x /bin/sed ; then - SED="/bin/sed" - else - SED="sed" - fi -fi -echo "HELLO" > .sedtest -$SED -i -e "s/HELLO/GOODBYE/" .sedtest >/dev/null 2>&1 -if test $? != 0 ; then - echo "sed works: No, using buildroot version instead" -else - echo "sed works: Ok" -fi -rm -f .sedtest -XSED=$HOST_SED_DIR/bin/sed - -############################################################# -# # check build system 'which' # ############################################################# @@ -123,6 +99,25 @@ fi; echo "which installed: Ok" + +############################################################# +# +# check build system 'sed' +# +############################################################# +SED=$(toolchain/dependencies/check-host-sed.sh) + +if [ -z "$SED" ] ; then + XSED=$HOST_SED_DIR/bin/sed + echo "sed works: No, using buildroot version instead" +else + XSED=$SED + echo "sed works: Ok ($SED)" +fi + + + + ############################################################# # # check build system 'make' |