Commit | Line | Data |
---|---|---|
233e7676 | 1 | ;;; GNU Guix --- Functional package management for GNU |
4050e5d6 | 2 | ;;; Copyright © 2012, 2013 Ludovic Courtès <ludo@gnu.org> |
c44899a2 | 3 | ;;; |
233e7676 | 4 | ;;; This file is part of GNU Guix. |
c44899a2 | 5 | ;;; |
233e7676 | 6 | ;;; GNU Guix is free software; you can redistribute it and/or modify it |
c44899a2 LC |
7 | ;;; under the terms of the GNU General Public License as published by |
8 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
9 | ;;; your option) any later version. | |
10 | ;;; | |
233e7676 | 11 | ;;; GNU Guix is distributed in the hope that it will be useful, but |
c44899a2 LC |
12 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of |
13 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 | ;;; GNU General Public License for more details. | |
15 | ;;; | |
16 | ;;; You should have received a copy of the GNU General Public License | |
233e7676 | 17 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. |
c44899a2 | 18 | |
1ffa7090 | 19 | (define-module (gnu packages perl) |
4a44e743 | 20 | #:use-module (guix licenses) |
59a43334 | 21 | #:use-module (gnu packages) |
c44899a2 | 22 | #:use-module (guix packages) |
87f5d366 | 23 | #:use-module (guix download) |
c44899a2 LC |
24 | #:use-module (guix build-system gnu)) |
25 | ||
26 | (define-public perl | |
27 | ;; Yeah, Perl... It is required early in the bootstrap process by Linux. | |
28 | (package | |
29 | (name "perl") | |
30 | (version "5.16.1") | |
31 | (source (origin | |
87f5d366 | 32 | (method url-fetch) |
c44899a2 LC |
33 | (uri (string-append "http://www.cpan.org/src/5.0/perl-" |
34 | version ".tar.gz")) | |
35 | (sha256 | |
36 | (base32 | |
37 | "15qxzba3a50c9nik5ydgyfp62x7h9vxxn12yd1jgl93hb1wj96km")))) | |
38 | (build-system gnu-build-system) | |
39 | (arguments | |
12abb19d LC |
40 | '(#:tests? #f |
41 | #:patches (list (assoc-ref %build-inputs "patch/no-sys-dirs")) | |
42 | #:phases | |
43 | (alist-replace | |
44 | 'configure | |
45 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
46 | (let ((out (assoc-ref outputs "out")) | |
47 | (libc (assoc-ref inputs "libc"))) | |
48 | ;; Use the right path for `pwd'. | |
49 | (substitute* "dist/Cwd/Cwd.pm" | |
50 | (("/bin/pwd") | |
51 | (which "pwd"))) | |
c44899a2 | 52 | |
12abb19d LC |
53 | (zero? |
54 | (system* "./Configure" | |
55 | (string-append "-Dprefix=" out) | |
56 | (string-append "-Dman1dir=" out "/share/man/man1") | |
57 | (string-append "-Dman3dir=" out "/share/man/man3") | |
58 | "-de" "-Dcc=gcc" | |
59 | "-Uinstallusrbinperl" | |
60 | "-Dinstallstyle=lib/perl5" | |
61 | "-Duseshrplib" | |
62 | (string-append "-Dlocincpth=" libc "/include") | |
63 | (string-append "-Dloclibpth=" libc "/lib"))))) | |
64 | %standard-phases))) | |
c44899a2 | 65 | (inputs `(("patch/no-sys-dirs" ,(search-patch "perl-no-sys-dirs.patch")))) |
a18eda27 LC |
66 | (native-search-paths (list (search-path-specification |
67 | (variable "PERL5LIB") | |
68 | (directories '("lib/perl5/site_perl"))))) | |
c44899a2 LC |
69 | (synopsis "Implementation of the Perl programming language") |
70 | (description | |
71 | "Perl 5 is a highly capable, feature-rich programming language with over | |
72 | 24 years of development.") | |
73 | (home-page "http://www.perl.org/") | |
4a44e743 | 74 | (license gpl1+))) ; or "Artistic" |