Commit | Line | Data |
---|---|---|
4c9e7975 AE |
1 | ;;; GNU Guix --- Functional package management for GNU |
2 | ;;; Copyright © 2013 Andreas Enge <andreas@enge.fr> | |
93cb98d4 | 3 | ;;; Copyright © 2015, 2016 Mark H Weaver <mhw@netris.org> |
4e080fbb | 4 | ;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il> |
a408e757 | 5 | ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org> |
1d4234d4 | 6 | ;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net> |
4c9e7975 AE |
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 | ||
1ffa7090 | 23 | (define-module (gnu packages icu4c) |
59a43334 | 24 | #:use-module (gnu packages) |
1ffa7090 | 25 | #:use-module (gnu packages perl) |
4c9e7975 AE |
26 | #:use-module (guix licenses) |
27 | #:use-module (guix packages) | |
28 | #:use-module (guix download) | |
1d4234d4 | 29 | #:use-module (guix build-system ant) |
4c9e7975 AE |
30 | #:use-module (guix build-system gnu)) |
31 | ||
32 | (define-public icu4c | |
33 | (package | |
34 | (name "icu4c") | |
c3c7e094 | 35 | (version "63.1") |
4c9e7975 AE |
36 | (source (origin |
37 | (method url-fetch) | |
d5df6fc7 | 38 | (uri (string-append |
5499de02 | 39 | "http://download.icu-project.org/files/icu4c/" |
d5df6fc7 AW |
40 | version |
41 | "/icu4c-" | |
42 | (string-map (lambda (x) (if (char=? x #\.) #\_ x)) version) | |
43 | "-src.tgz")) | |
1319cfe9 | 44 | (sha256 |
c3c7e094 | 45 | (base32 "17fbk0lm2clsxbmjzvyp245ayx0n4chji3ky1f3fbz2ljjv91i05")))) |
4c9e7975 | 46 | (build-system gnu-build-system) |
a2270ce2 | 47 | (inputs |
0d93648b | 48 | `(("perl" ,perl))) |
4c9e7975 | 49 | (arguments |
0d93648b MW |
50 | `(#:configure-flags |
51 | '("--enable-rpath" | |
93cb98d4 MW |
52 | ,@(if (let ((s (or (%current-target-system) |
53 | (%current-system)))) | |
54 | (or (string-prefix? "arm" s) | |
55 | (string-prefix? "mips" s))) | |
0d93648b MW |
56 | '("--with-data-packaging=archive") |
57 | '())) | |
e65b2181 MB |
58 | ,@(if (string-prefix? "i686" (or (%current-target-system) |
59 | (%current-system))) | |
60 | ;; FIXME: Some tests are failing on i686: | |
61 | ;; <https://unicode-org.atlassian.net/browse/ICU-20080>. | |
62 | '(#:tests? #f) | |
63 | '()) | |
a2270ce2 | 64 | #:phases |
c296d5d1 EF |
65 | (modify-phases %standard-phases |
66 | (add-after 'unpack 'chdir-to-source | |
fbd2b8da MB |
67 | (lambda _ (chdir "source") #t)) |
68 | (add-after 'install 'avoid-coreutils-reference | |
69 | ;; Don't keep a reference to the build tools. | |
70 | (lambda* (#:key outputs #:allow-other-keys) | |
71 | (let ((out (assoc-ref outputs "out"))) | |
72 | (substitute* (find-files (string-append out "/lib/icu") | |
73 | "\\.inc$") | |
74 | (("INSTALL_CMD=.*/bin/install") "INSTALL_CMD=install")) | |
75 | #t)))))) | |
35b9e423 | 76 | (synopsis "International Components for Unicode") |
4c9e7975 AE |
77 | (description |
78 | "ICU is a set of C/C++ and Java libraries providing Unicode and | |
35b9e423 | 79 | globalisation support for software applications. This package contains the |
4c9e7975 AE |
80 | C/C++ part.") |
81 | (license x11) | |
82 | (home-page "http://site.icu-project.org/"))) | |
a408e757 | 83 | |
1d4234d4 RW |
84 | (define-public java-icu4j |
85 | (package | |
86 | (name "java-icu4j") | |
87 | (version "59.1") | |
88 | (source (origin | |
89 | (method url-fetch) | |
90 | (uri (string-append "http://download.icu-project.org/files/icu4j/" | |
91 | version "/icu4j-" | |
92 | (string-map (lambda (x) | |
93 | (if (char=? x #\.) #\_ x)) | |
94 | version) | |
95 | "-src.jar")) | |
96 | (sha256 | |
97 | (base32 | |
98 | "0bgxsvgi0qcwj60pvcxrf7a3fbk7aksyxnfwpbzavyfrfzixqh0c")))) | |
99 | (build-system ant-build-system) | |
100 | (arguments | |
101 | `(#:tests? #f ; no tests included | |
102 | #:jar-name "icu4j.jar")) | |
103 | (home-page "http://site.icu-project.org/") | |
104 | (synopsis "International Components for Unicode") | |
105 | (description | |
106 | "ICU is a set of C/C++ and Java libraries providing Unicode and | |
107 | globalisation support for software applications. This package contains the | |
108 | Java part.") | |
109 | (license x11))) |