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

Collapse All | Expand All

(-)revdep-rebuild (-17 / +28 lines)
Lines 620-647 Link Here
620
}
620
}
621
621
622
get_files() {
622
get_files() {
623
	local remake_files_file=
623
	einfo "Collecting system binaries and libraries"
624
	einfo "Collecting system binaries and libraries"
624
	if [[ -r "$FILES_FILE" && -s "$FILES_FILE" ]]; then
625
	if [[ -r "$FILES_FILE" && -s "$FILES_FILE" ]]; then
625
		einfo "Found existing $FILES_FILE"
626
		einfo "Found existing ${FILES_FILE}: checking its validity"
626
	else
627
		while read; do
627
		# Be safe and remove any extraneous temporary files
628
			if ! [[ -r $REPLY && -s $REPLY ]]; then
628
		# Don't remove 0_env.rr - The first file in the array
629
				ewarn "$REPLY is an invalid listing"
629
		rm -f "${FILES[@]:1}"
630
				ewarn "Replacing $FILES_FILE"
631
				remake_files_file=1
632
				break
633
			fi
634
		done
635
		[[ remake_files_file ]] || return 0
636
	fi
630
637
631
		clean_trap "$FILES_FILE"
638
	# Be safe and remove any extraneous temporary files
639
	# Don't remove 0_env.rr - The first file in the array
640
	rm -f "${FILES[@]:1}"
641
	clean_trap "$FILES_FILE"
632
642
633
		if [[ $SEARCH_DIRS_MASK ]]; then
643
	if [[ $SEARCH_DIRS_MASK ]]; then
634
			findMask=($SEARCH_DIRS_MASK)
644
		findMask=($SEARCH_DIRS_MASK)
635
			findMask="${findMask[@]/#/-o -path }"
645
		findMask="${findMask[@]/#/-o -path }"
636
			findMask="( ${findMask#-o } ) -prune -o"
646
		findMask="( ${findMask#-o } ) -prune -o"
637
		fi
638
		# TODO: Check this -- afaict SEARCH_DIRS isn't an array, so this should just be $SEARCH_DIRS?
639
		find ${SEARCH_DIRS[@]} $findMask -type f \( -perm -u+x -o -perm -g+x -o -perm -o+x -o \
640
			-name '*.so' -o -name '*.so.*' -o -name '*.la' \) -print 2> /dev/null |
641
			sort -u > "$FILES_FILE" ||
642
			die $? "find failed to list binary files (This is a bug.)"
643
		einfo "Generated new $FILES_FILE"
644
	fi
647
	fi
648
649
	# TODO: Check this -- afaict SEARCH_DIRS isn't an array, so this should just be $SEARCH_DIRS?
650
	find ${SEARCH_DIRS[@]} $findMask -type f \( -perm -u+x -o -perm -g+x -o -perm -o+x -o \
651
		-name '*.so' -o -name '*.so.*' -o -name '*.la' \) -print 2> /dev/null |
652
		sort -u > "$FILES_FILE" ||
653
		die $? "find failed to list binary files (This is a bug.)"
654
	einfo "Generated new $FILES_FILE"
655
645
}
656
}
646
get_ldpath() {
657
get_ldpath() {
647
	local COMPLETE_LD_LIBRARY_PATH
658
	local COMPLETE_LD_LIBRARY_PATH

Return to bug 252817