diff options
Diffstat (limited to 'user/labplot/really-really-disable-liborigin.patch')
-rw-r--r-- | user/labplot/really-really-disable-liborigin.patch | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/user/labplot/really-really-disable-liborigin.patch b/user/labplot/really-really-disable-liborigin.patch new file mode 100644 index 000000000..6deb963c8 --- /dev/null +++ b/user/labplot/really-really-disable-liborigin.patch @@ -0,0 +1,65 @@ +From 5e37796f4db1a2408fdd56562f0d80ef7988ff38 Mon Sep 17 00:00:00 2001 +From: "A. Wilcox" <AWilcox@Wilcox-Tech.com> +Date: Wed, 12 Sep 2018 12:02:44 -0500 +Subject: [PATCH] Tests: disable Origin tests when lib is disabled + +Compiling with liborigin disabled caused a build failure while building +ProjectImportTest, because it still unconditionally #included +OriginProjectParser and called into Origin code. +--- + tests/import_export/project/ProjectImportTest.cpp | 6 +++++- + tests/import_export/project/ProjectImportTest.h | 2 ++ + 2 files changed, 7 insertions(+), 1 deletion(-) + +diff --git a/tests/import_export/project/ProjectImportTest.cpp b/tests/import_export/project/ProjectImportTest.cpp +index 11ac7845..91163b62 100755 +--- a/tests/import_export/project/ProjectImportTest.cpp ++++ b/tests/import_export/project/ProjectImportTest.cpp +@@ -26,7 +26,9 @@ + ***************************************************************************/ + + #include "ProjectImportTest.h" +-#include "backend/datasources/projects/OriginProjectParser.h" ++#ifdef HAVE_LIBORIGIN ++# include "backend/datasources/projects/OriginProjectParser.h" ++#endif + #include "backend/core/Project.h" + #include "backend/core/Workbook.h" + #include "backend/matrix/Matrix.h" +@@ -49,6 +51,7 @@ void ProjectImportTest::initTestCase() { + //############################################################################## + + ++#ifdef HAVE_LIBORIGIN + //############################################################################## + //###################### import of Origin projects ############################ + //############################################################################## +@@ -375,5 +378,6 @@ void ProjectImportTest::testOriginTextNumericColumns() { + QCOMPARE(!std::isnan(column->valueAt(3)), false); + QCOMPARE(!std::isnan(column->valueAt(4)), false); + } ++#endif + + QTEST_MAIN(ProjectImportTest) +diff --git a/tests/import_export/project/ProjectImportTest.h b/tests/import_export/project/ProjectImportTest.h +index 2e27bcd0..22b414a3 100755 +--- a/tests/import_export/project/ProjectImportTest.h ++++ b/tests/import_export/project/ProjectImportTest.h +@@ -37,12 +37,14 @@ private slots: + + //import of LabPlot projects + ++#ifdef HAVE_LIBORIGIN + //import of Origin projects + void testOrigin01(); + void testOrigin02(); + void testOrigin03(); + void testOrigin04(); + void testOriginTextNumericColumns(); ++#endif + + private: + QString m_dataDir; +-- +2.18.0 + |