7b08d5
#!/bin/sh
7b08d5
7b08d5
# Finds requirements provided outside of the current file set
7b08d5
7b08d5
filelist=`sed "s/[]['\"*?{}]/\\\\\&/g"`
7b08d5
7b08d5
provides=`echo $filelist | /usr/lib/rpm/find-provides`
7b08d5
7b08d5
{
7b08d5
for f in $filelist ; do
7b08d5
	echo $f | /usr/lib/rpm/find-requires | while read req ; do
7b08d5
		found=0
7b08d5
		for p in $provides ; do
7b08d5
			if [ "$req" = "$p" ]; then
7b08d5
				found=1
7b08d5
			fi
7b08d5
		done
7b08d5
		if [ "$found" = "0" ]; then
7b08d5
			echo $req
7b08d5
		fi
7b08d5
	done
7b08d5
done
7b08d5
} | sort -u