aboutsummaryrefslogtreecommitdiffstats
path: root/fontconfig.prov
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mageia.org>2012-07-25 17:01:48 +0000
committerThierry Vignaud <tv@mageia.org>2012-07-25 17:01:48 +0000
commit7f606854dcbbe0f74a1adccbd385239644089574 (patch)
tree1d00530f672a09535c7b2cf3105e87919e157e94 /fontconfig.prov
parent300cc29973b185505692bce49597f857e65b1dfc (diff)
downloadrpm-setup-7f606854dcbbe0f74a1adccbd385239644089574.tar
rpm-setup-7f606854dcbbe0f74a1adccbd385239644089574.tar.gz
rpm-setup-7f606854dcbbe0f74a1adccbd385239644089574.tar.bz2
rpm-setup-7f606854dcbbe0f74a1adccbd385239644089574.tar.xz
rpm-setup-7f606854dcbbe0f74a1adccbd385239644089574.zip
sync with rpm.org:
(wtf are not we using rpm's /usr/lib/rpm/fontconfig.prov instead of copying it here???) "Fix potential getOutputFrom() error on font provide extraction (RhBug:609117) - if fonts are detected in the package being built but fc-query isn't present, the script exited without consuming stdin which can break getOutputFrom()" (panu, 2010-06-30)
Diffstat (limited to 'fontconfig.prov')
-rwxr-xr-xfontconfig.prov8
1 files changed, 5 insertions, 3 deletions
diff --git a/fontconfig.prov b/fontconfig.prov
index 73f345c..bfb6ea0 100755
--- a/fontconfig.prov
+++ b/fontconfig.prov
@@ -1,7 +1,7 @@
#!/bin/bash
#
# Script to install in:
-# /usr/lib/rpm/mageia/find-provides.d
+# /usr/lib/rpm/redhat/find-provides.d
#
# Transform font files into RPM provides
# Requires fontconfig >= 2.6.90
@@ -12,11 +12,13 @@
fcquery=/usr/bin/fc-query
-[ -x $fcquery ] || exit 0
+if [ ! -x $fcquery ]; then
+ cat > /dev/null
+ exit 0
+fi
# filter out anything outside main fontconfig path
grep /usr/share/fonts/ |
while read fn; do
$fcquery --format '%{=pkgkit}' "${fn}" 2> /dev/null
done
-exit 0