Commit | Line | Data |
---|---|---|
e55c1b67 | 1 | ;;; GNU Guix --- Functional package management for GNU |
aef8a9fb | 2 | ;;; Copyright © 2015, 2016, 2018 Ricardo Wurmus <rekado@elephly.net> |
8b94dffd | 3 | ;;; Copyright © 2015 Eric Bavier <bavier@member.fsf.org> |
57818b6e | 4 | ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il> |
f3eeca56 | 5 | ;;; Copyright © 2017 Chris Marusich <cmmarusich@gmail.com> |
471ce31c | 6 | ;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr> |
e55c1b67 RW |
7 | ;;; |
8 | ;;; This file is part of GNU Guix. | |
9 | ;;; | |
10 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
11 | ;;; under the terms of the GNU General Public License as published by | |
12 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
13 | ;;; your option) any later version. | |
14 | ;;; | |
15 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
16 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
17 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
18 | ;;; GNU General Public License for more details. | |
19 | ;;; | |
20 | ;;; You should have received a copy of the GNU General Public License | |
21 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
22 | ||
23 | (define-module (gnu packages gnucash) | |
c71c8b97 | 24 | #:use-module ((guix licenses) #:prefix license:) |
e55c1b67 RW |
25 | #:use-module (guix packages) |
26 | #:use-module (guix download) | |
27 | #:use-module (guix build-system gnu) | |
53e66fbc | 28 | #:use-module (guix build-system cmake) |
e55c1b67 | 29 | #:use-module (gnu packages) |
445aa137 | 30 | #:use-module (gnu packages autotools) |
53e66fbc RW |
31 | #:use-module (gnu packages boost) |
32 | #:use-module (gnu packages check) | |
33 | #:use-module (gnu packages cmake) | |
f3eeca56 CM |
34 | #:use-module (gnu packages docbook) |
35 | #:use-module (gnu packages documentation) | |
e55c1b67 | 36 | #:use-module (gnu packages gnome) |
5c881f32 | 37 | #:use-module (gnu packages gnupg) |
e55c1b67 RW |
38 | #:use-module (gnu packages glib) |
39 | #:use-module (gnu packages gtk) | |
40 | #:use-module (gnu packages guile) | |
41 | #:use-module (gnu packages icu4c) | |
445aa137 | 42 | #:use-module (gnu packages multiprecision) |
8b94dffd | 43 | #:use-module (gnu packages perl) |
e55c1b67 | 44 | #:use-module (gnu packages pkg-config) |
5c881f32 | 45 | #:use-module (gnu packages tls) |
8b94dffd | 46 | #:use-module (gnu packages web) |
e55c1b67 RW |
47 | #:use-module (gnu packages webkit) |
48 | #:use-module (gnu packages xml)) | |
49 | ||
50 | (define-public gnucash | |
51 | (package | |
52 | (name "gnucash") | |
53e66fbc | 53 | (version "3.0") |
e55c1b67 RW |
54 | (source |
55 | (origin | |
56 | (method url-fetch) | |
de67e922 | 57 | (uri (string-append "mirror://sourceforge/gnucash/gnucash%20%28stable%29/" |
5b72dafe | 58 | version "/gnucash-" version ".tar.bz2")) |
e55c1b67 RW |
59 | (sha256 |
60 | (base32 | |
53e66fbc RW |
61 | "1ffvf1rryg5yin86fnf1zvy6hnpwzrjarbdfmjmrf2mqlmv48xac")) |
62 | ||
63 | ;; TODO: rebase this patch | |
64 | ; (patches (search-patches "gnucash-price-quotes-perl.patch")) | |
65 | )) | |
66 | (build-system cmake-build-system) | |
e55c1b67 | 67 | (inputs |
53e66fbc RW |
68 | `(("guile" ,guile-2.2) |
69 | ("boost" ,boost) | |
e55c1b67 RW |
70 | ("icu4c" ,icu4c) |
71 | ("glib" ,glib) | |
53e66fbc | 72 | ("gtk" ,gtk+) |
e55c1b67 RW |
73 | ("libgnomecanvas" ,libgnomecanvas) |
74 | ("libxml2" ,libxml2) | |
75 | ("libxslt" ,libxslt) | |
53e66fbc | 76 | ("webkitgtk" ,webkitgtk) |
945939a5 | 77 | ("aqbanking" ,aqbanking) |
8b94dffd EB |
78 | ("perl-date-manip" ,perl-date-manip) |
79 | ("perl-finance-quote" ,perl-finance-quote))) | |
e55c1b67 RW |
80 | (native-inputs |
81 | `(("glib" ,glib "bin") ; glib-compile-schemas, etc. | |
82 | ("intltool" ,intltool) | |
53e66fbc RW |
83 | ("googlemock" ,(package-source googletest)) |
84 | ("googletest" ,googletest) | |
f3eeca56 | 85 | ("gnucash-docs" ,gnucash-docs) |
e55c1b67 | 86 | ("pkg-config" ,pkg-config))) |
f3eeca56 | 87 | (outputs '("out" "doc")) |
8b94dffd | 88 | (arguments |
53e66fbc RW |
89 | `(#:test-target "check" |
90 | #:configure-flags | |
91 | (list "-DWITH_OFX=OFF" ; libofx is not available yet | |
92 | "-DWITH_SQL=OFF") ; without dbi.h | |
8b94dffd EB |
93 | #:phases |
94 | (modify-phases %standard-phases | |
53e66fbc RW |
95 | (add-after 'unpack 'unpack-gmock |
96 | (lambda* (#:key inputs #:allow-other-keys) | |
97 | (mkdir "gmock") | |
98 | (invoke "tar" "xf" (assoc-ref inputs "googlemock") | |
99 | "-C" "gmock" "--strip-components=1") | |
100 | (setenv "GMOCK_ROOT" (string-append (getcwd) "/gmock/googlemock")) | |
101 | #t)) | |
f3eeca56 CM |
102 | ;; There are about 100 megabytes of documentation. |
103 | (add-after | |
104 | 'install 'install-docs | |
105 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
106 | (let ((docs (assoc-ref inputs "gnucash-docs")) | |
107 | (doc-output (assoc-ref outputs "doc"))) | |
108 | (symlink (string-append docs "/share/gnome") | |
109 | (string-append doc-output "/share/gnome"))))) | |
8b94dffd | 110 | (add-after |
f3eeca56 | 111 | 'install-docs 'wrap-programs |
8b94dffd EB |
112 | (lambda* (#:key inputs outputs #:allow-other-keys) |
113 | (for-each (lambda (prog) | |
114 | (wrap-program (string-append (assoc-ref outputs "out") | |
115 | "/bin/" prog) | |
116 | `("PERL5LIB" ":" prefix | |
117 | ,(map (lambda (o) | |
118 | (string-append o "/lib/perl5/site_perl/" | |
119 | ,(package-version perl))) | |
120 | (if (string=? prog "gnc-fq-helper") | |
121 | (list | |
122 | ,@(transitive-input-references | |
123 | 'inputs | |
124 | (map (lambda (l) | |
125 | (assoc l (inputs))) | |
126 | '("perl-finance-quote" | |
127 | "perl-date-manip")))) | |
128 | (list | |
129 | ,@(transitive-input-references | |
130 | 'inputs | |
131 | (map (lambda (l) | |
132 | (assoc l (inputs))) | |
133 | '("perl-finance-quote"))))))))) | |
134 | '("gnucash" | |
135 | "gnc-fq-check" | |
136 | "gnc-fq-helper" | |
137 | "gnc-fq-dump"))))))) | |
7c1adf00 | 138 | (home-page "https://www.gnucash.org/") |
e55c1b67 RW |
139 | (synopsis "Personal and small business financial accounting software") |
140 | (description | |
141 | "GnuCash is personal and professional financial-accounting software. | |
142 | It can be used to track bank accounts, stocks, income and expenses, based on | |
143 | the double-entry accounting practice. It includes support for QIF/OFX/HBCI | |
144 | import and transaction matching. It also automates several tasks, such as | |
145 | financial calculations or scheduled transactions.") | |
c71c8b97 | 146 | (license license:gpl3+))) |
5c881f32 | 147 | |
f3eeca56 CM |
148 | ;; This package is not public, since we use it to build the "doc" output of |
149 | ;; the gnucash package (see above). It would be confusing if it were public. | |
150 | (define gnucash-docs | |
151 | (package | |
152 | (name "gnucash-docs") | |
153 | (version (package-version gnucash)) | |
154 | (source | |
155 | (origin | |
156 | (method url-fetch) | |
157 | (uri (string-append "mirror://sourceforge/gnucash/gnucash-docs/" | |
158 | version "/gnucash-docs-" version ".tar.gz")) | |
159 | (sha256 | |
160 | (base32 | |
53e66fbc | 161 | "0yq65s3z3dwdwdf2nq1d1w9ckdjdyjwkfpmvhzyib54b66q65xh5")))) |
f3eeca56 CM |
162 | (build-system gnu-build-system) |
163 | ;; These are native-inputs because they are only required for building the | |
164 | ;; documentation. | |
165 | (native-inputs | |
166 | `(("libxml2" ,libxml2) | |
167 | ;; The "check" target needs the docbook xml packages for validating the | |
168 | ;; DocBook XML during the tests. | |
169 | ("docbook-xml-4.4" ,docbook-xml-4.4) | |
170 | ("docbook-xml-4.2" ,docbook-xml-4.2) | |
171 | ("docbook-xml-4.1.2" ,docbook-xml-4.1.2) | |
172 | ("libxslt" ,libxslt) | |
173 | ("docbook-xsl" ,docbook-xsl) | |
174 | ("scrollkeeper" ,scrollkeeper))) | |
7c1adf00 | 175 | (home-page "https://www.gnucash.org/") |
f3eeca56 CM |
176 | (synopsis "Documentation for GnuCash") |
177 | (description | |
178 | "User guide and other documentation for GnuCash in various languages. | |
179 | This package exists because the GnuCash project maintains its documentation in | |
180 | an entirely separate package from the actual GnuCash program. It is intended | |
181 | to be read using the GNOME Yelp program.") | |
182 | (license (list license:fdl1.1+ license:gpl3+)))) | |
183 | ||
5c881f32 RW |
184 | (define-public gwenhywfar |
185 | (package | |
186 | (name "gwenhywfar") | |
aef8a9fb | 187 | (version "4.20.0") |
5c881f32 RW |
188 | (source |
189 | (origin | |
190 | (method url-fetch) | |
aef8a9fb RW |
191 | (uri (string-append "https://www.aquamaniac.de/sites/download/" |
192 | "download.php?package=01&release=208&file=02&" | |
193 | "dummy=gwenhywfar-" version ".tar.gz")) | |
5c881f32 RW |
194 | (file-name (string-append name "-" version ".tar.gz")) |
195 | (sha256 | |
196 | (base32 | |
aef8a9fb | 197 | "1c0g3f8jk6j693774ifslx2ds4ksabgbbalhhm9gk20kpamxm22s")))) |
5c881f32 RW |
198 | (build-system gnu-build-system) |
199 | (arguments | |
200 | `(#:configure-flags | |
201 | (list "--disable-network-checks" | |
aef8a9fb RW |
202 | ;; GTK+3, GTK+2 and QT4 are supported. |
203 | "--with-guis=gtk3" | |
5c881f32 RW |
204 | (string-append "--with-openssl-includes=" |
205 | (assoc-ref %build-inputs "openssl") "/include") | |
206 | (string-append "--with-openssl-libs=" | |
207 | (assoc-ref %build-inputs "openssl") "/lib")))) | |
208 | (inputs | |
209 | `(("libgcrypt" ,libgcrypt) | |
210 | ("gnutls" ,gnutls) | |
211 | ("openssl" ,openssl) | |
aef8a9fb | 212 | ("gtk+" ,gtk+))) |
5c881f32 RW |
213 | (native-inputs |
214 | `(("pkg-config" ,pkg-config))) | |
215 | (home-page "http://www.aquamaniac.de/sites/aqbanking/index.php") | |
216 | (synopsis "Utility library for networking and security applications") | |
217 | (description | |
218 | "This package provides a helper library for networking and security | |
219 | applications and libraries. It is used by AqBanking.") | |
220 | ;; The license includes an explicit additional permission to compile and | |
221 | ;; distribute this library with the OpenSSL Toolkit. | |
222 | (license license:lgpl2.1+))) | |
223 | ||
445aa137 RW |
224 | (define-public aqbanking |
225 | (package | |
226 | (name "aqbanking") | |
2f5ccf27 | 227 | (version "5.7.8") |
445aa137 RW |
228 | (source |
229 | (origin | |
230 | (method url-fetch) | |
2f5ccf27 RW |
231 | (uri (string-append "https://www.aquamaniac.de/sites/download/" |
232 | "download.php?package=03&release=217&file=02&" | |
233 | "dummy=aqbanking-" version ".tar.gz")) | |
445aa137 RW |
234 | (file-name (string-append name "-" version ".tar.gz")) |
235 | (sha256 | |
236 | (base32 | |
2f5ccf27 | 237 | "0s67mysskbiw1h1p0np4ph4351r7wq3nc873vylam7lsqi66xy0n")))) |
445aa137 RW |
238 | (build-system gnu-build-system) |
239 | (arguments | |
240 | `(;; Parallel building fails because aqhbci is required before it's | |
241 | ;; built. | |
242 | #:parallel-build? #f | |
243 | #:configure-flags | |
244 | (list (string-append "--with-gwen-dir=" | |
245 | (assoc-ref %build-inputs "gwenhywfar"))))) | |
246 | (propagated-inputs | |
247 | `(("gwenhywfar" ,gwenhywfar))) | |
248 | (inputs | |
249 | `(("gmp" ,gmp) | |
250 | ("xmlsec" ,xmlsec) | |
251 | ("gnutls" ,gnutls))) | |
252 | (native-inputs | |
253 | `(("pkg-config" ,pkg-config) | |
254 | ("libltdl" ,libltdl))) | |
255 | (home-page "http://www.aquamaniac.de/sites/aqbanking/index.php") | |
256 | (synopsis "Interface for online banking tasks") | |
257 | (description | |
258 | "AqBanking is a modular and generic interface to online banking tasks, | |
259 | financial file formats (import/export) and bank/country/currency information. | |
260 | AqBanking uses backend plugins to actually perform the online tasks. HBCI, | |
261 | OFX DirectConnect, YellowNet, GeldKarte, and DTAUS discs are currently | |
262 | supported. AqBanking is used by GnuCash, KMyMoney, and QBankManager.") | |
263 | ;; AqBanking is licensed under the GPLv2 or GPLv3 | |
264 | (license (list license:gpl2 license:gpl3)))) |