[jhbuild] do not check prefix is writable when reading the configuration
- From: Frederic Peters <fpeters src gnome org>
- To: svn-commits-list gnome org
- Subject: [jhbuild] do not check prefix is writable when reading the configuration
- Date: Wed, 6 May 2009 15:01:57 -0400 (EDT)
commit 3533890e19905f0a862dafc54f26db6027d27c9e
Author: Frederic Peters <fpeters 0d be>
Date: Wed May 6 20:54:17 2009 +0200
do not check prefix is writable when reading the configuration
It is not necessary to check the JHBuild prefix is writable in every
situation, as running jhbuild run gnome-session as another user is
a very legitimate use. So this defers the ckeck for a writable prefix
later on. (GNOME #581634)
---
jhbuild/config.py | 2 --
jhbuild/frontends/buildscript.py | 4 ++++
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/jhbuild/config.py b/jhbuild/config.py
index b699072..e822cdb 100644
--- a/jhbuild/config.py
+++ b/jhbuild/config.py
@@ -202,8 +202,6 @@ class Config:
os.makedirs(self.prefix)
except:
raise FatalError(_('install prefix (%s) can not be created') % self.prefix)
- if not os.access(self.prefix, os.R_OK|os.W_OK|os.X_OK):
- raise FatalError(_('install prefix (%s) must be writable') % self.prefix)
os.environ['UNMANGLED_LD_LIBRARY_PATH'] = os.environ.get('LD_LIBRARY_PATH', '')
diff --git a/jhbuild/frontends/buildscript.py b/jhbuild/frontends/buildscript.py
index 6c94da0..a4abc1d 100644
--- a/jhbuild/frontends/buildscript.py
+++ b/jhbuild/frontends/buildscript.py
@@ -33,6 +33,10 @@ class BuildScript:
self.config = config
+ # the existence of self.config.prefix is checked in config.py
+ if not os.access(self.config.prefix, os.R_OK|os.W_OK|os.X_OK):
+ raise FatalError(_('install prefix (%s) must be writable') % self.config.prefix)
+
if not os.path.exists(self.config.checkoutroot):
try:
os.makedirs(self.config.checkoutroot)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]