trinity-devel@lists.pearsoncomputing.net

Message: previous - next
Month: January 2012

test: =: unary operator expected

From: Darrell Anderson <humanreadable@...>
Date: Thu, 19 Jan 2012 23:29:53 -0800 (PST)
I am receiving that error in all of my automake builds. The cause is the usual comparing a result to a non integer:

if test "$kde_qtver" = "3"; then
  if test "$kde_qtsubver" -le 1; then
    trinity2ornewer=
  fi
  if test "$kde_qtsubver" -le 2; then
    trinity3ornewer=
  fi
  if test "$KDECONFIG" != "compiled"; then
    if test `$KDECONFIG --version | grep KDE | sed 's/KDE: \(...\).*/\1/'` = 3.2; then
      trinity3ornewer=
    fi
  fi
fi

Is this test looking to test against 3 or 2? I think 2 because 3 is already established in the first test of this snippet.

Anyway, this needs a fixin'.

Up to you Tim!

Darrell