summaryrefslogtreecommitdiffstats
path: root/urpmi
diff options
context:
space:
mode:
Diffstat (limited to 'urpmi')
-rwxr-xr-xurpmi7
1 files changed, 2 insertions, 5 deletions
diff --git a/urpmi b/urpmi
index 4fd44977..3432f034 100755
--- a/urpmi
+++ b/urpmi
@@ -239,9 +239,6 @@ while (defined($_ = shift @argv)) {
$src = 0; #- reset switch for next package.
}
-# We assume --root / is stupid (P. Terjan idea)
-$root =~ s!^/*$!!;
-
#- use install_src to promote all names as src package.
if ($install_src) {
@files and $urpm->{fatal}(1, N("What can be done with binary rpm files when using --install-src"));
@@ -269,8 +266,8 @@ if ($env) {
$urpm->{statedir} = $env;
} else {
if ($uid > 0) {
- #- only src files are installable using urpmi.
- !($install_src || $root) and @names || @files and $urpm->{fatal}(1, N("Only superuser is allowed to install packages"));
+ #- need to be root if binary rpms are to be installed
+ @names || @files and $urpm->{fatal}(1, N("Only superuser is allowed to install packages"));
} else {
#- allow log if not defined.
$log ||= "/var/log/urpmi.log";