xbps-src: revbump if shlibs differ in the rshlibs file.

This commit is contained in:
Juan RP 2011-11-12 09:52:34 +01:00
parent 7fa0e64d4d
commit 48209c4058

View file

@ -130,19 +130,6 @@ verify_rundeps()
tmplf=$XBPS_SRCPKGDIR/$pkgname/template tmplf=$XBPS_SRCPKGDIR/$pkgname/template
fi fi
sed -i "/^Add_dependency run ${_rdep}.*$/d" $tmplf sed -i "/^Add_dependency run ${_rdep}.*$/d" $tmplf
_rev=$(egrep '^revision=.*' $tmplf)
if [ -n "${_rev}" ]; then
newrev=$((${_rev#revision=} + 1))
if [ -z "$revbumped" ]; then
sed -i "s/^revision=.*$/revision=${newrev}/" $tmplf
revbumped=1
fi
else
if [ -z "$revbumped" ]; then
sed -i "/^short_desc=.*$/irevision=1" $tmplf
revbumped=1
fi
fi
if find_rundep ${_rdep}; then if find_rundep ${_rdep}; then
Add_dependency run ${_rdep} Add_dependency run ${_rdep}
@ -199,6 +186,19 @@ verify_rundeps()
fi fi
if [ -n "$broken" ]; then if [ -n "$broken" ]; then
msg_error "$pkgver: shlibs changed: a revbump is necessary!\n" msg_warn "$pkgver: shlibs changed... package has been revbumped!\n"
_rev=$(egrep '^revision=.*' $tmplf)
if [ -n "${_rev}" ]; then
newrev=$((${_rev#revision=} + 1))
if [ -z "$revbumped" ]; then
sed -i "s/^revision=.*$/revision=${newrev}/" $tmplf
revbumped=1
fi
else
if [ -z "$revbumped" ]; then
sed -i "/^short_desc=.*$/irevision=1" $tmplf
revbumped=1
fi
fi
fi fi
} }