#!/usr/bin/bash if [ $# -ne 1 ] ; then >&2 echo "Usage: make-perl-exclude-list " exit 1 fi echo "# This is a list of the perl modules provided by the perl and perl-base" echo "# packages. Many of these modules are also provided by standalone packages." echo "# This list allows us to avoid including both on the installer media." echo "#" echo "# This file is automatically generated by the make-perl-exclude-list.sh script." echo "# It may need to be manually edited if the perl or perl-base package does not" echo "# provide a suitable version of a particular module (e.g. if another package" echo "# requires a different version, and that version is available as a standalone" echo "# package)." echo "#" urpmq --use-distrib $1 --provides perl perl-base \ | sed -E -e 's/^perl.*: //' -e 's/\((.*)\)/-\1/' -e 's/::/-/g' -e 's/\[.*\]$//' \ | grep -v '^perl-base' \ | grep '^perl-' \ | sort -u \ | perl -ne "my \$bn = \$_; chomp(\$bn); print \"\$_\" if my @files = grep { \$_ =~ \"$1/media/core/release/\$bn-[0-9].*rpm\" } glob(\"$1/media/core/release/\$bn-*.rpm\")"