diff options
authorYuri Victorovich <yuri@FreeBSD.org>2022-07-09 14:50:47 +0000
committerYuri Victorovich <yuri@FreeBSD.org>2022-07-09 14:52:33 +0000
commit6af95e9e48b065580cbac3f329e73c2b83e7f02d (patch)
parentb43d535264ba9be733eaad37350a907b952c26fc (diff)
Mk/Scripts/qa.sh: Bogus 'xx doesn't have a SONAME' messages are printed by stage-qa for some shared libraries
Reason: 'grep -q SONAME' ends before it drains the pipe, pipe fails when the remaining output is too long, and 'set -o pipefail' causes the whole command to fail when it is supposed to succeed. Remedy: Please apply the attached patch fix-SONAME.patch, or alternatively remove 'set -o pipefail' from qa.sh PR: 259992 Approved by: tcberner@ (as portmgr)
1 files changed, 2 insertions, 2 deletions
diff --git a/Mk/Scripts/qa.sh b/Mk/Scripts/qa.sh
index 20d1e296dd5c..dd0f3440c299 100644
--- a/Mk/Scripts/qa.sh
+++ b/Mk/Scripts/qa.sh
@@ -673,7 +673,7 @@ proxydeps() {
# When grep -q finds a match it will close the pipe immediately.
# This may cause the test to fail when pipefail is turned on.
set +o pipefail
- if ! readelf -d "${dep_file}" | grep -q SONAME; then
+ if ! readelf -d "${dep_file}" | grep SONAME > /dev/null; then
err "${file} is linked to ${dep_file} which does not have a SONAME. ${dep_file_pkg} needs to be fixed."
set -o pipefail
@@ -724,7 +724,7 @@ sonames() {
[ -z "${f}" ] && continue
# Ignore symlinks
[ -f "${f}" -a ! -L "${f}" ] || continue
- if ! readelf -d ${f} | grep -q SONAME; then
+ if ! readelf -d ${f} | grep SONAME > /dev/null; then
warn "${f} doesn't have a SONAME."
warn "pkg(8) will not register it as being provided by the port."
warn "If another port depend on it, pkg will not be able to know where it comes from."