[Piglit] [PATCH] piglit: Don't override user's definition of the PIGLIT_SOURCE_DIR env variable v2

Tom Stellard thomas.stellard at amd.com
Fri May 9 14:29:38 PDT 2014


---
 piglit | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/piglit b/piglit
index af8dfb1..dcb51db 100755
--- a/piglit
+++ b/piglit
@@ -42,7 +42,8 @@ if not path.exists('HACKING'):
     _binpath, _bin = path.split(__file__)
     _libdir = path.abspath(path.join(_binpath, '..', 'lib', _bin))
     sys.path.append(_libdir)
-    os.environ['PIGLIT_SOURCE_DIR'] = _libdir
+    if 'PIGLIT_SOURCE_DIR' not in os.environ:
+        os.environ['PIGLIT_SOURCE_DIR'] = _libdir
 
 import framework.programs.run as run
 import framework.programs.summary as summary
-- 
1.8.1.5



More information about the Piglit mailing list