X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=build.sh;h=57f3d4449a99bef83b75b50f425dc548bc9ead60;hb=72a76347831a848e6722d9147297a1e03c4c01d8;hp=3efb44f64047c5bdeedf6dc5d646230645a4afcd;hpb=a2ef6243e563dae68c71d58c1d9af924a5817e5a;p=collectd.git diff --git a/build.sh b/build.sh index 3efb44f6..57f3d444 100755 --- a/build.sh +++ b/build.sh @@ -1,9 +1,53 @@ #! /bin/sh -libtoolize=libtoolize +GLOBAL_ERROR_INDICATOR=0 -if which glibtoolize > /dev/null 2>&1; then - libtoolize=glibtoolize +check_for_application () +{ + for PROG in "$@" + do + which "$PROG" >/dev/null 2>&1 + if test $? -ne 0; then + cat >&2 </dev/null 2>/dev/null +if test $? -eq 0 +then + libtoolize=libtoolize +else + glibtoolize --version >/dev/null 2>/dev/null + if test $? -eq 0 + then + libtoolize=glibtoolize + else + cat >&2 <