gnu: rust: Accept more detailed gdb responses.
[jackhill/guix/guix.git] / gnu / packages / pcre.scm
CommitLineData
10d1822b
AE
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2013 Andreas Enge <andreas@enge.fr>
fd19fa55 3;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
7ea3099b 4;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
ccda7c83 5;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
9bb766e7 6;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com>
a97f0ee1 7;;; Copyright © 2017 Ludovic Courtès <ludo@gnu.org>
0b7f9806 8;;; Copyright © 2017 Efraim Flashner <efraim@flashner.co.il>
8297ff0f 9;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
10d1822b
AE
10;;;
11;;; This file is part of GNU Guix.
12;;;
13;;; GNU Guix is free software; you can redistribute it and/or modify it
14;;; under the terms of the GNU General Public License as published by
15;;; the Free Software Foundation; either version 3 of the License, or (at
16;;; your option) any later version.
17;;;
18;;; GNU Guix is distributed in the hope that it will be useful, but
19;;; WITHOUT ANY WARRANTY; without even the implied warranty of
20;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21;;; GNU General Public License for more details.
22;;;
23;;; You should have received a copy of the GNU General Public License
24;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
25
26(define-module (gnu packages pcre)
b5b73a82 27 #:use-module ((guix licenses) #:prefix license:)
10d1822b
AE
28 #:use-module (gnu packages compression)
29 #:use-module (gnu packages readline)
d46dd72c 30 #:use-module (gnu packages)
10d1822b
AE
31 #:use-module (guix packages)
32 #:use-module (guix download)
33 #:use-module (guix build-system gnu))
34
35(define-public pcre
36 (package
37 (name "pcre")
0b7f9806 38 (version "8.41")
10d1822b
AE
39 (source (origin
40 (method url-fetch)
dae36ca5
MW
41 (uri (list
42 (string-append "ftp://ftp.csx.cam.ac.uk"
43 "/pub/software/programming/pcre/"
44 "pcre-" version ".tar.bz2")
45 (string-append "mirror://sourceforge/pcre/pcre/"
46 version "/pcre-" version ".tar.bz2")))
10d1822b
AE
47 (sha256
48 (base32
0b7f9806 49 "0c5m469p5pd7jip621ipq6hbgh7128lzh7xndllfgh77ban7wb76"))))
10d1822b 50 (build-system gnu-build-system)
6d49ca3b
LC
51 (outputs '("out" ;library & headers
52 "bin" ;depends on Readline (adds 20MiB to the closure)
53 "doc")) ;1.8 MiB of HTML
10d1822b
AE
54 (inputs `(("bzip2" ,bzip2)
55 ("readline" ,readline)
56 ("zlib" ,zlib)))
57 (arguments
d786d2f8
LC
58 '(#:disallowed-references ("doc")
59 #:configure-flags '("--enable-utf"
10d1822b
AE
60 "--enable-pcregrep-libz"
61 "--enable-pcregrep-libbz2"
90dcf9c8 62 "--enable-pcretest-libreadline"
16f71908
MW
63 "--enable-unicode-properties"
64 "--enable-pcre16"
65 "--enable-pcre32"
90dcf9c8 66 "--enable-jit")))
35b9e423 67 (synopsis "Perl Compatible Regular Expressions")
10d1822b
AE
68 (description
69 "The PCRE library is a set of functions that implement regular expression
35b9e423 70pattern matching using the same syntax and semantics as Perl 5. PCRE has its
10d1822b
AE
71own native API, as well as a set of wrapper functions that correspond to the
72POSIX regular expression API.")
73 (license license:bsd-3)
265c31f5 74 (home-page "https://www.pcre.org/")))
7ea3099b
RW
75
76(define-public pcre2
77 (package
78 (name "pcre2")
8297ff0f 79 (version "10.31")
7ea3099b
RW
80 (source (origin
81 (method url-fetch)
82 (uri (string-append "mirror://sourceforge/pcre/pcre2/"
83 version "/pcre2-" version ".tar.bz2"))
84
85 (sha256
86 (base32
8297ff0f 87 "1b389pzw91k1hzydsh4smdsxyppwz4pv74m3nrvy8rda0j3m6zg0"))))
7ea3099b
RW
88 (build-system gnu-build-system)
89 (inputs `(("bzip2" ,bzip2)
90 ("readline" ,readline)
91 ("zlib" ,zlib)))
92 (arguments
93 `(#:configure-flags '("--enable-unicode"
af6e2385
LF
94 "--enable-pcre2grep-libz"
95 "--enable-pcre2grep-libbz2"
96 "--enable-pcre2test-libreadline"
7ea3099b
RW
97 "--enable-pcre2-16"
98 "--enable-pcre2-32"
9bb766e7
MB
99 "--enable-jit")
100 #:phases
101 (modify-phases %standard-phases
102 (add-after 'unpack 'patch-paths
103 (lambda _
104 (substitute* "RunGrepTest"
105 (("/bin/echo") (which "echo")))
106 #t)))))
7ea3099b
RW
107 (synopsis "Perl Compatible Regular Expressions")
108 (description
109 "The PCRE library is a set of functions that implement regular expression
110pattern matching using the same syntax and semantics as Perl 5. PCRE has its
111own native API, as well as a set of wrapper functions that correspond to the
112POSIX regular expression API.")
113 (license license:bsd-3)
265c31f5 114 (home-page "https://www.pcre.org/")))