Gentoo Archives: gentoo-commits

From: David Seifert <soap@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-misc/nco/
Date: Mon, 01 Jan 2018 22:41:36
Message-Id: 1514846444.906d6a3933fcfe30c68f701d021d50be5dde48e7.soap@gentoo
1 commit: 906d6a3933fcfe30c68f701d021d50be5dde48e7
2 Author: David Seifert <soap <AT> gentoo <DOT> org>
3 AuthorDate: Mon Jan 1 22:40:44 2018 +0000
4 Commit: David Seifert <soap <AT> gentoo <DOT> org>
5 CommitDate: Mon Jan 1 22:40:44 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=906d6a39
7
8 sci-misc/nco: Port to EAPI 6
9
10 * Remove use of `built_with_use` function
11
12 Package-Manager: Portage-2.3.19, Repoman-2.3.6
13
14 sci-misc/nco/nco-4.5.1-r2.ebuild | 51 ++++++++++++++++++++++------------------
15 1 file changed, 28 insertions(+), 23 deletions(-)
16
17 diff --git a/sci-misc/nco/nco-4.5.1-r2.ebuild b/sci-misc/nco/nco-4.5.1-r2.ebuild
18 index 850672c5b05..a1cd22244bb 100644
19 --- a/sci-misc/nco/nco-4.5.1-r2.ebuild
20 +++ b/sci-misc/nco/nco-4.5.1-r2.ebuild
21 @@ -1,10 +1,9 @@
22 -# Copyright 1999-2017 Gentoo Foundation
23 +# Copyright 1999-2018 Gentoo Foundation
24 # Distributed under the terms of the GNU General Public License v2
25
26 -EAPI=5
27 +EAPI=6
28
29 -AUTOTOOLS_IN_SOURCE_BUILD=1
30 -inherit autotools-utils eutils flag-o-matic
31 +inherit flag-o-matic toolchain-funcs
32
33 DESCRIPTION="Command line utilities for operating on netCDF files"
34 HOMEPAGE="http://nco.sourceforge.net/"
35 @@ -13,37 +12,43 @@ SRC_URI="http://nco.sf.net/src/${P}.tar.gz"
36 LICENSE="GPL-3"
37 SLOT="0/${PV}"
38 KEYWORDS="amd64 x86 ~amd64-linux ~x86-linux"
39 -IUSE="dap doc gsl ncap2 openmp static-libs test udunits"
40 +IUSE="dap gsl hdf5 ncap2 openmp static-libs test udunits"
41
42 RDEPEND="
43 - >=sci-libs/netcdf-4:=[dap=,tools]
44 + >=sci-libs/netcdf-4:=[dap=,hdf5?,tools]
45 gsl? ( sci-libs/gsl:= )
46 ncap2? ( dev-cpp/antlr-cpp:2= )
47 udunits? ( >=sci-libs/udunits-2 )"
48 -
49 DEPEND="${RDEPEND}
50 test? ( >=sci-libs/netcdf-4[tools] )"
51
52 +pkg_pretend() {
53 + [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
54 +}
55 +
56 +pkg_setup() {
57 + [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
58 +}
59 +
60 src_configure() {
61 - local myeconfargs=(
62 - --disable-udunits
63 - $(use_enable dap dap-netcdf)
64 - $(use_enable gsl)
65 - $(use_enable ncap2)
66 - $(use_enable openmp)
67 + use hdf5 && append-cppflags -DHAVE_NETCDF4_H
68 +
69 + econf \
70 + --disable-udunits \
71 + $(use_enable dap) \
72 + $(use_enable gsl) \
73 + $(use_enable hdf5 netcdf4) \
74 + $(use_enable ncap2) \
75 + $(use_enable openmp) \
76 + $(use_enable static-libs static) \
77 $(use_enable udunits udunits2)
78 - )
79 - if has_version '>=sci-libs/netcdf-4[hdf5]'; then
80 - myeconfargs+=( --enable-netcdf4 )
81 - append-cppflags -DHAVE_NETCDF4_H
82 - else
83 - myeconfargs+=( --disable-netcdf4 )
84 - fi
85 - autotools-utils_src_configure
86 }
87
88 src_install() {
89 - use doc && DOCS=( doc/nco.pdf ) && HTML_DOCS=( doc/nco.html )
90 - autotools-utils_src_install
91 + default
92 doinfo doc/*.info*
93 +
94 + if ! use static-libs; then
95 + find "${D}" -name '*.la' -delete || die
96 + fi
97 }