1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
5 PYTHON_COMPAT=( python3_6 )
6 PYTHON_REQ_USE="sqlite"
8 DISTUTILS_SINGLE_IMPL=1
9 inherit distutils-r1 xdg-utils
11 DESCRIPTION="Genealogical Research and Analysis Management Programming System"
12 HOMEPAGE="https://gramps-project.org/"
13 SRC_URI="https://github.com/gramps-project/${PN}/archive/v${PV}.tar.gz
19 IUSE="+rcs +reports exif geo postscript spell"
22 dev-python/bsddb3[${PYTHON_USEDEP}]
23 dev-python/pycairo[${PYTHON_USEDEP}]
24 >=dev-python/pygobject-3.12:3[cairo,${PYTHON_USEDEP}]
25 dev-python/pyicu[${PYTHON_USEDEP}]
27 >x11-libs/gtk+-3.14.8:3[introspection]
28 x11-libs/pango[introspection]
30 reports? ( media-gfx/graphviz[postscript?] )
31 exif? ( >=media-libs/gexiv2-0.5[${PYTHON_USEDEP},introspection] )
32 geo? ( >=sci-geosciences/osm-gps-map-1.1.0 )
33 spell? ( app-text/gtkspell:3[introspection] )
37 python_prepare_all() {
38 # Install documentation to the proper location. This can't be done
39 # easily with a patch because we substitute in the $PF variable,
40 # and that changes with every revision.
41 sed -i "s:share/doc/gramps:share/doc/${PF}:g" setup.py || die
42 distutils-r1_python_prepare_all
45 python_configure_all() {
47 --resourcepath=/usr/share
48 --no-compress-manpages
53 # GRAMPS builds just fine out of tree but it confuses its test suite.
54 # The following might be an ugly hack but at least it lets the tests
55 # run properly until either I or upstream have come up with something
57 rm -rf "${S}/build" && ln -s "${BUILD_DIR}" "${S}"/build || \
58 die "Failed to symlink build directory to source directory"
64 xdg_desktop_database_update
65 xdg_mimeinfo_database_update
69 xdg_desktop_database_update
70 xdg_mimeinfo_database_update