* [gentoo-commits] proj/portage:repoman commit in: bin/install-qa-check.d/
@ 2016-05-14 18:33 Brian Dolbec
0 siblings, 0 replies; 3+ messages in thread
From: Brian Dolbec @ 2016-05-14 18:33 UTC (permalink / raw
To: gentoo-commits
commit: 9266e8e8d5709b9046e085baf3521a9e7a744d5b
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Thu May 12 22:08:46 2016 +0000
Commit: Brian Dolbec <dolsen <AT> gentoo <DOT> org>
CommitDate: Thu May 12 22:08:46 2016 +0000
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=9266e8e8
qa-checks: executable-issues: improve logic & output
Use more robust shell styles for parsing strings/output, and change
the QA log output to include the actual failing rpaths. This helps
in debugging/tracking down problems.
X-Gentoo-Bug: 582524
X-Gentoo-Bug-URL: https://bugs.gentoo.org/582524
bin/install-qa-check.d/10executable-issues | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/bin/install-qa-check.d/10executable-issues b/bin/install-qa-check.d/10executable-issues
index 066f150..b52cc93 100644
--- a/bin/install-qa-check.d/10executable-issues
+++ b/bin/install-qa-check.d/10executable-issues
@@ -22,26 +22,26 @@ elf_check() {
# that directory won't exist on the target system.
# 3) Null paths are banned because the loader will search $PWD when
# it finds null paths.
- local forbidden_dirs="${PORTAGE_BUILDDIR}"
- if [[ -n "${ROOT}" && "${ROOT}" != "/" ]]; then
- forbidden_dirs+=" ${ROOT}"
+ local forbidden_dirs=( "${PORTAGE_BUILDDIR}" )
+ if [[ "${ROOT:-/}" != "/" ]]; then
+ forbidden_dirs+=( "${ROOT}" )
fi
local dir l rpath_files=$(scanelf -F '%F:%r' -qBR "${ED}")
f=""
- for dir in ${forbidden_dirs}; do
- for l in $(echo "${rpath_files}" | grep -E ":${dir}|::|: "); do
- f+=" ${l%%:*}\n"
+ for dir in "${forbidden_dirs[@]}"; do
+ while read l; do
+ f+=" ${l/:/\n RPATH: }\n"
if ! has stricter ${FEATURES}; then
__vecho "Auto fixing rpaths for ${l%%:*}"
TMPDIR="${dir}" scanelf -BXr "${l%%:*}" -o /dev/null
fi
- done
+ done < <(echo "${rpath_files}" | grep -F -e ":${dir}" -e "::" -e ": ")
done
# Reject set*id binaries with $ORIGIN in RPATH #260331
x=$(
- find "${ED}" -type f \( -perm -u+s -o -perm -g+s \) -print0 | \
- xargs -0 scanelf -qyRF '%r %p' | grep '$ORIGIN'
+ find "${ED}" -type f '(' -perm -u+s -o -perm -g+s ')' \
+ -exec scanelf -qyRF '%r %p' {} + | grep '$ORIGIN'
)
# Print QA notice.
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] proj/portage:repoman commit in: bin/install-qa-check.d/
@ 2016-05-14 18:33 Brian Dolbec
0 siblings, 0 replies; 3+ messages in thread
From: Brian Dolbec @ 2016-05-14 18:33 UTC (permalink / raw
To: gentoo-commits
commit: 04dd7923eedec4103c4ff52f382b5af68b4364b4
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Thu May 12 21:35:13 2016 +0000
Commit: Brian Dolbec <dolsen <AT> gentoo <DOT> org>
CommitDate: Thu May 12 21:35:13 2016 +0000
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=04dd7923
qa-checks: change "herd" to "maintainer"
bin/install-qa-check.d/10executable-issues | 2 +-
bin/install-qa-check.d/90gcc-warnings | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/bin/install-qa-check.d/10executable-issues b/bin/install-qa-check.d/10executable-issues
index 10d3c71..066f150 100644
--- a/bin/install-qa-check.d/10executable-issues
+++ b/bin/install-qa-check.d/10executable-issues
@@ -49,7 +49,7 @@ elf_check() {
__vecho -ne '\n'
eqawarn "QA Notice: The following files contain insecure RUNPATHs"
eqawarn " Please file a bug about this at http://bugs.gentoo.org/"
- eqawarn " with the maintaining herd of the package."
+ eqawarn " with the maintainer of the package."
eqawarn "${f}${f:+${x:+\n}}${x}"
__vecho -ne '\n'
if [[ -n ${x} ]] || has stricter ${FEATURES} ; then
diff --git a/bin/install-qa-check.d/90gcc-warnings b/bin/install-qa-check.d/90gcc-warnings
index 43f9498..a160436 100644
--- a/bin/install-qa-check.d/90gcc-warnings
+++ b/bin/install-qa-check.d/90gcc-warnings
@@ -99,7 +99,7 @@ gcc_warn_check() {
eerror "${f}"
eerror
eerror " Please file a bug about this at http://bugs.gentoo.org/"
- eerror " with the maintaining herd of the package."
+ eerror " with the maintainer of the package."
eerror
else
__vecho -ne '\n'
@@ -137,7 +137,7 @@ gcc_warn_check() {
eerror "${f}"
eerror
eerror " Please file a bug about this at http://bugs.gentoo.org/"
- eerror " with the maintaining herd of the package."
+ eerror " with the maintainer of the package."
eerror
else
__vecho -ne '\n'
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] proj/portage:repoman commit in: bin/install-qa-check.d/
@ 2016-05-14 18:33 Brian Dolbec
0 siblings, 0 replies; 3+ messages in thread
From: Brian Dolbec @ 2016-05-14 18:33 UTC (permalink / raw
To: gentoo-commits
commit: 91e1dd94c1615bf97d5bc42dac4d64876919e768
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Wed May 11 17:53:40 2016 +0000
Commit: Brian Dolbec <dolsen <AT> gentoo <DOT> org>
CommitDate: Wed May 11 17:53:40 2016 +0000
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=91e1dd94
qa: gcc-warnings: force text mode w/grep
Newer versions of grep will flag non-ASCII output (e.g. UTF-8 encoded)
as binary when run in the C locale. Force it into text mode to avoid
that otherwise the QA warning is simply:
* QA Notice: Package triggers severe warnings which indicate that it
* may exhibit random runtime failures.
* Binary file /var/log/portage/net-fs:netatalk-3.1.8:20160511-173717.log matches
bin/install-qa-check.d/90gcc-warnings | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/bin/install-qa-check.d/90gcc-warnings b/bin/install-qa-check.d/90gcc-warnings
index bd82cab..43f9498 100644
--- a/bin/install-qa-check.d/90gcc-warnings
+++ b/bin/install-qa-check.d/90gcc-warnings
@@ -81,8 +81,10 @@ gcc_warn_check() {
local grep_cmd=grep
[[ $PORTAGE_LOG_FILE = *.gz ]] && grep_cmd=zgrep
- # force C locale to work around slow unicode locales #160234
- f=$(LC_CTYPE=C LC_COLLATE=C "${grep_cmd}" -E "${joined_msgs}" "${PORTAGE_LOG_FILE}" | uniq)
+ # Force C locale to work around slow multibyte locales. #160234
+ # Force text mode as newer grep will treat non-ASCII (e.g. UTF-8) as
+ # binary when we run in the C locale.
+ f=$(LC_CTYPE=C LC_COLLATE=C "${grep_cmd}" -E -a "${joined_msgs}" "${PORTAGE_LOG_FILE}" | uniq)
if [[ -n ${f} ]] ; then
abort="yes"
# for now, don't make this fatal (see bug #337031)
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-05-14 18:34 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-05-14 18:33 [gentoo-commits] proj/portage:repoman commit in: bin/install-qa-check.d/ Brian Dolbec
-- strict thread matches above, loose matches on Subject: below --
2016-05-14 18:33 Brian Dolbec
2016-05-14 18:33 Brian Dolbec
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox