[pitivi] build: look at the proper pixmap directory when distchecking



commit baa2b255d93afea6e61b379eb815c29f6a293358
Author: Thibault Saunier <thibault saunier collabora co uk>
Date:   Sun May 22 16:04:05 2011 -0400

    build: look at the proper pixmap directory when distchecking
    
    Make distcheck working even if we haven't installed the project

 pitivi/configure.py.in |    3 +++
 tests/Makefile.am      |    3 ++-
 2 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/pitivi/configure.py.in b/pitivi/configure.py.in
index a0cc420..52a22b1 100644
--- a/pitivi/configure.py.in
+++ b/pitivi/configure.py.in
@@ -52,6 +52,9 @@ def get_pixmap_dir():
     _dir = os.path.dirname(os.path.abspath(__file__))
     if _in_devel():
         root = _dir
+    elif os.getenv("PITIVI_TOP_LEVEL_DIR"):
+        top_level = os.getenv("PITIVI_TOP_LEVEL_DIR")
+        root = os.path.abspath(os.path.join(top_level, "pitivi"))
     else:
         root = PKGDATADIR
     return os.path.join(root, 'pixmaps')
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 3da77a0..1e07aee 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -21,7 +21,8 @@ clean-local:
 	rm -f testProject.ptv testproject.xptv testproject2.xptv
 
 check-local:
-	@PYTHONPATH=$(top_srcdir):$(PYTHONPATH) $(PYTHON) $(srcdir)/runtests.py
+	@PYTHONPATH=$(top_srcdir):$(PYTHONPATH) PITIVI_TOP_LEVEL_DIR='$(top_srcdir)' $(PYTHON)\
+		$(srcdir)/runtests.py
 
 %.check: %
 	@PYTHONPATH=$(top_srcdir):$(PYTHONPATH) $(PYTHON) $(srcdir)/runtests.py $*



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