Commit | Line | Data |
---|---|---|
233e7676 | 1 | ;;; GNU Guix --- Functional package management for GNU |
079fca3b | 2 | ;;; Copyright © 2012, 2013 Andreas Enge <andreas@enge.fr> |
9dc6f288 | 3 | ;;; |
233e7676 | 4 | ;;; This file is part of GNU Guix. |
9dc6f288 | 5 | ;;; |
233e7676 | 6 | ;;; GNU Guix is free software; you can redistribute it and/or modify it |
9dc6f288 AE |
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 |
9dc6f288 AE |
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/>. |
9dc6f288 | 18 | |
1ffa7090 | 19 | (define-module (gnu packages mit-krb5) |
59a43334 | 20 | #:use-module (gnu packages) |
1ffa7090 LC |
21 | #:use-module (gnu packages bison) |
22 | #:use-module (gnu packages perl) | |
9dc6f288 AE |
23 | #:use-module (guix licenses) |
24 | #:use-module (guix packages) | |
25 | #:use-module (guix download) | |
26 | #:use-module (guix build-system gnu)) | |
27 | ||
28 | (define-public mit-krb5 | |
29 | (package | |
30 | (name "mit-krb5") | |
31 | (version "1.11") | |
32 | (source (origin | |
33 | (method url-fetch) | |
34 | (uri (string-append "http://web.mit.edu/kerberos/www/dist/krb5/" | |
35 | version | |
36 | "/krb5-" version | |
37 | "-signed.tar")) | |
38 | (sha256 (base32 | |
39 | "0lc6lxb98qzg4x01lppq700vkr1ax9rld09znahrinwqnf9zndzy")))) | |
40 | (build-system gnu-build-system) | |
41 | (inputs `(("bison" ,bison) | |
42 | ("perl" ,perl) | |
43 | )) | |
44 | (arguments | |
12abb19d LC |
45 | '(#:phases |
46 | (alist-replace | |
47 | 'unpack | |
48 | (lambda* (#:key source #:allow-other-keys) | |
49 | (let ((inner | |
50 | (substring source | |
51 | (string-index-right source #\k) | |
52 | (string-index-right source #\-)))) | |
9dc6f288 AE |
53 | (and (zero? (system* "tar" "xvf" source)) |
54 | (zero? (system* "tar" "xvf" (string-append inner ".tar.gz"))) | |
55 | (chdir inner) | |
56 | (chdir "src")))) | |
12abb19d LC |
57 | (alist-replace |
58 | 'check | |
59 | (lambda* (#:key inputs #:allow-other-keys #:rest args) | |
60 | (let ((perl (assoc-ref inputs "perl")) | |
61 | (check (assoc-ref %standard-phases 'check))) | |
62 | (substitute* "plugins/kdb/db2/libdb2/test/run.test" | |
63 | (("/bin/cat") (string-append perl "/bin/perl"))) | |
64 | (substitute* "plugins/kdb/db2/libdb2/test/run.test" | |
65 | (("D/bin/sh") (string-append "D" (which "bash")))) | |
66 | (substitute* "plugins/kdb/db2/libdb2/test/run.test" | |
67 | (("bindir=/bin/.") (string-append "bindir=" perl "/bin"))) | |
68 | ;; use existing files and directories in test | |
69 | (substitute* "tests/resolve/Makefile" | |
70 | (("-p telnet") "-p 23")) | |
71 | ;; avoid service names since /etc/services is unavailable | |
72 | (apply check args))) | |
73 | %standard-phases)))) | |
9dc6f288 AE |
74 | (synopsis "MIT Kerberos 5") |
75 | (description | |
76 | "Massachusetts Institute of Technology implementation of Kerberos. | |
77 | Kerberos is a network authentication protocol designed to provide strong | |
78 | authentication for client/server applications by using secret-key cryptography.") | |
79 | (license (bsd-style "file://NOTICE" | |
80 | "See NOTICE in the distribution.")) | |
81 | (home-page "http://web.mit.edu/kerberos/"))) |