summaryrefslogtreecommitdiff
path: root/user
diff options
context:
space:
mode:
authorA. Wilcox <AWilcox@Wilcox-Tech.com>2018-09-12 17:27:45 +0000
committerA. Wilcox <AWilcox@Wilcox-Tech.com>2018-09-12 17:27:45 +0000
commitd2a5aafc7f3d743e85362e020ea4fabe5fe31c64 (patch)
tree5bd472d5944809f69414eac74b2a53df7784a55f /user
parent2831d2d8d69525161b8150a084f5eb66dc9e964f (diff)
downloadpackages-d2a5aafc7f3d743e85362e020ea4fabe5fe31c64.tar.gz
packages-d2a5aafc7f3d743e85362e020ea4fabe5fe31c64.tar.bz2
packages-d2a5aafc7f3d743e85362e020ea4fabe5fe31c64.tar.xz
packages-d2a5aafc7f3d743e85362e020ea4fabe5fe31c64.zip
user/labplot: Bump to 2.5.0
Diffstat (limited to 'user')
-rw-r--r--user/labplot/APKBUILD23
-rw-r--r--user/labplot/disable-liborigin.patch169
-rw-r--r--user/labplot/really-disable-liborigin.patch32
-rw-r--r--user/labplot/really-really-disable-liborigin.patch65
4 files changed, 282 insertions, 7 deletions
diff --git a/user/labplot/APKBUILD b/user/labplot/APKBUILD
index b9c893184..53c91a025 100644
--- a/user/labplot/APKBUILD
+++ b/user/labplot/APKBUILD
@@ -1,7 +1,7 @@
# Contributor: A. Wilcox <awilfox@adelielinux.org>
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=labplot
-pkgver=2.4.0
+pkgver=2.5.0
pkgrel=0
pkgdesc="Interactive tool for graphing and analysis of scientific data"
url="https://www.kde.org/applications/education/labplot/"
@@ -11,10 +11,14 @@ depends="shared-mime-info"
makedepends="cmake extra-cmake-modules qt5-qtbase-dev qt5-qtsvg-dev kconfig-dev
karchive-dev kcompletion-dev kconfigwidgets-dev kcoreaddons-dev kio-dev
kdoctools-dev ki18n-dev kiconthemes-dev kdelibs4support-dev kxmlgui-dev
- knewstuff-dev ktextwidgets-dev kwidgetsaddons-dev gsl-dev fftw-dev"
+ knewstuff-dev ktextwidgets-dev kwidgetsaddons-dev gsl-dev fftw-dev
+ qt5-qtserialport-dev syntax-highlighting-dev bison libexecinfo-dev"
subpackages="$pkgname-doc $pkgname-lang"
-source="https://download.kde.org/stable/labplot/2.4.0/labplot-$pkgver-kf5.tar.xz"
-builddir="$srcdir/labplot-$pkgver-kf5"
+source="https://download.kde.org/stable/labplot/$pkgver/labplot-$pkgver.tar.xz
+ disable-liborigin.patch
+ really-disable-liborigin.patch
+ really-really-disable-liborigin.patch
+ "
build() {
cd "$builddir"
@@ -25,16 +29,18 @@ build() {
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DBUILD_SHARED_LIBS=True \
- -DCMAKE_BUILD_TYPE=RelWithDebugInfo \
+ -DCMAKE_BUILD_TYPE=Debug \
-DCMAKE_CXX_FLAGS="$CXXFLAGS" \
-DCMAKE_C_FLAGS="$CFLAGS -D_GNU_SOURCE" \
+ -DENABLE_LIBORIGIN=False \
${CMAKE_CROSSOPTS}
make
}
check() {
cd "$builddir"
- CTEST_OUTPUT_ON_FAILURE=TRUE ctest
+ # gives incorrect results
+ CTEST_OUTPUT_ON_FAILURE=TRUE ctest -E fittest
}
package() {
@@ -42,4 +48,7 @@ package() {
make DESTDIR="$pkgdir" install
}
-sha512sums="5d29dd7d63d484359e73c8d82d8dbc25a069e1f33829cf75c2a2009ebae2027353ecf578b51806b5f35ae17ec472f5cbfdb4caed2637dc1ecc9229d33033d21b labplot-2.4.0-kf5.tar.xz"
+sha512sums="a4b285917e30b0ac00cb8c8ad6827ba3884d95fccc0511a0a317bb2d637e48e6579929c45cfb8bba737bb5a01472a2baa9d812a688730ac4fa40b23cc6625eba labplot-2.5.0.tar.xz
+c309bc9d8d73377298824a5b5c741a4caf796f7136a562827c8f9969c860cef0f5f510a85527b3ef89cbd35d08d986b5d95f5d44e1a30f8a8eed083f3ebedcc7 disable-liborigin.patch
+d2dd6f90a4382f88b28a8a2cb5e07c618ea8ba823e040638f08b95a4df97f4db76c025f897e6b618eb9546cf39a401904329697422db6af1c14cd2e8f6961362 really-disable-liborigin.patch
+cba3c70d661fa2a887c414595757b9961771500402e58e6414e403cef2dd4fe183e253ce1e5accb49c6f930519ac4ff02ee8f63dfb5eb53289c6d0d3fab6703c really-really-disable-liborigin.patch"
diff --git a/user/labplot/disable-liborigin.patch b/user/labplot/disable-liborigin.patch
new file mode 100644
index 000000000..9fd4e4ba7
--- /dev/null
+++ b/user/labplot/disable-liborigin.patch
@@ -0,0 +1,169 @@
+From d67faf643b2e69c017c21e9d9aaa1fe2d3de6b0e Mon Sep 17 00:00:00 2001
+From: Alexander Semke <alexander.semke@web.de>
+Date: Wed, 12 Sep 2018 08:46:38 +0200
+Subject: Fixed the build with -DENABLE_LIBORIGIN=OFF.
+
+---
+ INSTALL | 1 +
+ src/CMakeLists.txt | 5 ++++-
+ src/kdefrontend/MainWin.cpp | 18 +++++++++++++++++-
+ src/kdefrontend/datasources/ImportProjectDialog.cpp | 8 ++++++++
+ 4 files changed, 30 insertions(+), 2 deletions(-)
+
+diff --git a/INSTALL b/INSTALL
+index cc2bab9..05dd97b 100644
+--- a/INSTALL
++++ b/INSTALL
+@@ -41,5 +41,7 @@ To compile LabPlot without optional dependencies even if they are present on the
+ -DENABLE_LIBCERF=OFF
+ -DENABLE_CANTOR=OFF
++-DENABLE_MQTT=OFF
++-DENABLE_LIBORIGIN=OFF
+
+ Note, by switching off these libraries the feature set of LabPlot will be reduced.
+
+diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
+index ba5763d..892c3c3 100644
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -223,7 +223,6 @@ set(BACKEND_SOURCES
+ ${BACKEND_DIR}/datasources/filters/ROOTFilter.cpp
+ ${BACKEND_DIR}/datasources/projects/ProjectParser.cpp
+ ${BACKEND_DIR}/datasources/projects/LabPlotProjectParser.cpp
+- ${BACKEND_DIR}/datasources/projects/OriginProjectParser.cpp
+ ${BACKEND_DIR}/gsl/ExpressionParser.cpp
+ ${BACKEND_DIR}/matrix/Matrix.cpp
+ ${BACKEND_DIR}/matrix/matrixcommands.cpp
+@@ -271,6 +270,10 @@ set(BACKEND_SOURCES
+ ${BACKEND_DIR}/datapicker/DatapickerCurve.cpp
+ )
+
++IF (ENABLE_LIBORIGIN)
++ lsit(APPEND BACKEND_SOURCES ${BACKEND_DIR}/datasources/projects/OriginProjectParser.cpp)
++ENDIF ()
++
+ set(NSL_SOURCES
+ ${BACKEND_DIR}/nsl/nsl_conv.c
+ ${BACKEND_DIR}/nsl/nsl_dft.c
+diff --git a/src/kdefrontend/MainWin.cpp b/src/kdefrontend/MainWin.cpp
+index 6f90d38..f7d6f8b 100644
+--- a/src/kdefrontend/MainWin.cpp
++++ b/src/kdefrontend/MainWin.cpp
+@@ -37,7 +37,9 @@
+ #include "backend/matrix/Matrix.h"
+ #include "backend/worksheet/Worksheet.h"
+ #include "backend/datasources/LiveDataSource.h"
++#ifdef HAVE_LIBORIGIN
+ #include "backend/datasources/projects/OriginProjectParser.h"
++#endif
+ #ifdef HAVE_CANTOR_LIBS
+ #include "backend/cantorWorksheet/CantorWorksheet.h"
+ #endif
+@@ -295,7 +297,11 @@ void MainWin::initGUI(const QString& fileName) {
+ connect(&m_autoSaveTimer, SIGNAL(timeout()), this, SLOT(autoSaveProject()));
+
+ if (!fileName.isEmpty()) {
++#ifdef HAVE_LIBORIGIN
+ if (Project::isLabPlotProject(fileName) || OriginProjectParser::isOriginProject(fileName)) {
++#else
++ if (Project::isLabPlotProject(fileName)) {
++#endif
+ QTimer::singleShot(0, this, [=] () { openProject(fileName); });
+ } else {
+ newProject();
+@@ -939,7 +945,11 @@ void MainWin::openProject() {
+ KConfigGroup conf(KSharedConfig::openConfig(), "MainWin");
+ const QString& dir = conf.readEntry("LastOpenDir", "");
+ const QString& path = QFileDialog::getOpenFileName(this,i18n("Open project"), dir,
++#ifdef HAVE_LIBORIGIN
+ i18n("LabPlot Projects (%1);;Origin Projects (%2)", Project::supportedExtensions(), OriginProjectParser::supportedExtensions()) );
++#else
++ i18n("LabPlot Projects (%1)", Project::supportedExtensions()) );
++#endif
+
+ if (path.isEmpty())// "Cancel" was clicked
+ return;
+@@ -970,12 +980,14 @@ void MainWin::openProject(const QString& filename) {
+ bool rc = false;
+ if (Project::isLabPlotProject(filename))
+ rc = m_project->load(filename);
++#ifdef HAVE_LIBORIGIN
+ else if (OriginProjectParser::isOriginProject(filename)) {
+ OriginProjectParser parser;
+ parser.setProjectFileName(filename);
+ parser.importTo(m_project, QStringList()); //TODO: add return code
+ rc = true;
+ }
++#endif
+
+ if (!rc) {
+ closeProject();
+@@ -1718,7 +1730,11 @@ void MainWin::dropEvent(QDropEvent* event) {
+ QUrl url = event->mimeData()->urls().at(0);
+ const QString& f = url.toLocalFile();
+
++#ifdef HAVE_LIBORIGIN
+ if (Project::isLabPlotProject(f) || OriginProjectParser::isOriginProject(f))
++#else
++ if (Project::isLabPlotProject(f))
++#endif
+ openProject(f);
+ else {
+ if (!m_project)
+diff --git a/src/kdefrontend/datasources/ImportProjectDialog.cpp b/src/kdefrontend/datasources/ImportProjectDialog.cpp
+index 85cbf34..5216127 100644
+--- a/src/kdefrontend/datasources/ImportProjectDialog.cpp
++++ b/src/kdefrontend/datasources/ImportProjectDialog.cpp
+@@ -111,8 +111,10 @@ ImportProjectDialog::ImportProjectDialog(MainWin* parent, ProjectType type) : QD
+ title = i18n("Import LabPlot Project");
+ break;
+ case (ProjectOrigin):
++#ifdef HAVE_LIBORIGIN
+ m_projectParser = new OriginProjectParser();
+ title = i18n("Import Origin Project");
++#endif
+ break;
+ }
+
+@@ -234,8 +236,10 @@ void ImportProjectDialog::importTo(QStatusBar* statusBar) const {
+ timer.start();
+ connect(m_projectParser, SIGNAL(completed(int)), progressBar, SLOT(setValue(int)));
+
++#ifdef HAVE_LIBORIGIN
+ if (m_projectType == ProjectOrigin && ui.chbUnusedObjects->isVisible() && ui.chbUnusedObjects->isChecked())
+ reinterpret_cast<OriginProjectParser*>(m_projectParser)->setImportUnusedObjects(true);
++#endif
+
+ m_projectParser->importTo(targetFolder, selectedPathes);
+ statusBar->showMessage( i18n("Project data imported in %1 seconds.", (float)timer.elapsed()/1000) );
+@@ -251,6 +255,7 @@ void ImportProjectDialog::refreshPreview() {
+ QString project = ui.leFileName->text();
+ m_projectParser->setProjectFileName(project);
+
++#ifdef HAVE_LIBORIGIN
+ if (m_projectType == ProjectOrigin) {
+ OriginProjectParser* originParser = reinterpret_cast<OriginProjectParser*>(m_projectParser);
+ if (originParser->hasUnusedObjects())
+@@ -260,6 +265,7 @@ void ImportProjectDialog::refreshPreview() {
+
+ originParser->setImportUnusedObjects(ui.chbUnusedObjects->isVisible() && ui.chbUnusedObjects->isChecked());
+ }
++#endif
+
+ ui.tvPreview->setModel(m_projectParser->model());
+
+@@ -349,9 +355,11 @@ void ImportProjectDialog::selectFile() {
+ supportedFormats = i18n("LabPlot Projects (%1)", Project::supportedExtensions());
+ break;
+ case (ProjectOrigin):
++#ifdef HAVE_LIBORIGIN
+ title = i18n("Open Origin Project");
+ lastDirConfEntryName = QLatin1String("LastImportOriginProjecttDir");
+ supportedFormats = i18n("Origin Projects (%1)", OriginProjectParser::supportedExtensions());
++#endif
+ break;
+ }
+
+--
+cgit v0.11.2
+
diff --git a/user/labplot/really-disable-liborigin.patch b/user/labplot/really-disable-liborigin.patch
new file mode 100644
index 000000000..c97a30ed7
--- /dev/null
+++ b/user/labplot/really-disable-liborigin.patch
@@ -0,0 +1,32 @@
+From 75408146f9e26521dff825acc2bfb270dc4f6179 Mon Sep 17 00:00:00 2001
+From: "A. Wilcox" <AWilcox@Wilcox-Tech.com>
+Date: Wed, 12 Sep 2018 11:56:17 -0500
+Subject: [PATCH] datasources: Only include Origin header if enabled
+
+ImportProjectDialog was still #including the OriginProjectParser header,
+which caused a build error if -DENABLE_LIBORIGIN=OFF.
+
+Signed-off-by: A. Wilcox <AWilcox@Wilcox-Tech.com>
+Fixes: d67faf643b2e69c017c21e9d9aaa1fe2d3de6b0e
+---
+ src/kdefrontend/datasources/ImportProjectDialog.cpp | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/src/kdefrontend/datasources/ImportProjectDialog.cpp b/src/kdefrontend/datasources/ImportProjectDialog.cpp
+index 52161277..9fac9389 100644
+--- a/src/kdefrontend/datasources/ImportProjectDialog.cpp
++++ b/src/kdefrontend/datasources/ImportProjectDialog.cpp
+@@ -30,7 +30,9 @@
+ #include "backend/core/AspectTreeModel.h"
+ #include "backend/core/Project.h"
+ #include "backend/datasources/projects/LabPlotProjectParser.h"
+-#include "backend/datasources/projects/OriginProjectParser.h"
++#ifdef HAVE_LIBORIGIN
++# include "backend/datasources/projects/OriginProjectParser.h"
++#endif
+ #include "kdefrontend/MainWin.h"
+ #include "commonfrontend/widgets/TreeViewComboBox.h"
+
+--
+2.18.0
+
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
+