This will fix with issues like this [1]:
Aug 12 09:58:44 '/usr/bin/cmake' '--build' '/build/build_docker/native' '--target' 'pre_compressor'
Aug 12 09:58:44 sccache: error: Server startup failed: cache storage failed to read: Unexpected (temporary) at stat
Aug 12 09:58:45 ninja: build stopped: subcommand failed.
Aug 12 09:58:45 -- Configuring done (77.7s)
Aug 12 09:58:47 -- Generating done (1.8s)
Aug 12 09:58:47 -- Build files have been written to: /build/build_docker
So as you can see even if ninja fails it still wrote build files, while
it should fail.
[1]: https://s3.amazonaws.com/clickhouse-test-reports/64955/0af41e32a5822d25ac3760f1ebb2313557474701/builds/report.html
[2]: 0af41e32a5/binary_darwin_aarch64/build_log.log
Note, COMMAND_ERROR_IS_FATAL is 3.19+, and the requirement for now is
3.20
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
c-ares searching for gethostbyname in the libnsl library, however in the
version that shipped with gRPC it doing it wrong [1], since it uses
CHECK_LIBRARY_EXISTS(), which will return TRUE even if the function exists in
another dependent library. The upstream already contains correct macro [2],
but it is not included in gRPC (even upstream gRPC, not the one that is
shipped with clickhousee).
[1]: e982924ace/CMakeLists.txt (L125)
[2]: 44fbc81368/CMakeLists.txt (L146)
And because if you by some reason have libnsl [3] installed, clickhouse will
reject to start w/o it. While this is completelly different library.
[3]: https://packages.debian.org/bullseye/libnsl2