Lines 1-9
Link Here
|
1 |
# Copyright 1999-2019 Gentoo Authors |
1 |
# Copyright 1999-2020 Gentoo Authors |
2 |
# Distributed under the terms of the GNU General Public License v2 |
2 |
# Distributed under the terms of the GNU General Public License v2 |
3 |
|
3 |
|
4 |
EAPI=7 |
4 |
EAPI=7 |
5 |
|
5 |
|
6 |
PYTHON_COMPAT=( python3_{7,8} ) |
6 |
PYTHON_COMPAT=( python3_{6,7} ) |
7 |
PYTHON_REQ_USE="sqlite" # bug 572440 |
7 |
PYTHON_REQ_USE="sqlite" # bug 572440 |
8 |
WANT_AUTOCONF="2.1" |
8 |
WANT_AUTOCONF="2.1" |
9 |
WX_GTK_VER=3.0 |
9 |
WX_GTK_VER=3.0 |
Lines 21-32
Link Here
|
21 |
LICENSE="GPL-2" |
21 |
LICENSE="GPL-2" |
22 |
SLOT="0/7.8.0" |
22 |
SLOT="0/7.8.0" |
23 |
KEYWORDS="~amd64 ~ppc ~x86" |
23 |
KEYWORDS="~amd64 ~ppc ~x86" |
24 |
IUSE="blas cxx fftw geos lapack liblas mysql netcdf nls odbc opencl opengl openmp png postgres readline sqlite threads tiff truetype X" |
24 |
IUSE="blas cxx fftw geos lapack liblas mysql netcdf nls odbc opencl opengl openmp png postgres readline sqlite threads tiff truetype X zstd" |
25 |
|
25 |
|
26 |
RDEPEND="${PYTHON_DEPS} |
26 |
RDEPEND="${PYTHON_DEPS} |
27 |
>=app-admin/eselect-1.2 |
27 |
>=app-admin/eselect-1.2 |
28 |
$(python_gen_cond_dep 'dev-python/numpy[${PYTHON_MULTI_USEDEP}]') |
28 |
$(python_gen_cond_dep 'dev-python/numpy[${PYTHON_MULTI_USEDEP}]') |
29 |
media-libs/libprojectm |
|
|
30 |
sci-libs/gdal |
29 |
sci-libs/gdal |
31 |
sys-libs/gdbm |
30 |
sys-libs/gdbm |
32 |
sys-libs/ncurses:0= |
31 |
sys-libs/ncurses:0= |
Lines 34-48
Link Here
|
34 |
sci-libs/xdrfile |
33 |
sci-libs/xdrfile |
35 |
sys-libs/zlib |
34 |
sys-libs/zlib |
36 |
blas? ( |
35 |
blas? ( |
37 |
|| ( ( virtual/cblas virtual/blas ) |
36 |
virtual/cblas |
38 |
sci-libs/openblas ) |
37 |
virtual/blas |
39 |
) |
38 |
) |
40 |
fftw? ( sci-libs/fftw:3.0= ) |
39 |
fftw? ( sci-libs/fftw:3.0= ) |
41 |
geos? ( sci-libs/geos ) |
40 |
geos? ( sci-libs/geos ) |
42 |
lapack? ( |
41 |
lapack? ( virtual/lapack ) |
43 |
|| ( virtual/lapack |
|
|
44 |
sci-libs/lapack-reference ) |
45 |
) |
46 |
liblas? ( sci-geosciences/liblas ) |
42 |
liblas? ( sci-geosciences/liblas ) |
47 |
mysql? ( dev-db/mysql-connector-c:= ) |
43 |
mysql? ( dev-db/mysql-connector-c:= ) |
48 |
netcdf? ( sci-libs/netcdf ) |
44 |
netcdf? ( sci-libs/netcdf ) |
Lines 64-69
Link Here
|
64 |
x11-libs/libXext |
60 |
x11-libs/libXext |
65 |
x11-libs/libXt |
61 |
x11-libs/libXt |
66 |
) |
62 |
) |
|
|
63 |
zstd? ( app-arch/zstd ) |
67 |
" |
64 |
" |
68 |
DEPEND="${RDEPEND} |
65 |
DEPEND="${RDEPEND} |
69 |
sys-devel/bison |
66 |
sys-devel/bison |
Lines 83-89
Link Here
|
83 |
|
80 |
|
84 |
PATCHES=( |
81 |
PATCHES=( |
85 |
"${FILESDIR}/${PN}"-7.0.1-declare-inespg.patch |
82 |
"${FILESDIR}/${PN}"-7.0.1-declare-inespg.patch |
86 |
"${FILESDIR}"/grass-7.8.1-pyversion.patch |
|
|
87 |
) |
83 |
) |
88 |
|
84 |
|
89 |
pkg_setup() { |
85 |
pkg_setup() { |
Lines 91-100
Link Here
|
91 |
local mylapack |
87 |
local mylapack |
92 |
mylapack=$(eselect lapack show) || die |
88 |
mylapack=$(eselect lapack show) || die |
93 |
if [[ -z "${mylapack/.*reference.*/}" ]] && \ |
89 |
if [[ -z "${mylapack/.*reference.*/}" ]] && \ |
94 |
[[ -z "${mylapack/.*atlas.*/}" ]]; then |
90 |
[[ -z "${mylapack/.*openblas.*/}" ]]; then |
95 |
ewarn "You need to set lapack to atlas or reference. Do:" |
91 |
ewarn "You need to set lapack to openblas or reference. Do:" |
96 |
ewarn " eselect lapack set <impl>" |
92 |
ewarn " eselect lapack set <impl>" |
97 |
ewarn "where <impl> is atlas, threaded-atlas or reference" |
93 |
ewarn "where <impl> is openblas or reference" |
98 |
die "setup failed" |
94 |
die "setup failed" |
99 |
fi |
95 |
fi |
100 |
fi |
96 |
fi |
Lines 103-112
Link Here
|
103 |
local myblas |
99 |
local myblas |
104 |
myblas=$(eselect blas show) || die |
100 |
myblas=$(eselect blas show) || die |
105 |
if [[ -z "${myblas/.*reference.*/}" ]] && \ |
101 |
if [[ -z "${myblas/.*reference.*/}" ]] && \ |
106 |
[[ -z "${myblas/.*atlas.*/}" ]]; then |
102 |
[[ -z "${myblas/.*openblas.*/}" ]]; then |
107 |
ewarn "You need to set blas to atlas or reference. Do:" |
103 |
ewarn "You need to set blas to openblas or reference. Do:" |
108 |
ewarn " eselect blas set <impl>" |
104 |
ewarn " eselect blas set <impl>" |
109 |
ewarn "where <impl> is atlas, threaded-atlas or reference" |
105 |
ewarn "where <impl> is openblas or reference" |
110 |
die "setup failed" |
106 |
die "setup failed" |
111 |
fi |
107 |
fi |
112 |
fi |
108 |
fi |
Lines 115-129
Link Here
|
115 |
} |
111 |
} |
116 |
|
112 |
|
117 |
src_prepare() { |
113 |
src_prepare() { |
118 |
# Fix unversioned python calls |
|
|
119 |
local pyver=${EPYTHON/python/} |
120 |
sed -e "s:GRASS_PYTHON=.*:&${pyver}:" -i "${S}/lib/init/grass.sh" || die |
121 |
sed -e "s:= python:&${pyver}:" -i "${S}/include/Make/Platform.make.in" || die |
122 |
|
123 |
# fix header being unconditionally included |
124 |
# see upstream https://trac.osgeo.org/grass/ticket/2779 |
125 |
sed -e 's:\(#include <ogr_api.h>\):#ifdef HAVE_OGR\n\1\n#endif:' \ |
126 |
-i "${S}/vector/v.external/main.c" || die "failed to sed main.c" |
127 |
|
114 |
|
128 |
default |
115 |
default |
129 |
eautoconf |
116 |
eautoconf |
Lines 161-167
Link Here
|
161 |
--without-opendwg |
148 |
--without-opendwg |
162 |
--with-regex |
149 |
--with-regex |
163 |
--with-gdal="${EPREFIX%/}/usr/bin/gdal-config" |
150 |
--with-gdal="${EPREFIX%/}/usr/bin/gdal-config" |
164 |
--with-proj-includes="${EPREFIX%/}/usr/include/libprojectM" |
151 |
--with-proj-includes="${EPREFIX%/}/usr/include/proj" |
165 |
--with-proj-libs="${EPREFIX%/}/usr/$(get_libdir)" |
152 |
--with-proj-libs="${EPREFIX%/}/usr/$(get_libdir)" |
166 |
--with-proj-share="${EPREFIX%/}/usr/share/proj/" |
153 |
--with-proj-share="${EPREFIX%/}/usr/share/proj/" |
167 |
$(use_with cxx) |
154 |
$(use_with cxx) |
Lines 189-194
Link Here
|
189 |
$(use_with netcdf netcdf "${EPREFIX%/}/usr/bin/nc-config") |
176 |
$(use_with netcdf netcdf "${EPREFIX%/}/usr/bin/nc-config") |
190 |
$(use_with geos geos "${EPREFIX%/}/usr/bin/geos-config") |
177 |
$(use_with geos geos "${EPREFIX%/}/usr/bin/geos-config") |
191 |
$(use_with X x) |
178 |
$(use_with X x) |
|
|
179 |
$(use_with zstd) |
192 |
) |
180 |
) |
193 |
econf "${myeconfargs[@]}" |
181 |
econf "${myeconfargs[@]}" |
194 |
} |
182 |
} |
Lines 259-265
Link Here
|
259 |
if use X; then |
247 |
if use X; then |
260 |
local GUI="-gui" |
248 |
local GUI="-gui" |
261 |
[[ ${WX_BUILD} == yes ]] && GUI="-wxpython" |
249 |
[[ ${WX_BUILD} == yes ]] && GUI="-wxpython" |
262 |
make_desktop_entry "/usr/bin/${MY_PM} ${GUI}" "${PN}" "${PN}-48x48" "Science;Education" |
250 |
make_desktop_entry "/usr/bin/${MY_PM} ${GUI}" "${PN}" "${PN}-48x48" "Science;Geoscience" |
263 |
doicon -s 48 gui/icons/${PN}-48x48.png |
251 |
doicon -s 48 gui/icons/${PN}-48x48.png |
264 |
fi |
252 |
fi |
265 |
|
253 |
|