Re: [PATCH v2 1/4] configure: improve libzbc version check

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

 



On Fri, 31 Jul 2020 at 00:09, Dmitry Fomichev <Dmitry.Fomichev@xxxxxxx> wrote:
>
> Right now, there is no default for libzbc ioengine support. If libzbc is found by
> configure, then libzbc ioengine will always be added. The new flag, --disable-libzbc,
> prevents adding support for libzbc ioengine in this case. If libzbc is not present,
> fio configure is not failed with "feature not found".
>
> Currently, no other feature in fio configure has the default option of "yes" and all
> features that can be explicitly set to yes are set so by script command line options.
> If a feature is set to yes and is not available, configure fails with "feature not found"
> error. Do we really want configure to fail on any system that doesn't have libzbc
> unless --disable-libzbc is added to the command line?
>
> There is one feature option, "disable_lex",  with the default value, "". I guess we
> could define libzbc option the same way to improve code clarity.

That's right:
- "yes": hard fail if probe fails
- "": probe but don't hard fail
- "no": don't probe and disable feature

So your suggestion of a default of "" is right because I can't believe
we want to hard fail when libzbc is unavailable.

I learned of this pattern while reading
https://github.com/qemu/qemu/blob/1448629751871c4924c234c2faaa968fc26890e1/configure#L348
which I think was the basis of fio's configure script. The desire to
show this pattern led to some of the refactoring in
https://github.com/axboe/fio/commit/d490af7f8c0ee7a992f332bb6bcffb30313d6488
even though it added some unncessary lines for those options...

-- 
Sitsofe | http://sucs.org/~sits/



[Index of Archives]     [Linux Kernel]     [Linux SCSI]     [Linux IDE]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux