[pybliographer/wip/gtk3: 29/42] build: Add path to PYTHONPATH



commit 5083c02bca4065925cc517933d110e17fc1e912d
Author: Germán Poo-Caamaño <gpoo gnome org>
Date:   Fri Mar 21 00:29:25 2014 -0700

    build: Add path to PYTHONPATH
    
    It only worked if the path por Pyblio was already in the PYTHONPATH

 scripts/pybscript.in |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/scripts/pybscript.in b/scripts/pybscript.in
index f56032b..1f3d4a8 100644
--- a/scripts/pybscript.in
+++ b/scripts/pybscript.in
@@ -10,6 +10,9 @@ if test -x "./pybliographer" ; then
     export PYTHONPATH
 else
     pyblio="@bin_dir@/pybliographer"
+    if [ -d "$prefix" ] && [[ ":$PYTHONPATH:" != *":$prefix:"* ]]; then
+        PYTHONPATH="${PYTHONPATH:+"$PYTHONPATH:"}$prefix"
+    fi
 fi
 
 invocation="$0"


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]