summaryrefslogtreecommitdiff
path: root/sci-geosciences/GeographicLib
diff options
context:
space:
mode:
Diffstat (limited to 'sci-geosciences/GeographicLib')
-rw-r--r--sci-geosciences/GeographicLib/GeographicLib-1.52-r1.ebuild106
-rw-r--r--sci-geosciences/GeographicLib/Manifest1
2 files changed, 107 insertions, 0 deletions
diff --git a/sci-geosciences/GeographicLib/GeographicLib-1.52-r1.ebuild b/sci-geosciences/GeographicLib/GeographicLib-1.52-r1.ebuild
new file mode 100644
index 000000000000..18ac53badef6
--- /dev/null
+++ b/sci-geosciences/GeographicLib/GeographicLib-1.52-r1.ebuild
@@ -0,0 +1,106 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+
+inherit cmake distutils-r1
+
+MY_PN="${PN,,}"
+
+DESCRIPTION="C++ library for converting geographic coordinate systems"
+HOMEPAGE="https://sourceforge.net/projects/geographiclib/"
+SRC_URI="mirror://sourceforge/${MY_PN}/${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0/19"
+KEYWORDS="~amd64 ~arm"
+IUSE="doc examples python"
+
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+RDEPEND="python? ( ${PYTHON_DEPS} )"
+DEPEND="${RDEPEND}"
+BDEPEND="
+ doc? (
+ >=app-doc/doxygen-1.8.7
+ >=dev-lang/perl-5.26.1-r1
+ >=dev-python/sphinx-1.6.3-r2
+ >=sys-apps/util-linux-2.31
+ )
+"
+
+distutils_enable_tests setup.py
+# there are additional docs in the python dir
+distutils_enable_sphinx python/doc
+
+src_prepare() {
+ cmake_src_prepare
+
+ if use python; then
+ pushd "python" || die
+ distutils-r1_src_prepare
+ popd || die
+ fi
+}
+
+src_configure() {
+ export GEODATAPATH="/usr/share/${MY_PN}"
+
+ local mycmakeargs=(
+ -DGEOGRAPHICLIB_DOCUMENTATION=$(usex doc ON OFF)
+ -DGEOGRAPHICLIB_LIB_TYPE="SHARED"
+ -DGEOGRAPHICLIB_DATA="${GEODATAPATH}"
+ )
+ cmake_src_configure
+}
+
+src_compile() {
+ cmake_src_compile
+
+ if use python; then
+ pushd "python" || die
+ distutils-r1_src_compile
+ popd || die
+ fi
+}
+
+src_test() {
+ cmake_src_test
+
+ if use python; then
+ pushd "python" || die
+ distutils-r1_src_test
+ popd || die
+ fi
+}
+
+src_install() {
+ cmake_src_install
+
+ # Remove python things added by the cmake_src_install function
+ rm -r "${ED}/usr/$(get_libdir)/python" || die
+
+ # If using Python, we re-add these python files for each implementation
+ if use python; then
+ pushd "python" || die
+ distutils-r1_src_install
+ popd || die
+ fi
+
+ # TODO: find out if java stuff need something
+
+ # Installs to wrong doc dir for some reason
+ # Also happens with USE="-doc"
+ mv "${D}/usr/share/doc/${PN}" "${D}/usr/share/doc/${PF}" || die
+
+ if use examples; then
+ dodoc -r examples
+ docompress -x "/usr/share/doc/${PF}/examples"
+ fi
+
+ insinto "/usr/share/maxima/${MY_PN}"
+ doins -r maxima/.
+
+ find "${D}" -name "*.la" -delete || die
+}
diff --git a/sci-geosciences/GeographicLib/Manifest b/sci-geosciences/GeographicLib/Manifest
index a96c7ae6ef6c..6f47c7b7b4ea 100644
--- a/sci-geosciences/GeographicLib/Manifest
+++ b/sci-geosciences/GeographicLib/Manifest
@@ -1,3 +1,4 @@
DIST GeographicLib-1.52.tar.gz 2432658 BLAKE2B 87328de1774ab9aec05355362c9a1760cf62864135b97a3e9cb1382b0ec9825b032f6c67a5e02b762c3009a3876a9cd995e3a49a3ad3c051dcd36446b55d0191 SHA512 98a4d33764db4a4755851a7db639fd9e055dcf4f1f949258e112fce2e198076b5896fcae2c1ea36b37fe1000d28eec326636a730e70f25bc19a1610423ba6859
+EBUILD GeographicLib-1.52-r1.ebuild 2126 BLAKE2B de3551d0c5cdcaf98897eee5b0042c113fbae11a0c719ca66c77249bf5df810fbd86e3ccd03369d2504e0f51420236b0df0ceefa63f970cf7fa203275db8dbae SHA512 cd5ae878f64bb422d0f0e4be4f9b003bcd03194f3893102898b3cc1f645ca34869637983678d05edb59f4c25bc7c82b4e874614a95d57908fa511dd348fe4a0b
EBUILD GeographicLib-1.52.ebuild 2182 BLAKE2B 1840313b9b73175c1c73b765b789f26105d29aa7ba615b287264216ac11a793f35c94980790702031161af06411378d5e107b1d24d3ed54616fdb9fc5470c069 SHA512 1a52c4c4dae62bbcac21f0f2dcdb06332f0729c51b14c370b1190714079943985fc0166427d97ffeb2a1c8cea187378e3efd555b3d4a4199c775538237149ed9
MISC metadata.xml 875 BLAKE2B c383ecf94641b3ebdcb225b61eaec0077f83a03647306af59142fa633e8865ec46e809bd75410258dd9141cdca1141efd94f0a005ab273dfa2039811d419db24 SHA512 800b4153192b66e848a79a3e5ce915b21d61008d4b43e0f8c5da34142823af15367220589db1a04a8e3cddeb3ad0d300f002c2264e71408200595c67bcc7a625