diff options
-rwxr-xr-x | bin/misc-functions.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/bin/misc-functions.sh b/bin/misc-functions.sh index 9b280588c..db023e48a 100755 --- a/bin/misc-functions.sh +++ b/bin/misc-functions.sh @@ -558,6 +558,23 @@ install_qa_check() { done done + local checkbashisms=$(type -P checkbashisms) + if [[ -n ${checkbashisms} ]] ; then + for d in /etc/init.d ; do + [[ -d ${ED}${d} ]] || continue + for i in "${ED}${d}"/* ; do + [[ -e ${i} ]] || continue + [[ -L ${i} ]] && continue + f=$("${checkbashisms}" -f "${i}" 2>&1) + [[ $? != 0 && -n ${f} ]] || continue + eqawarn "QA Notice: shell script appears to use non-POSIX feature(s):" + while read -r ; + do eqawarn " ${REPLY}" + done <<< "${f//${ED}}" + done + done + fi + # Look for leaking LDFLAGS into pkg-config files f=$(egrep -sH '^Libs.*-Wl,(-O[012]|--hash-style)' "${ED}"/usr/*/pkgconfig/*.pc) if [[ -n ${f} ]] ; then |