Package: calligra / 1:2.8.5+dfsg-1

calligra_imports_search_path Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
Index: calligra/krita/gemini/MainWindow.cpp
===================================================================
--- calligra.orig/krita/gemini/MainWindow.cpp	2014-05-15 17:22:40.814772549 +0200
+++ calligra/krita/gemini/MainWindow.cpp	2014-05-15 17:22:40.810772707 +0200
@@ -158,6 +158,11 @@
         sketchView->engine()->addImportPath(appdir.canonicalPath() + "/lib64/calligra/imports");
         QString mainqml = appdir.canonicalPath() + "/share/apps/kritagemini/kritagemini.qml";
 #else
+
+#ifdef LIBRARY_ARCHITECTURE
+        sketchView->engine()->addImportPath(KGlobal::dirs()->findDirs("lib", LIBRARY_ARCHITECTURE "/calligra/imports").value(0));
+#endif
+
         sketchView->engine()->addImportPath(KGlobal::dirs()->findDirs("lib", "calligra/imports").value(0));
         QString mainqml = KGlobal::dirs()->findResource("data", "kritagemini/kritagemini.qml");
 #endif
Index: calligra/krita/sketch/CMakeLists.txt
===================================================================
--- calligra.orig/krita/sketch/CMakeLists.txt	2014-05-15 17:22:40.814772549 +0200
+++ calligra/krita/sketch/CMakeLists.txt	2014-05-15 17:22:40.810772707 +0200
@@ -131,6 +131,9 @@
 
 kde4_add_executable(kritasketch ${kritasketch_SRCS})
 
+set_target_properties(kritasketch PROPERTIES COMPILE_DEFINITIONS
+    LIBRARY_ARCHITECTURE="${CMAKE_LIBRARY_ARCHITECTURE}")
+
 target_link_libraries(kritasketch
     ${QT_QTDECLARATIVE_LIBRARY}
     ${QT_QTGUI_LIBRARIES}
Index: calligra/krita/sketch/MainWindow.cpp
===================================================================
--- calligra.orig/krita/sketch/MainWindow.cpp	2014-05-15 17:22:40.814772549 +0200
+++ calligra/krita/sketch/MainWindow.cpp	2014-05-15 17:22:40.810772707 +0200
@@ -114,6 +114,11 @@
     view->engine()->addImportPath(appdir.canonicalPath() + "/lib64/calligra/imports");
     QString mainqml = appdir.canonicalPath() + "/share/apps/kritasketch/kritasketch.qml";
 #else
+
+#ifdef LIBRARY_ARCHITECTURE
+    view->engine()->addImportPath(KGlobal::dirs()->findDirs("lib", LIBRARY_ARCHITECTURE "/calligra/imports").value(0));
+#endif
+
     view->engine()->addImportPath(KGlobal::dirs()->findDirs("lib", "calligra/imports").value(0));
     QString mainqml = KGlobal::dirs()->findResource("appdata", "kritasketch.qml");
 #endif
Index: calligra/krita/gemini/CMakeLists.txt
===================================================================
--- calligra.orig/krita/gemini/CMakeLists.txt	2014-05-15 17:22:40.814772549 +0200
+++ calligra/krita/gemini/CMakeLists.txt	2014-05-15 17:22:40.810772707 +0200
@@ -31,6 +31,9 @@
 
 kde4_add_executable(kritagemini ${kritagemini_SRCS})
 
+set_target_properties(kritagemini PROPERTIES COMPILE_DEFINITIONS
+    LIBRARY_ARCHITECTURE="${CMAKE_LIBRARY_ARCHITECTURE}")
+
 target_link_libraries(kritagemini
     ${QT_QTDECLARATIVE_LIBRARY}
     ${QT_QTGUI_LIBRARIES}