Commit a1459142 authored by Vitaly Lipatov's avatar Vitaly Lipatov

drop __epm_check_if_package_from_repo() in favour epm status --original

parent 93fb9999
......@@ -102,7 +102,7 @@ epm_epm_install()
{
if [ "$BASEDISTRNAME" = "alt" ] && [ "$DISTRVERSION" != "Sisyphus" ] && [ "$EPMMODE" = "package" ] ; then
if __epm_check_if_package_from_repo eepm ; then
if epm status --original eepm ; then
warning "Using external (Korinf) repo is forbidden for stable ALT branch $DISTRVERSION."
info "Check https://bugzilla.altlinux.org/44314 for reasons."
info "You can install eepm package from Korinf manually, check instruction at https://eepm.ru"
......
......@@ -765,33 +765,6 @@ __epm_remove_tmp_files()
}
__epm_check_if_package_from_repo()
{
local pkg="$1"
# only ALT
[ "$BASEDISTRNAME" = "alt" ] || return 0
local vendor
# TODO: check only for rpm
#vendor="$(epm print field Vendor for "$pkg" 2>/dev/null))"
#[ "$vendor" = "ALT Linux Team" ] || return
local distribution
distribution="$(epm print field Distribution for "$pkg" 2>/dev/null )"
echo "$distribution" | grep -q "^ALT" || return
local sig
sig="$(epm print field sigpgp for "$pkg" 2>/dev/null )"
[ "$sig" = "(none)" ] && return 1
# FIXME: how to check if the package is from ALT repo (verified)?
local release="$(epm print release from package "$pkg" 2>/dev/null )"
echo "$release" | grep -q "^alt" || return
return 0
}
has_space()
{
estrlist -- has_space "$@"
......
......@@ -36,9 +36,23 @@ epm_status_original()
case $DISTRNAME in
ALTLinux|ALTServer)
epm_status_validate $pkg || return
#[ "$(epm print field Vendor for package $pkg)" = "ALT Linux Team" ] && return
epm_status_repacked $pkg && return 1
__epm_check_if_package_from_repo $pkg && return
# not for all packages
#[ "$(epm print field Vendor for package $pkg)" = "ALT Linux Team" ] || return
local distribution
distribution="$(epm print field Distribution for "$pkg" 2>/dev/null )"
echo "$distribution" | grep -q "^ALT" || return
local sig
sig="$(epm print field sigpgp for "$pkg" 2>/dev/null )"
[ "$sig" = "(none)" ] && return 1
# FIXME: how to check if the package is from ALT repo (verified)?
local release="$(epm print release from package "$pkg" 2>/dev/null )"
echo "$release" | grep -q "^alt" || return
return 0
;;
*)
fatal "Unsupported $DISTRNAME"
......
......@@ -32,7 +32,7 @@ get_latest_version()
__check_for_epm_version()
{
# skip update checking for eepm from repo (ALT bug #44314)
[ "$BASEDISTRNAME" = "alt" ] && [ "$DISTRVERSION" != "Sisyphus" ] && __epm_check_if_package_from_repo eepm && return
[ "$BASEDISTRNAME" = "alt" ] && [ "$DISTRVERSION" != "Sisyphus" ] && epm status --original eepm && return
local latest="$(get_latest_version eepm)"
#[ -z "$latest" ] && return
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment