Index: bin/misc-functions.sh =================================================================== --- bin/misc-functions.sh (revision 11201) +++ bin/misc-functions.sh (working copy) @@ -158,6 +158,30 @@ sleep 1 fi + # Check for files built without respecting LDFLAGS + if [[ "${LDFLAGS}" == *--hash-style=gnu* ]] && [[ "${PN}" != *-bin ]] ; then + f=$(scanelf -qyRF '%k %p' -k .hash "${D}" | sed -e "s:\.hash ::") + if [[ -n ${f} ]] ; then + echo "${f}" > "${T}"/scanelf-ignored-LDFLAGS.log + for file in ${QA_DT_HASH} ; do + sed -i -e "s:^${file}$::" "${T}"/scanelf-ignored-LDFLAGS.log + done + sed -i -e "/^$/d" -e "s:^:/:" "${T}"/scanelf-ignored-LDFLAGS.log + f=$(<"${T}"/scanelf-ignored-LDFLAGS.log) + if [[ -n ${f} ]] ; then + vecho -ne '\a\n' + eqawarn "\e[31mQA Notice: Files built without respecting LDFLAGS have been detected\e[0m" + eqawarn " Please include this file in your report:" + eqawarn " ${T}/scanelf-ignored-LDFLAGS.log" + for file in ${f} ; do + eqawarn ${file} + done + vecho -ne '\a\n' + sleep 1 + fi + fi + fi + # Save NEEDED information after removing self-contained providers scanelf -qyRF '%a;%p;%S;%r;%n' "${D}" | { while IFS= read l; do arch=${l%%;*}; l=${l#*;} Index: man/ebuild.5 =================================================================== --- man/ebuild.5 (revision 11201) +++ man/ebuild.5 (working copy) @@ -422,6 +422,11 @@ This should contain a list of file paths, relative to the image directory, of files that contain writable and executable segments. These are rare. The paths may contain regular expressions. +.TP +\fBQA_DT_HASH\fR +This should contain a list of file paths, relative to the image directory, of +files that contain .hash sections. The paths may contain regular expressions +with escape\-quoted special characters. .SH "PORTAGE DECLARATIONS" .TP .B inherit