summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMathy Vanvoorden <mathy@vanvoorden.be>2021-06-07 17:48:55 +0200
committerDennis Lamm <expeditioneer@gentoo.org>2021-06-10 19:40:50 +0200
commit7346c0ab432a2777bd255580eabcd4debead13ef (patch)
tree1ec5d3500c629859962edf0d38a1e9cceb1c1daf /dev-libs/libsavitar
parentmedia-gfx/fdm-materials: Version bump: 4.9.1 (diff)
downloadgentoo-7346c0ab432a2777bd255580eabcd4debead13ef.tar.gz
gentoo-7346c0ab432a2777bd255580eabcd4debead13ef.tar.bz2
gentoo-7346c0ab432a2777bd255580eabcd4debead13ef.zip
dev-libs/libsavitar: Version bump to 4.9.1
Closes: https://bugs.gentoo.org/793803 Package-Manager: Portage-3.0.19, Repoman-3.0.3 Signed-off-by: Mathy Vanvoorden <mathy@vanvoorden.be> Signed-off-by: Dennis Lamm <expeditioneer@gentoo.org>
Diffstat (limited to 'dev-libs/libsavitar')
-rw-r--r--dev-libs/libsavitar/Manifest1
-rw-r--r--dev-libs/libsavitar/libsavitar-4.9.1.ebuild76
2 files changed, 77 insertions, 0 deletions
diff --git a/dev-libs/libsavitar/Manifest b/dev-libs/libsavitar/Manifest
index fa69039eb88e..9f6888baa8af 100644
--- a/dev-libs/libsavitar/Manifest
+++ b/dev-libs/libsavitar/Manifest
@@ -1 +1,2 @@
DIST libsavitar-4.8.0.tar.gz 99030 BLAKE2B a1c1e252aa942114a1d7112d2e661b5e63403502642826c6b92c408c8eabd3d9fb12b44dc286f9a0dce3d42f473adae2441d357f237c903c8a0df936c41f9f37 SHA512 65d31986b120c9e717b10d0bac420f2582d9f1b44051d88f89475408d1f7997e144001c61f180eac554de33f1f8c1ec9555a6c23bdd797315624f57030f7ec8c
+DIST libsavitar-4.9.1.tar.gz 100496 BLAKE2B 7700f110522298905c1e4cf42529e83c06c337ac826007db2fca8abf462abcb8dd9245d2d81773ba3e6663d9afa093685bf955a1cc7e27d48fc904913e56d62f SHA512 2b291a17603922a4a06292282392015cf381a813b5f9a374e8cb35da6c0701ead72cbf76f17e763793225885a4209b49e73114f462b40d6999f95db6de887a44
diff --git a/dev-libs/libsavitar/libsavitar-4.9.1.ebuild b/dev-libs/libsavitar/libsavitar-4.9.1.ebuild
new file mode 100644
index 000000000000..999341bf1c3c
--- /dev/null
+++ b/dev-libs/libsavitar/libsavitar-4.9.1.ebuild
@@ -0,0 +1,76 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{7..9} )
+
+inherit cmake python-single-r1
+
+MY_PN="libSavitar"
+
+DESCRIPTION="C++ implementation of 3mf loading with SIP python bindings"
+HOMEPAGE="https://github.com/Ultimaker/libSavitar"
+SRC_URI="https://github.com/Ultimaker/${MY_PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="LGPL-3"
+SLOT="0/3"
+KEYWORDS="~amd64 ~arm64 ~x86"
+
+IUSE="+python static-libs test"
+RESTRICT="!test? ( test )"
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+
+RDEPEND="${PYTHON_DEPS}
+ dev-libs/pugixml
+ $(python_gen_cond_dep '
+ <dev-python/sip-5[${PYTHON_MULTI_USEDEP}]
+ ')"
+
+DEPEND="${RDEPEND}
+ test? (
+ dev-cpp/gtest
+ dev-cpp/tbb
+ )"
+
+S="${WORKDIR}/${MY_PN}-${PV}"
+BUILD_DIR="${S}/build"
+
+PATCHES=( "${FILESDIR}/${PN}-4.7.0-use-system-pugixml.patch" )
+
+pkg_setup() {
+ use python && python-single-r1_pkg_setup
+}
+
+src_prepare() {
+ # remove bundled pugixml
+ rm -r "${S}"/pugixml || die
+
+ find "${S}"/src -type f -name '*.cpp' -o -name '*.h' | xargs sed -i \
+ -e 's "../pugixml/src/pugixml.hpp" <pugixml.hpp> g' || die
+
+ if use test; then
+ find "${S}"/tests -type f -name '*.cpp' -o -name '*.h' | xargs sed -i \
+ -e 's "../pugixml/src/pugixml.hpp" <pugixml.hpp> g' || die
+ fi
+
+ # find SIP for current python version, not the latest installed
+ sed -i -e "s/find_package(Python3 3.4 REQUIRED/find_package(Python3 ${EPYTHON##python} EXACT REQUIRED/g" \
+ CMakeLists.txt cmake/FindSIP.cmake || die
+
+ cmake_src_prepare
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DBUILD_PYTHON=$(usex python ON OFF)
+ -DBUILD_STATIC=$(usex static-libs ON OFF)
+ -DBUILD_TESTS=$(usex test ON OFF)
+ )
+
+ cmake_src_configure
+}
+
+src_test() {
+ cmake_src_test
+}