From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 57E0E138334 for ; Mon, 8 Apr 2019 21:15:20 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id B0CDCE09CA; Mon, 8 Apr 2019 21:15:15 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 72D95E09CA for ; Mon, 8 Apr 2019 21:15:15 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id C706D335D1B for ; Mon, 8 Apr 2019 21:15:13 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id DEFA45B2 for ; Mon, 8 Apr 2019 21:15:10 +0000 (UTC) From: "Andreas Sturmlechner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Andreas Sturmlechner" Message-ID: <1554757982.bf5b286286b23a33a24f718e8bd765b9617f73e3.asturm@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: media-libs/vigra/ X-VCS-Repository: repo/gentoo X-VCS-Files: media-libs/vigra/vigra-1.11.1-r2.ebuild X-VCS-Directories: media-libs/vigra/ X-VCS-Committer: asturm X-VCS-Committer-Name: Andreas Sturmlechner X-VCS-Revision: bf5b286286b23a33a24f718e8bd765b9617f73e3 X-VCS-Branch: master Date: Mon, 8 Apr 2019 21:15:10 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 67019d3f-b01c-45f7-8084-9e75db4a873f X-Archives-Hash: e98d1101608701712bf5c3cac5507cb6 commit: bf5b286286b23a33a24f718e8bd765b9617f73e3 Author: Andreas Sturmlechner gentoo org> AuthorDate: Mon Apr 8 21:08:23 2019 +0000 Commit: Andreas Sturmlechner gentoo org> CommitDate: Mon Apr 8 21:13:02 2019 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bf5b2862 media-libs/vigra: Revbump with lots of fixes from 9999 Bug: https://bugs.gentoo.org/682860 Package-Manager: Portage-2.3.62, Repoman-2.3.12 Signed-off-by: Andreas Sturmlechner gentoo.org> media-libs/vigra/vigra-1.11.1-r2.ebuild | 163 ++++++++++++++++++++++++++++++++ 1 file changed, 163 insertions(+) diff --git a/media-libs/vigra/vigra-1.11.1-r2.ebuild b/media-libs/vigra/vigra-1.11.1-r2.ebuild new file mode 100644 index 00000000000..97c69bf3221 --- /dev/null +++ b/media-libs/vigra/vigra-1.11.1-r2.ebuild @@ -0,0 +1,163 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +MY_P="${P}-src" +MY_V="${PV//\./-}" +PYTHON_COMPAT=( python2_7 ) +PYTHON_REQ_USE="threads,xml" +inherit cmake-utils python-r1 + +DESCRIPTION="C++ computer vision library emphasizing customizable algorithms and structures" +HOMEPAGE="https://ukoethe.github.io/vigra/" + +if [[ ${PV} == *9999 ]] ; then + EGIT_REPO_URI="https://github.com/ukoethe/${PN}.git" + inherit git-r3 +else + SRC_URI="https://github.com/ukoethe/${PN}/releases/download/Version-${MY_V}/${MY_P}.tar.gz" + KEYWORDS="~amd64 ~sparc ~x86 ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris" +fi + +LICENSE="MIT" +SLOT="0" +IUSE="doc +fftw +hdf5 +jpeg mpi openexr +png +python test +tiff valgrind +zlib" + +REQUIRED_USE=" + doc? ( hdf5 fftw ) + python? ( hdf5 ${PYTHON_REQUIRED_USE} ) + test? ( hdf5 python fftw )" + +BDEPEND=" + doc? ( + app-doc/doxygen + >=dev-python/sphinx-1.1.3-r5[${PYTHON_USEDEP}] + ) + test? ( + >=dev-python/nose-1.1.2-r1[${PYTHON_USEDEP}] + valgrind? ( dev-util/valgrind ) + ) +" +# runtime dependency on python:2.7 is required by the vigra-config script +DEPEND=" + dev-lang/python:2.7 + fftw? ( sci-libs/fftw:3.0 ) + hdf5? ( >=sci-libs/hdf5-1.8.0:=[mpi=] ) + jpeg? ( virtual/jpeg:0 ) + openexr? ( + media-libs/openexr:= + media-libs/ilmbase:= + ) + png? ( media-libs/libpng:0= ) + python? ( + dev-libs/boost:=[python?,${PYTHON_USEDEP}] + dev-python/numpy[${PYTHON_USEDEP}] + ${PYTHON_DEPS} + ) + tiff? ( media-libs/tiff:0= ) + zlib? ( sys-libs/zlib ) +" +RDEPEND="${DEPEND}" + +# Severely broken, also disabled in Fedora, bugs #390447, #653442 +RESTRICT="test" + +PATCHES=( + "${FILESDIR}/${P}-fix-incorrect-template-parameter-type.patch" + "${FILESDIR}/${P}-lib_suffix.patch" +) + +pkg_setup() { + if use python || use doc; then + python_setup + fi +} + +src_prepare() { + vigra_disable() { + if ! use ${1}; then + sed -e "/^VIGRA_FIND_PACKAGE.*${2:-$1}/Is/^/#disabled by USE=${1}: /" \ + -i CMakeLists.txt || die "failed to disable ${1}" + fi + } + + cmake-utils_src_prepare + + if [[ ${PV} != *9999 ]]; then + rm -r doc || die "failed to remove shipped docs" + fi + + vigra_disable fftw fftw3 + vigra_disable fftw fftw3f + vigra_disable jpeg + vigra_disable png + vigra_disable tiff + vigra_disable zlib + + # Don't use python_fix_shebang because we can't put this behind USE="python" + sed -i -e '/env/s:python:python2:' config/vigra-config.in || die +} + +src_configure() { + vigra_configure() { + local mycmakeargs=( + -DAUTOEXEC_TESTS=OFF + -DDOCDIR="${BUILD_DIR}/doc" + -DDOCINSTALL="share/doc/${PF}" + -DWITH_HDF5=$(usex hdf5) + -DWITH_OPENEXR=$(usex openexr) + -DWITH_VALGRIND=$(usex valgrind) + -DWITH_VIGRANUMPY=$(usex python) + ) + cmake-utils_src_configure + } + + if use python; then + python_foreach_impl vigra_configure + else + # required for docdir + _cmake_check_build_dir init + vigra_configure + fi +} + +src_compile() { + local VIGRA_BUILD_DIR + vigra_compile() { + cmake-utils_src_compile + VIGRA_BUILD_DIR="${BUILD_DIR}" + } + if use python; then + python_foreach_impl vigra_compile + else + vigra_compile + fi + + if use doc; then + einfo "Generating Documentation" + # use build dir from last compile command + VARTEXFONTS="${T}/fonts" BUILD_DIR="${VIGRA_BUILD_DIR}" cmake-utils_src_make doc + fi +} + +src_install() { + if use python; then + python_foreach_impl cmake-utils_src_install + python_optimize + else + cmake-utils_src_install + fi +} + +src_test() { + # perhaps disable tests (see #390447) + vigra_test() { + PYTHONPATH="${BUILD_DIR}/vigranumpy/vigra" cmake-utils_src_test + } + if use python; then + python_foreach_impl vigra_test + else + vigra_test + fi +}