| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 |
|
| 21 | (define-module (gnu packages genealogy)
|
| 22 | #:use-module ((guix licenses) #:prefix license:)
|
| 23 | #:use-module (guix build-system glib-or-gtk)
|
| 24 | #:use-module (guix build-system pyproject)
|
| 25 | #:use-module (guix gexp)
|
| 26 | #:use-module (guix git-download)
|
| 27 | #:use-module (guix packages)
|
| 28 | #:use-module (gnu packages base)
|
| 29 | #:use-module (gnu packages bash)
|
| 30 | #:use-module (gnu packages check)
|
| 31 | #:use-module (gnu packages fonts)
|
| 32 | #:use-module (gnu packages freedesktop)
|
| 33 | #:use-module (gnu packages geo)
|
| 34 | #:use-module (gnu packages gettext)
|
| 35 | #:use-module (gnu packages ghostscript)
|
| 36 | #:use-module (gnu packages glib)
|
| 37 | #:use-module (gnu packages gnome)
|
| 38 | #:use-module (gnu packages graphviz)
|
| 39 | #:use-module (gnu packages gtk)
|
| 40 | #:use-module (gnu packages iso-codes)
|
| 41 | #:use-module (gnu packages python)
|
| 42 | #:use-module (gnu packages python-build)
|
| 43 | #:use-module (gnu packages python-xyz)
|
| 44 | #:use-module (gnu packages sqlite)
|
| 45 | #:use-module (gnu packages version-control)
|
| 46 | #:use-module (gnu packages xml))
|
| 47 |
|
| 48 | (define-public gramps
|
| 49 | (package
|
| 50 | (name "gramps")
|
| 51 | (version "6.0.8")
|
| 52 | (source
|
| 53 | (origin
|
| 54 | (method git-fetch)
|
| 55 | (uri (git-reference
|
| 56 | (url "https://github.com/gramps-project/gramps")
|
| 57 | (commit (string-append "v" version))))
|
| 58 | (file-name (git-file-name name version))
|
| 59 | (sha256
|
| 60 | (base32 "06kdcf6h9rqdcsx097a3n2z4q8yvln20ja7ajwrna1i133591bra"))))
|
| 61 | (build-system pyproject-build-system)
|
| 62 | (arguments
|
| 63 | (list
|
| 64 | #:imported-modules (append %glib-or-gtk-build-system-modules
|
| 65 | %pyproject-build-system-modules)
|
| 66 | #:modules
|
| 67 | `((ice-9 match)
|
| 68 | (srfi srfi-1)
|
| 69 | (guix build pyproject-build-system)
|
| 70 | ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
|
| 71 | (guix build utils))
|
| 72 | |
| 73 | #:test-flags
|
| 74 | |
| 75 | #~(list "--ignore=gramps/gen/merge/test/merge_ref_test.py"
|
| 76 | "--ignore=po/test/po_test.py"
|
| 77 | "--ignore=test/LosHawlos_db_test.py"
|
| 78 | "--ignore=test/blob_to_json_test.py"
|
| 79 | |
| 80 | #$@(map (lambda (ls) (string-append "--deselect=gramps/"
|
| 81 | (string-join ls "::")))
|
| 82 | '(("gen/proxy/test/proxies_test.py"
|
| 83 | "LivingProxyTest" "test_person_count")
|
| 84 | ("gen/proxy/test/proxies_test.py"
|
| 85 | "LivingPrivateProxyTest" "test_person_count")
|
| 86 | ("plugins/test/reports_test.py"
|
| 87 | "TestDynamic" "test_export_gedcom")
|
| 88 | ("plugins/test/reports_test.py"
|
| 89 | "TestDynamic" "test_export_gpkg")
|
| 90 | ("plugins/test/reports_test.py"
|
| 91 | "TestDynamic" "test_indiv_complete")
|
| 92 | ("plugins/test/reports_test.py"
|
| 93 | "TestDynamic" "test_navwebpage")
|
| 94 | ("plugins/test/reports_test.py"
|
| 95 | "TestDynamic" "test_tool_check")
|
| 96 | ("plugins/test/tools_test.py"
|
| 97 | "ToolControl" "test_tcg_and_check_and_repair")
|
| 98 | ("plugins/test/db_undo_and_signals_test.py"
|
| 99 | "TestSQLite" "test_one"))))
|
| 100 | #:phases
|
| 101 | #~(modify-phases %standard-phases
|
| 102 | (add-before 'build 'fix-gexiv2-dependency
|
| 103 | (lambda _
|
| 104 | |
| 105 | (substitute* (find-files "." ".*\\.py$")
|
| 106 | (("\"GExiv2\", \"0.10\"") "\"GExiv2\", \"0.16\""))))
|
| 107 | (add-after 'unpack 'swap-bsddb3-with-berkeleydb
|
| 108 | |
| 109 | (lambda _
|
| 110 | (substitute* (find-files "." ".*\\.py")
|
| 111 | (("bsddb3") "berkeleydb"))))
|
| 112 | (add-before 'check 'prepare-tests
|
| 113 | (lambda _
|
| 114 | (setenv "GDK_BACKEND" "-")
|
| 115 | (setenv "HOME" "/tmp")
|
| 116 | |
| 117 | |
| 118 | |
| 119 | (mkdir ".git")))
|
| 120 | (add-before 'wrap 'wrap-with-GI_TYPELIB_PATH
|
| 121 | (lambda* (#:key inputs #:allow-other-keys)
|
| 122 | (wrap-program (string-append #$output "/bin/gramps")
|
| 123 | `("GI_TYPELIB_PATH" ":" prefix
|
| 124 | ,(filter-map
|
| 125 | (match-lambda
|
| 126 | ((output . directory)
|
| 127 | (let ((girepodir (string-append
|
| 128 | directory
|
| 129 | "/lib/girepository-1.0")))
|
| 130 | (and (file-exists? girepodir)
|
| 131 | girepodir))))
|
| 132 | inputs)))))
|
| 133 | (add-after 'wrap 'glib-or-gtk-wrap
|
| 134 | (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap)))))
|
| 135 | (native-inputs
|
| 136 | (list gettext-minimal
|
| 137 | intltool
|
| 138 | python-jsonschema
|
| 139 | python-mock
|
| 140 | python-pytest
|
| 141 | python-setuptools))
|
| 142 | (inputs
|
| 143 | (list bash-minimal
|
| 144 | cairo
|
| 145 | font-gnu-freefont
|
| 146 | geocode-glib
|
| 147 | gexiv2
|
| 148 | ghostscript
|
| 149 | gobject-introspection
|
| 150 | gtk+
|
| 151 | gtkspell3
|
| 152 | graphviz
|
| 153 | (librsvg-for-system)
|
| 154 | osm-gps-map
|
| 155 | pango
|
| 156 | python-berkeleydb
|
| 157 | python-imagesize
|
| 158 | python-orjson
|
| 159 | python-pillow
|
| 160 | python-pycairo
|
| 161 | python-pycountry
|
| 162 | python-pygobject
|
| 163 | python-pyicu
|
| 164 | rcs
|
| 165 | sqlite
|
| 166 | xdg-utils))
|
| 167 | (home-page "https://gramps-project.org")
|
| 168 | (synopsis "Genealogical research software")
|
| 169 | (description
|
| 170 | "Gramps is a free software project and community striving to produce
|
| 171 | a genealogy program that is both intuitive for hobbyists and feature-complete
|
| 172 | for professional genealogists.")
|
| 173 | (license license:gpl2+)))
|