diff options
-rw-r--r-- | .SRCINFO | 12 | ||||
-rw-r--r-- | .gitignore | 22 | ||||
-rw-r--r-- | 0001-Do-not-vendor-the-pugixml-library.patch | 127 | ||||
-rw-r--r-- | PKGBUILD | 48 |
4 files changed, 54 insertions, 155 deletions
@@ -1,22 +1,20 @@ pkgbase = libsavitar-git pkgdesc = c++ implementation of 3mf loading with SIP python bindings - pkgver = 4.9.beta.r0.gfe88675 - pkgrel = 3 + pkgver = 5.3.0.r5.g94ad4be + pkgrel = 0.1 url = https://github.com/Ultimaker/libSavitar arch = i686 arch = x86_64 license = LGPL makedepends = cmake - makedepends = python-sip4 - makedepends = sip4 makedepends = git + makedepends = python-pyqt5-sip + makedepends = sip depends = python depends = pugixml provides = libsavitar conflicts = libsavitar source = git+https://github.com/Ultimaker/libSavitar.git - source = 0001-Do-not-vendor-the-pugixml-library.patch - md5sums = SKIP - md5sums = 6a59f74447a366e9b71d294b916e5cc6 + b2sums = SKIP pkgname = libsavitar-git diff --git a/.gitignore b/.gitignore index 21fafcf692db..058ba2318df1 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,18 @@ -/pkg/ -/src/ -/libSavitar/ -/*.pkg.* +# based on https://github.com/github/gitignore/blob/master/ArchLinuxPackages.gitignore +*.tar +*.tar.* +*.rpm +*.jar +*.exe +*.msi +*.zip +*.tgz +*.log +*.log.* + +*/ +*.orig +*.bak +*.backup +*.kate-swp +.directory diff --git a/0001-Do-not-vendor-the-pugixml-library.patch b/0001-Do-not-vendor-the-pugixml-library.patch deleted file mode 100644 index 5a0dc7b942b8..000000000000 --- a/0001-Do-not-vendor-the-pugixml-library.patch +++ /dev/null @@ -1,127 +0,0 @@ -From 021d0732750cddee97e771814e5e2ca17585db46 Mon Sep 17 00:00:00 2001 -From: Eli Schwartz <eschwartz93@gmail.com> -Date: Mon, 9 Apr 2018 12:36:35 -0400 -Subject: [PATCH] Do not vendor the pugixml library - -This prevents trying to co-install pugixml with existing system -libraries, and also fixes the includes for pugixml.hpp to actually use -the include path added by find_package/add_subdirectory instead of a -hardcoded relative path. ---- - CMakeLists.txt | 2 +- - src/MeshData.cpp | 2 +- - src/Namespace.cpp | 2 +- - src/Scene.cpp | 2 +- - src/SceneNode.cpp | 2 +- - src/ThreeMFParser.h | 2 +- - tests/MeshDataTest.cpp | 2 +- - tests/NamespaceTest.cpp | 2 +- - 8 files changed, 8 insertions(+), 8 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index f22d42e..e78b1f8 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -15,7 +15,7 @@ if(BUILD_TESTS) - find_package(Threads QUIET) - endif() - --add_subdirectory(pugixml) -+find_package(pugixml REQUIRED) - - if(BUILD_PYTHON) - list(APPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake) -diff --git a/src/MeshData.cpp b/src/MeshData.cpp -index 97c089a..7c4de46 100644 ---- a/src/MeshData.cpp -+++ b/src/MeshData.cpp -@@ -17,7 +17,7 @@ - */ - - #include "MeshData.h" --#include "../pugixml/src/pugixml.hpp" -+#include <pugixml.hpp> - #include <cstring> - #include <iostream> - #include <stdexcept> //For std::runtime_error. -diff --git a/src/Namespace.cpp b/src/Namespace.cpp -index 2cfff76..23c3349 100644 ---- a/src/Namespace.cpp -+++ b/src/Namespace.cpp -@@ -3,7 +3,7 @@ - - #include "Namespace.h" - --#include "../pugixml/src/pugixml.hpp" -+#include <pugixml.hpp> - - namespace xml_namespace - { -diff --git a/src/Scene.cpp b/src/Scene.cpp -index 7a40570..86e9295 100644 ---- a/src/Scene.cpp -+++ b/src/Scene.cpp -@@ -17,7 +17,7 @@ - */ - - #include "Scene.h" --#include "../pugixml/src/pugixml.hpp" -+#include <pugixml.hpp> - #include <iostream> - #include <string> - using namespace Savitar; -diff --git a/src/SceneNode.cpp b/src/SceneNode.cpp -index db686e9..8c9dd8c 100644 ---- a/src/SceneNode.cpp -+++ b/src/SceneNode.cpp -@@ -18,7 +18,7 @@ - - #include "SceneNode.h" - #include "Namespace.h" --#include "../pugixml/src/pugixml.hpp" -+#include <pugixml.hpp> - #include <iostream> - using namespace Savitar; - -diff --git a/src/ThreeMFParser.h b/src/ThreeMFParser.h -index 3394683..a0f6691 100644 ---- a/src/ThreeMFParser.h -+++ b/src/ThreeMFParser.h -@@ -21,7 +21,7 @@ - - #include "SavitarExport.h" - #include "SceneNode.h" --#include "../pugixml/src/pugixml.hpp" -+#include <pugixml.hpp> - - #include <string> - namespace Savitar -diff --git a/tests/MeshDataTest.cpp b/tests/MeshDataTest.cpp -index 583b946..76d3187 100644 ---- a/tests/MeshDataTest.cpp -+++ b/tests/MeshDataTest.cpp -@@ -10,7 +10,7 @@ - #include <iterator> - #include <string> - --#include "../pugixml/src/pugixml.hpp" -+#include <pugixml.hpp> - - namespace Savitar - { -diff --git a/tests/NamespaceTest.cpp b/tests/NamespaceTest.cpp -index 1a2c2a2..4ac77fa 100644 ---- a/tests/NamespaceTest.cpp -+++ b/tests/NamespaceTest.cpp -@@ -7,7 +7,7 @@ - #include <gtest/gtest.h> - #include <iostream> - #include <string> --#include "../pugixml/src/pugixml.hpp" -+#include <pugixml.hpp> - - namespace xml_namespace - { --- -2.31.1 - @@ -1,38 +1,52 @@ -# Maintainer: Online122228 <premtimdukaj@hotmail.com> -# Previous Maintainer: Adam Goldsmith <contact@adamgoldsmith.name> -# Previous Maintainer: neodarz <neodarz@neodarz.net> +# Contributor: Online122228 <premtimdukaj@hotmail.com> +# Contributor: Adam Goldsmith <contact@adamgoldsmith.name> +# Contributor: neodarz <neodarz@neodarz.net> # Contributor: brodokk <brodokk@brodokk.space> pkgname=libsavitar-git -_pkgname=libSavitar -pkgver=4.9.beta.r0.gfe88675 -pkgrel=3 +_pkgbase=libSavitar +pkgver=5.3.0.r5.g94ad4be +pkgrel=0.1 pkgdesc="c++ implementation of 3mf loading with SIP python bindings" arch=('i686' 'x86_64') -url="https://github.com/Ultimaker/$_pkgname" +url="https://github.com/Ultimaker/$_pkgbase" license=('LGPL') depends=('python' 'pugixml') -makedepends=('cmake' 'python-sip4' 'sip4' 'git') +makedepends=( + 'cmake' + 'git' + 'python-pyqt5-sip' + 'sip' +) provides=('libsavitar') conflicts=('libsavitar') -source=("git+https://github.com/Ultimaker/$_pkgname.git" - "0001-Do-not-vendor-the-pugixml-library.patch") -md5sums=('SKIP' - '6a59f74447a366e9b71d294b916e5cc6') +source=("git+https://github.com/Ultimaker/$_pkgbase.git") +b2sums=('SKIP') pkgver() { - cd "${_pkgname}" - git describe --long 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' + cd "${_pkgbase}" + + # Generate git tag based version. Count only proper (v)#.#* [#=number] tags. + local _gitversion=$(git describe --long --tags --match '[v0-9][0-9.][0-9.]*' | sed -e 's|^v||' | tr '[:upper:]' '[:lower:]') + + # Format git-based version for pkgver + # Expected format: e.g. 1.5.0rc2.r521.g99982a1c + # Or in case of 'post': 1.5.0.post1.r521.g99982a1c + echo "${_gitversion}" | sed \ + -e 's;^\([0-9][0-9.]*\)[-_.]\([a-zA-Z]\+\);\1\2;' \ + -e 's;\([0-9]\+-g\);r\1;' \ + -e 's;-;.;g' \ + -e 's;\(post.*\);\.\1;' } prepare() { - cd "${_pkgname}" + cd "${_pkgbase}" sed -i 's,DESTINATION lib/python${PYTHON_VERSION_MAJOR}/dist-packages,DESTINATION lib/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/site-packages,g' CMakeLists.txt sed -i 's,DESTINATION lib/python${PYTHON_VERSION_MAJOR}/dist-packages/cura),DESTINATION lib/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/site-packages/cura),g' CMakeLists.txt } build() { - cd "${_pkgname}" + cd "${_pkgbase}" mkdir -p build && cd build cmake .. \ -DCMAKE_INSTALL_PREFIX=/usr \ @@ -42,6 +56,6 @@ build() { } package() { - cd "${_pkgname}/build" + cd "${_pkgbase}/build" make DESTDIR="${pkgdir}" install } |