Commit | Line | Data |
---|---|---|
c0798488 | 1 | ;;; GNU Guix --- Functional package management for GNU |
4bb49be2 | 2 | ;;; Copyright © 2013, 2014, 2015 Andreas Enge <andreas@enge.fr> |
3c972f53 | 3 | ;;; Copyright © 2015, 2016 Ricardo Wurmus <rekado@elephly.net> |
c0798488 AE |
4 | ;;; |
5 | ;;; This file is part of GNU Guix. | |
6 | ;;; | |
7 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
8 | ;;; under the terms of the GNU General Public License as published by | |
9 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
10 | ;;; your option) any later version. | |
11 | ;;; | |
12 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
13 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 | ;;; GNU General Public License for more details. | |
16 | ;;; | |
17 | ;;; You should have received a copy of the GNU General Public License | |
18 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
19 | ||
07cec9a5 | 20 | (define-module (gnu packages rdf) |
4bb49be2 | 21 | #:use-module ((guix licenses) |
dbbb45dd | 22 | #:select (non-copyleft isc gpl2 lgpl2.1 lgpl2.1+)) |
c0798488 AE |
23 | #:use-module (guix packages) |
24 | #:use-module (guix download) | |
25 | #:use-module (guix build-system cmake) | |
2c4e4d25 | 26 | #:use-module (guix build-system gnu) |
4bb49be2 | 27 | #:use-module (guix build-system python) |
f65784d5 | 28 | #:use-module (guix build-system waf) |
7051054a | 29 | #:use-module (gnu packages) |
bfe26beb | 30 | #:use-module (gnu packages autotools) |
5f96f303 | 31 | #:use-module (gnu packages databases) |
8a79ec41 | 32 | #:use-module (gnu packages boost) |
ac257f12 | 33 | #:use-module (gnu packages check) |
2c4e4d25 AE |
34 | #:use-module (gnu packages compression) |
35 | #:use-module (gnu packages curl) | |
bfe26beb | 36 | #:use-module (gnu packages cyrus-sasl) |
99828fa7 | 37 | #:use-module (gnu packages documentation) |
1634c042 AE |
38 | #:use-module (gnu packages gnupg) |
39 | #:use-module (gnu packages linux) | |
40 | #:use-module (gnu packages multiprecision) | |
41 | #:use-module (gnu packages pcre) | |
42 | #:use-module (gnu packages perl) | |
c0798488 | 43 | #:use-module (gnu packages pkg-config) |
4bb49be2 | 44 | #:use-module (gnu packages python) |
1b2f753d | 45 | #:use-module (gnu packages python-web) |
2c4e4d25 | 46 | #:use-module (gnu packages qt) |
33dc54b0 | 47 | #:use-module (gnu packages time) |
cc2b77df | 48 | #:use-module (gnu packages tls) |
2c4e4d25 AE |
49 | #:use-module (gnu packages xml)) |
50 | ||
51 | (define-public raptor2 | |
52 | (package | |
53 | (name "raptor2") | |
f4ee08d8 | 54 | (version "2.0.15") |
2c4e4d25 AE |
55 | (source (origin |
56 | (method url-fetch) | |
57 | (uri (string-append "http://download.librdf.org/source/" name | |
58 | "-" version ".tar.gz")) | |
099c9fda MB |
59 | (patches |
60 | (search-patches "raptor2-heap-overflow.patch")) | |
2c4e4d25 AE |
61 | (sha256 |
62 | (base32 | |
f4ee08d8 | 63 | "1vc02im4mpc28zxzgli68k6j0dakh0k3s389bm436yvqajxg19xd")))) |
2c4e4d25 AE |
64 | (build-system gnu-build-system) |
65 | (inputs | |
66 | `(("curl" ,curl) | |
67 | ("libxml2" ,libxml2) | |
68 | ("libxslt" ,libxslt) | |
69 | ("zlib" ,zlib))) | |
0e6260a4 AE |
70 | (arguments |
71 | `(#:parallel-tests? #f)) | |
2c4e4d25 AE |
72 | (home-page "http://librdf.org/raptor/") |
73 | (synopsis "RDF syntax library") | |
74 | (description "Raptor is a C library providing a set of parsers and | |
75 | serialisers that generate Resource Description Framework (RDF) triples | |
76 | by parsing syntaxes or serialise the triples into a syntax. The supported | |
77 | parsing syntaxes are RDF/XML, N-Quads, N-Triples 1.0 and 1.1, TRiG, | |
78 | Turtle 2008 and 2013, RDFa 1.0 and 1.1, RSS tag soup including all versions | |
79 | of RSS, Atom 1.0 and 0.3, GRDDL and microformats for HTML, XHTML and | |
80 | XML. The serialising syntaxes are RDF/XML (regular, abbreviated, XMP), | |
81 | Turtle 2013, N-Quads, N-Triples 1.1, Atom 1.0, RSS 1.0, GraphViz DOT, | |
82 | HTML and JSON.") | |
83 | (license lgpl2.1+))) ; or any choice of gpl2+ or asl2.0 | |
c0798488 | 84 | |
8a79ec41 AE |
85 | (define-public clucene |
86 | (package | |
87 | (name "clucene") | |
88 | (version "2.3.3.4") | |
89 | (source (origin | |
90 | (method url-fetch) | |
91 | (uri (string-append "mirror://sourceforge/clucene/" | |
92 | "clucene-core-unstable/2.3/clucene-core-" | |
93 | version ".tar.gz")) | |
94 | (sha256 | |
95 | (base32 | |
7051054a | 96 | "1arffdwivig88kkx685pldr784njm0249k0rb1f1plwavlrw9zfx")) |
fc1adab1 AK |
97 | (patches (search-patches "clucene-pkgconfig.patch" |
98 | "clucene-contribs-lib.patch")))) | |
8a79ec41 AE |
99 | (build-system cmake-build-system) |
100 | (inputs | |
101 | `(("boost" ,boost) ; could also use bundled copy | |
102 | ("zlib" ,zlib))) | |
103 | (arguments | |
104 | `(#:test-target "cl_test" | |
80059f54 | 105 | #:configure-flags '("-DBUILD_CONTRIBS_LIB=ON") |
8a79ec41 AE |
106 | #:tests? #f)) ; Tests do not compile, as TestIndexSearcher.cpp uses |
107 | ; undeclared usleep. After fixing this, one needs to run | |
108 | ; "make test" in addition to "make cl_test", then | |
109 | ; SimpleTest fails. | |
110 | ; Notice that the library appears to be unmaintained | |
111 | ; with no reaction to bug reports. | |
112 | (home-page "http://clucene.sourceforge.net/") | |
113 | (synopsis "C text indexing and searching library") | |
114 | (description "CLucene is a high-performance, scalable, cross platform, | |
115 | full-featured indexing and searching API. It is a port of the very popular | |
116 | Java Lucene text search engine API to C++.") | |
117 | (license lgpl2.1))) | |
118 | ||
bfe26beb RW |
119 | (define-public lrdf |
120 | (package | |
121 | (name "lrdf") | |
122 | (version "0.5.0") | |
123 | (source (origin | |
124 | (method url-fetch) | |
125 | (uri (string-append "https://github.com/swh/LRDF/archive/" | |
126 | version ".tar.gz")) | |
f586c877 | 127 | (file-name (string-append name "-" version ".tar.gz")) |
bfe26beb RW |
128 | (sha256 |
129 | (base32 | |
130 | "18p2flb2sv2hq6w2qkd29z9c7knnwqr3f12i2srshlzx6vwkm05s")))) | |
131 | (build-system gnu-build-system) | |
132 | (arguments | |
dc1d3cde KK |
133 | '(#:phases |
134 | (modify-phases %standard-phases | |
dc1d3cde KK |
135 | (add-after 'unpack 'remove-out-of-tree-references |
136 | (lambda _ | |
137 | ;; remove symlinks to files in /usr/ | |
138 | (delete-file-recursively "m4") | |
139 | (for-each delete-file '("config.guess" | |
140 | "config.sub" | |
141 | "depcomp" | |
142 | "install-sh" | |
143 | "ltmain.sh" | |
144 | "missing")) | |
145 | ;; remove_test depends on an out-of-tree RDF file | |
146 | (substitute* "examples/Makefile.am" | |
147 | (("instances_test remove_test") "instances_test") | |
148 | (("\\$\\(TESTS\\) remove_test") "$(TESTS)")) | |
4f27a333 MB |
149 | #t)) |
150 | (add-after 'remove-out-of-tree-references 'autoreconf | |
151 | (lambda _ | |
152 | (zero? (system* "autoreconf" "-vfi"))))))) | |
bfe26beb RW |
153 | (inputs |
154 | `(("raptor" ,raptor2) | |
155 | ("cyrus-sasl" ,cyrus-sasl) | |
156 | ("openssl" ,openssl) | |
157 | ("zlib" ,zlib))) | |
158 | (native-inputs | |
159 | `(("autoconf" ,autoconf) | |
160 | ("automake" ,automake) | |
161 | ("libtool" ,libtool) | |
162 | ("pkg-config" ,pkg-config))) | |
163 | (home-page "https://github.com/swh/LRDF") | |
164 | (synopsis "Lightweight RDF library for accessing LADSPA plugin metadata") | |
165 | (description | |
166 | "LRDF is a library to make it easy to manipulate RDF files describing | |
167 | LADSPA plugins. It can also be used for general RDF manipulation. It can | |
168 | read RDF/XLM and N3 files and export N3 files, and it also has a light | |
e881752c | 169 | taxonomic inference capability.") |
bfe26beb RW |
170 | (license gpl2))) |
171 | ||
1634c042 AE |
172 | (define-public rasqal |
173 | (package | |
174 | (name "rasqal") | |
ca1071e1 | 175 | (version "0.9.33") |
1634c042 AE |
176 | (source (origin |
177 | (method url-fetch) | |
178 | (uri (string-append "http://download.librdf.org/source/" name | |
179 | "-" version ".tar.gz")) | |
180 | (sha256 | |
181 | (base32 | |
ca1071e1 | 182 | "0z6rrwn4jsagvarg8d5zf0j352kjgi33py39jqd29gbhcnncj939")))) |
1634c042 AE |
183 | (build-system gnu-build-system) |
184 | (native-inputs | |
185 | `(("perl" ,perl) | |
186 | ("perl-xml-dom" ,perl-xml-dom) ; for the tests | |
187 | ("pkg-config" ,pkg-config))) | |
188 | (inputs | |
189 | `(("libgcrypt" ,libgcrypt) | |
190 | ("libxml2" ,libxml2) | |
191 | ("mpfr" ,mpfr) | |
192 | ("pcre" ,pcre) | |
1634c042 | 193 | ("util-linux" ,util-linux))) |
85d83c3b AE |
194 | (propagated-inputs |
195 | `(("raptor2" ,raptor2))) ; stipulated by rasqal.pc | |
1634c042 AE |
196 | (arguments |
197 | `(#:parallel-tests? #f | |
198 | ; test failure reported upstream, see | |
199 | ; http://bugs.librdf.org/mantis/view.php?id=571 | |
200 | #:tests? #f)) | |
201 | (home-page "http://librdf.org/rasqal/") | |
202 | (synopsis "RDF query library") | |
203 | (description "Rasqal is a C library that handles Resource Description | |
204 | Framework (RDF) query language syntaxes, query construction and execution | |
205 | of queries returning results as bindings, boolean, RDF graphs/triples or | |
206 | syntaxes. The supported query languages are SPARQL Query 1.0, | |
207 | SPARQL Query 1.1, SPARQL Update 1.1 (no executing) and the Experimental | |
208 | SPARQL extensions (LAQRS). Rasqal can write binding query results in the | |
209 | SPARQL XML, SPARQL JSON, CSV, TSV, HTML, ASCII tables, RDF/XML and | |
af6fce0f AE |
210 | Turtle/N3 and read them in SPARQL XML, RDF/XML and Turtle/N3.") |
211 | (license lgpl2.1+))) ; or any choice of gpl2+ or asl2.0 | |
212 | ||
213 | (define-public redland | |
214 | (package | |
215 | (name "redland") | |
216 | (version "1.0.17") | |
217 | (source (origin | |
218 | (method url-fetch) | |
219 | (uri (string-append "http://download.librdf.org/source/" name | |
220 | "-" version ".tar.gz")) | |
221 | (sha256 | |
222 | (base32 | |
223 | "109n0kp39p966dpiasad2bb7q66rwbcb9avjvimw28chnpvlf66y")))) | |
224 | (build-system gnu-build-system) | |
225 | (native-inputs | |
226 | `(("perl" ,perl) ; needed for installation | |
227 | ("pkg-config" ,pkg-config))) | |
0390a520 AE |
228 | (propagated-inputs |
229 | `(("rasqal" ,rasqal))) ; in Requires.private field of .pc | |
af6fce0f | 230 | (inputs |
0390a520 | 231 | `(("bdb" ,bdb))) |
af6fce0f AE |
232 | (home-page "http://librdf.org/") |
233 | (synopsis "RDF library") | |
234 | (description "The Redland RDF Library (librdf) provides the RDF API | |
235 | and triple stores.") | |
1634c042 AE |
236 | (license lgpl2.1+))) ; or any choice of gpl2+ or asl2.0 |
237 | ||
f65784d5 RW |
238 | (define-public serd |
239 | (package | |
240 | (name "serd") | |
7421467a | 241 | (version "0.26.0") |
f65784d5 RW |
242 | (source (origin |
243 | (method url-fetch) | |
244 | (uri (string-append "http://download.drobilla.net/serd-" | |
7421467a | 245 | version ".tar.bz2")) |
f65784d5 RW |
246 | (sha256 |
247 | (base32 | |
7421467a | 248 | "164j43am4hka2vbzw4n52zy7rafgp6kmkgbcbvap368az644mr73")))) |
f65784d5 | 249 | (build-system waf-build-system) |
90ea9863 TUBK |
250 | (arguments |
251 | `(#:tests? #f ; no check target | |
252 | #:phases | |
253 | (modify-phases %standard-phases | |
254 | (add-before | |
255 | 'configure 'set-ldflags | |
256 | (lambda* (#:key outputs #:allow-other-keys) | |
257 | (setenv "LDFLAGS" | |
258 | (string-append "-Wl,-rpath=" | |
259 | (assoc-ref outputs "out") "/lib"))))))) | |
f65784d5 RW |
260 | (home-page "http://drobilla.net/software/serd/") |
261 | (synopsis "Library for RDF syntax supporting Turtle and NTriples") | |
262 | (description | |
263 | "Serd is a lightweight C library for RDF syntax which supports reading | |
264 | and writing Turtle and NTriples. Serd is not intended to be a swiss-army | |
265 | knife of RDF syntax, but rather is suited to resource limited or performance | |
266 | critical applications (e.g. converting many gigabytes of NTriples to Turtle), | |
267 | or situations where a simple reader/writer with minimal dependencies is | |
268 | ideal (e.g. in LV2 implementations or embedded applications).") | |
269 | (license isc))) | |
270 | ||
a035e6ff RW |
271 | (define-public sord |
272 | (package | |
273 | (name "sord") | |
a1d419c7 | 274 | (version "0.16.0") |
a035e6ff RW |
275 | (source (origin |
276 | (method url-fetch) | |
277 | (uri (string-append "http://download.drobilla.net/sord-" | |
a1d419c7 | 278 | version ".tar.bz2")) |
a035e6ff RW |
279 | (sha256 |
280 | (base32 | |
a1d419c7 | 281 | "0nh3i867g9z4kdlnk82cg2kcw8r02qgifxvkycvzb4vfjv4v4g4x")))) |
a035e6ff | 282 | (build-system waf-build-system) |
7e81a761 TUBK |
283 | (arguments |
284 | `(#:tests? #f ; no check target | |
285 | #:phases | |
286 | (modify-phases %standard-phases | |
287 | (add-before | |
288 | 'configure 'set-ldflags | |
289 | (lambda* (#:key outputs #:allow-other-keys) | |
290 | (setenv "LDFLAGS" | |
291 | (string-append "-Wl,-rpath=" | |
292 | (assoc-ref outputs "out") "/lib"))))))) | |
a035e6ff RW |
293 | (inputs |
294 | `(("serd" ,serd))) | |
295 | (native-inputs | |
296 | `(("pkg-config" ,pkg-config))) | |
297 | (home-page "http://drobilla.net/software/sord/") | |
298 | (synopsis "C library for storing RDF data in memory") | |
299 | (description | |
300 | "Sord is a lightweight C library for storing RDF data in memory.") | |
301 | (license isc))) | |
302 | ||
4bb49be2 AE |
303 | (define-public python-rdflib |
304 | (package | |
305 | (name "python-rdflib") | |
306 | (version "4.1.2") | |
307 | (source | |
308 | (origin | |
309 | (method url-fetch) | |
310 | (uri (string-append | |
311 | "https://pypi.python.org/packages/source/r/rdflib/rdflib-" | |
312 | version | |
313 | ".tar.gz")) | |
da71f145 AE |
314 | (patches |
315 | ;; The patch has no effect under Python 3. | |
fc1adab1 | 316 | (search-patches "python2-rdflib-drop-sparqlwrapper.patch")) |
4bb49be2 AE |
317 | (sha256 |
318 | (base32 | |
319 | "0kvaf332cqbi47rqzlpdx4mbkvw12mkrzkj8n9l19wk713d4py9w")))) | |
320 | (build-system python-build-system) | |
ee472241 MB |
321 | (arguments |
322 | '(;; FIXME: Three test failures. Try uncommenting the below next update. | |
323 | #:tests? #f)) | |
324 | ;; #:phases | |
325 | ;; (modify-phases %standard-phases | |
326 | ;; (replace 'check | |
327 | ;; (lambda _ | |
328 | ;; ;; Run tests from the build directory so python3 only | |
329 | ;; ;; sees the installed 2to3 version. | |
330 | ;; (zero? (system* "nosetests" "--where=./build/src"))))) | |
331 | (native-inputs | |
332 | `(("python-nose" ,python-nose))) | |
f22efa01 | 333 | (propagated-inputs |
4219f48f | 334 | `(("python-html5lib" ,python-html5lib) |
4bb49be2 | 335 | ("python-isodate" ,python-isodate) |
f3b98f4f | 336 | ("python-pyparsing" ,python-pyparsing))) |
4bb49be2 AE |
337 | (home-page "https://github.com/RDFLib/rdflib") |
338 | (synopsis | |
339 | "Python RDF library") | |
340 | (description | |
341 | "RDFLib is a Python library for working with RDF, a simple yet | |
342 | powerful language for representing information.") | |
166191b3 | 343 | (license (non-copyleft "file://LICENSE" |
4bb49be2 | 344 | "See LICENSE in the distribution.")))) |
da71f145 AE |
345 | |
346 | (define-public python2-rdflib | |
ee472241 | 347 | (package-with-python2 python-rdflib)) |