automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Weird behaviour of AM_CONDITIONAL


From: Thibaut Le Guilly
Subject: Re: Weird behaviour of AM_CONDITIONAL
Date: Sat, 3 Sep 2011 14:12:32 +0200

Hi Eric,

It was in fact my mistake, I'm really sorry for posting for such a trivial
issue, but I'm a real beginner to autotools and I guess that after spending
hours understanding all the complex principles, I didn't take care enough to
basic stuff.

Anyway thank you very much for your fast answer, I'm really happy to have my
first autotools project working now!

Have a great week-end!

On Fri, Sep 2, 2011 at 6:48 PM, Eric Blake <address@hidden> wrote:

> On 09/02/2011 08:24 AM, Thibaut Le Guilly wrote:
>
>> I am using AM_CONDITIONAL to enable a user to choose between one kind of
>> library and another one with :
>>
>> AM_CONDITIONAL([ENABLE_A], [test x$condition=xyes])
>>
>
> > Am I doing something wrong? Do you know how to solve this problem?
>
> Wrong syntax.  You meant:
>
> test "x$condition" = xyes
>
> the quoting around $condition, and the spacing around =, are essential in
> shell syntax.  Otherwise, if $condition has no whitespace to cause IFS word
> splitting, you end up testing whether the single word x$condition=xyes is
> non-empty, which it is, so the test is always true.
>
> --
> Eric Blake   address@hidden    +1-801-349-2682
> Libvirt virtualization library http://libvirt.org
>



-- 
Thibaut Le Guilly
Research Assistant at Aalborg University
Embedded System Engineer (ECE Paris)
Software System Engineer (Aalborg University)


reply via email to

[Prev in Thread] Current Thread [Next in Thread]