can 'test -z ""' be false?
From: the_googlemail (_at_(the_googlemail).com)
Date: 04/25/05
- Next message: the_googlemail: "Re: can 'test -z ""' be false?"
- Previous message: Kasper Dupont: "Re: Vectorization in gcc 4.0"
- Next in thread: the_googlemail: "Re: can 'test -z ""' be false?"
- Reply: the_googlemail: "Re: can 'test -z ""' be false?"
- Reply: Sergei Organov: "Re: can 'test -z ""' be false?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 24 Apr 2005 23:31:06 -0400
I have tried to install Qterm(requires Qt 3.1+) on my fedora 3C and fail
during the configure process due to that it cannot found my Qt library,
though I have supplied the correct path everywhere. However, after I
change part of the configure file as below. However, I am not sure about
the reason and hope some one can tell me. Specifically, what confused me
is that how can 'test -z "" ' produce a false? Should it always be true?
(I am a newbie to bash......)
Many thanks.
----------------------------------------------------
if test -z ""; then
#--------------V---I just changed these "2"s into "3".
kde_qtver=2
kde_qtsubver=2
else
kde_qtsubver=`echo "" | sed -e 's#[0-9]\+\.\([0-9]\+\).*#\1#'`
# following is the check if subversion isnīt found in passed argument
if test "$kde_qtsubver" = ""; then
kde_qtsubver=1
fi
kde_qtver=`echo "" | sed -e 's#^\([0-9]\+\)\..*#\1#'`
if test "$kde_qtver" = "1"; then
kde_qtsubver=42
fi
fi
---------------
p.s. I know there is a bash group....but really few people there....
- Next message: the_googlemail: "Re: can 'test -z ""' be false?"
- Previous message: Kasper Dupont: "Re: Vectorization in gcc 4.0"
- Next in thread: the_googlemail: "Re: can 'test -z ""' be false?"
- Reply: the_googlemail: "Re: can 'test -z ""' be false?"
- Reply: Sergei Organov: "Re: can 'test -z ""' be false?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|