Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 162589 | Differences between
and this patch

Collapse All | Expand All

(-)gentoolkit-0.2.4.2/src/revdep-rebuild/revdep-rebuild (-4 / +11 lines)
Lines 687-693 Link Here
687
			if [[ $target_file != *.la ]]; then
687
			if [[ $target_file != *.la ]]; then
688
				# Note: double checking seems to be faster than single with complete path
688
				# Note: double checking seems to be faster than single with complete path
689
				# (special add ons are rare).
689
				# (special add ons are rare).
690
				ldd_output=$(ldd "$target_file" 2>> "$ERRORS_FILE" | sort -u)
690
				case $target_file in
691
				*.so|*.so.*)
692
					ldd_output=$(ldd "$target_file" 2>> "$ERRORS_FILE" | sort -u);;
693
				*)
694
					ldd_output=$(ldd -d -r "$target_file" 2>> "$ERRORS_FILE" | sort -u);;
695
				esac
691
				ldd_status=$? # TODO: Check this for problems with sort
696
				ldd_status=$? # TODO: Check this for problems with sort
692
				# HACK: if LD_LIBRARY_MASK is null or undefined grep -vF doesn't work
697
				# HACK: if LD_LIBRARY_MASK is null or undefined grep -vF doesn't work
693
				if grep -vF "${LD_LIBRARY_MASK:=$'\a'}" <<< "$ldd_output" |
698
				if grep -vF "${LD_LIBRARY_MASK:=$'\a'}" <<< "$ldd_output" |
Lines 754-770 Link Here
754
		done
759
		done
755
		if [[ $SEARCH_BROKEN ]]; then
760
		if [[ $SEARCH_BROKEN ]]; then
756
			# Look for missing version
761
			# Look for missing version
757
			while read target_file; do
762
			while read target_file && read message; do
758
				echo "obj $target_file" >> "$BROKEN_FILE"
763
				echo "obj $target_file" >> "$BROKEN_FILE"
759
				echo_v "  broken $target_file (no version information available)"
764
				echo_v "  broken $target_file ($message)"
760
			done < <(
765
			done < <(
761
				# Regexify LD_LIBRARY_MASK. Exclude it from the search.
766
				# Regexify LD_LIBRARY_MASK. Exclude it from the search.
762
				LD_LIBRARY_MASK="${LD_LIBRARY_MASK//$'\n'/|}"
767
				LD_LIBRARY_MASK="${LD_LIBRARY_MASK//$'\n'/|}"
763
				awk -v ldmask="(${LD_LIBRARY_MASK//./\\\.})" '
768
				awk -v ldmask="(${LD_LIBRARY_MASK//./\\\.})" '
764
					/no version information available/ && $0 !~ ldmask {
769
					/no version information available|undefined symbol/ && $0 !~ ldmask {
765
						gsub(/[()]/, "", $NF)
770
						gsub(/[()]/, "", $NF)
766
						if (seen[$NF]++)  next
771
						if (seen[$NF]++)  next
767
						print $NF
772
						print $NF
773
						NF--
774
						print $0
768
					}' "$ERRORS_FILE"
775
					}' "$ERRORS_FILE"
769
			)
776
			)
770
		fi
777
		fi

Return to bug 162589