fix deps generation for devel package.conf and prof libHS*_p.a

epel9
Jens Petersen 5 years ago
parent 6dd89e3044
commit 25cfe11f3d

@ -24,20 +24,25 @@ files=$(cat)
for i in $files; do
meta=""
case $i in
*/libHS*_p.a)
meta=prof
# exclude rts.conf
$pkgconfdir/*-*.conf)
name=$(grep "^name: " $i | sed -e "s/name: //")
ids=$($GHC_PKG field $name $field | sed -e "s/rts//" -e "s/bin-package-db-[^ ]\+//")
for d in $ids; do
case $d in
*-*) echo "ghc-devel($d)" ;;
*) ;;
esac
done
;;
*/libHS*.a)
meta=devel
*/libHS*_p.a)
pkgver=$(basename $(dirname $i))
ids=$($GHC_PKG field $pkgver $field | sed -e "s/rts//" -e "s/bin-package-db-[^ ]\+//")
for d in $ids; do
case $d in
*-*) echo "ghc-prof($d)" ;;
esac
done
;;
esac
if [ -n "$meta" ]; then
pkgver=$(basename $(dirname $i))
ids=$($GHC_PKG field $pkgver $field | sed -e "s/rts//" -e "s/bin-package-db-[^ ]\+//")
for d in $ids; do
case $d in
*-*) echo "ghc-${meta}($d)" ;;
esac
done
fi
done

@ -1,3 +1,3 @@
%__ghc_provides %{_rpmconfigdir}/ghc-deps.sh --provides %{buildroot}%{ghclibdir}
%__ghc_requires %{_rpmconfigdir}/ghc-deps.sh --requires %{buildroot}%{ghclibdir}
%__ghc_path ^%{ghclibdir}/.*/libHS.*\.a$
%__ghc_path ^%{ghclibdir}/(.*/libHS.*_p\.a|package.conf.d/.*\.conf)$

Loading…
Cancel
Save