aboutsummaryrefslogtreecommitdiffstats
path: root/find-provides.in
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mageia.org>2012-07-27 17:38:31 +0000
committerThierry Vignaud <tv@mageia.org>2012-07-27 17:38:31 +0000
commit061c1441b2964954e329252c620ea34bafb3cb3c (patch)
treec05b5585f67510d96828fd5425056f50394830e4 /find-provides.in
parent602cc9dbeb45b04f97b73f1a763776cb0af1232d (diff)
downloadrpm-setup-061c1441b2964954e329252c620ea34bafb3cb3c.tar
rpm-setup-061c1441b2964954e329252c620ea34bafb3cb3c.tar.gz
rpm-setup-061c1441b2964954e329252c620ea34bafb3cb3c.tar.bz2
rpm-setup-061c1441b2964954e329252c620ea34bafb3cb3c.tar.xz
rpm-setup-061c1441b2964954e329252c620ea34bafb3cb3c.zip
generate a perlapi-<version> provide when libperl.so is found
(inspirated from mdv (pok))
Diffstat (limited to 'find-provides.in')
-rwxr-xr-xfind-provides.in12
1 files changed, 12 insertions, 0 deletions
diff --git a/find-provides.in b/find-provides.in
index 8636a7b..c14ef6d 100755
--- a/find-provides.in
+++ b/find-provides.in
@@ -47,6 +47,18 @@ for f in $solist; do
done | sort -u
#
+# --- If libperl.so is found in buildroot, we provide perlapi-<version>
+if [ -n "`echo $filelist | grep -e '/CORE/libperl\.so'`" ]; then
+ for i in $filelist; do
+ if [ -n "`echo $i | grep -e '/CORE/libperl\.so\$'`" ]; then
+ perlpath=$i
+ version=`perl -I"$perlpath" -MConfig -e 'print $Config{version}'`
+ [ $? == 0 ] && echo "perlapi-$version"
+ fi
+ done
+fi
+
+#
# --- Perl modules.
[ -x @RPMVENDORDIR@/perl.prov ] &&
echo "$filelist" | tr '[:blank:]' \\n | @RPMVENDORDIR@/perl.prov | grep 'perl([[:upper:]]' | sort -u \