Fix broken pipe due to /usr/bin/ldd (#9606)

Motivation:

The build script for the module Netty Transport Native Epoll can cause
intermittent build break due to broken pipe by /usr/bin/ldd. This issue
likely to occur on a build environment with multiple processors.

Modifications:

The root cause is that the consumer head command finishes earlier the
producer ldd command. Buffering the outputs of the ldd command by an
intermediate tail command avoids the broken pipe.

Result:

A build on multiple processors can finish successfully.

Signed-off-by: Tatsushi Inagaki <e29253@jp.ibm.com>
This commit is contained in:
Tatsushi Inagaki 2019-09-27 05:26:45 +09:00 committed by Norman Maurer
parent 43f7a9ea2a
commit e8f823ef46

View File

@ -208,7 +208,7 @@
<tasks>
<exec executable="sh" outputproperty="ldd_version">
<arg value="-c" />
<arg value="ldd --version | head -1" />
<arg value="ldd --version | tail | head -1" />
</exec>
<exec executable="uname" outputproperty="uname_os_version">
<arg value="-r" />