From 2d08e902ef07b4a888fa3daf2d5a658dd04dac4e Mon Sep 17 00:00:00 2001 From: Aurelien Foret Date: Sat, 21 Jan 2006 16:50:01 +0000 Subject: added a FAKEROOT define allowing to use pacman in a fakeroot enivronment (for tests purpose) --- src/pacman/pacman.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/pacman/pacman.c b/src/pacman/pacman.c index 8511621a..ea3babe3 100644 --- a/src/pacman/pacman.c +++ b/src/pacman/pacman.c @@ -101,10 +101,12 @@ int main(int argc, char *argv[]) #ifndef CYGWIN /* see if we're root or not */ myuid = geteuid(); +#ifndef FAKEROOT if(!myuid && getenv("FAKEROOTKEY")) { /* fakeroot doesn't count, we're non-root */ myuid = 99; } +#endif /* check if we have sufficient permission for the requested operation */ if(myuid > 0) { -- cgit v1.2.3-70-g09d2