| 1 | ;;; GNU Guix --- Functional package management for GNU |
| 2 | ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com> |
| 3 | ;;; Copyright © 2014, 2015, 2018 Mark H Weaver <mhw@netris.org> |
| 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 | |
| 20 | (define-module (gnu packages apr) |
| 21 | #:use-module ((guix licenses) #:prefix l:) |
| 22 | #:use-module (guix packages) |
| 23 | #:use-module (guix download) |
| 24 | #:use-module (guix build-system gnu) |
| 25 | #:use-module (gnu packages) |
| 26 | #:use-module (gnu packages perl) |
| 27 | #:use-module (gnu packages xml) |
| 28 | #:use-module (gnu packages autotools)) |
| 29 | |
| 30 | (define-public apr |
| 31 | (package |
| 32 | (name "apr") |
| 33 | (version "1.6.5") |
| 34 | (source (origin |
| 35 | (method url-fetch) |
| 36 | (uri (string-append "mirror://apache/apr/apr-" |
| 37 | version ".tar.bz2")) |
| 38 | (sha256 |
| 39 | (base32 |
| 40 | "01d1n1ql66bxsjx0wyzazmkqdqdmr0is6a7lwyy5kzy4z7yajz56")) |
| 41 | (patches |
| 42 | (search-patches "apr-skip-getservbyname-test.patch")) |
| 43 | (patch-flags '("-p0")))) |
| 44 | (build-system gnu-build-system) |
| 45 | (arguments |
| 46 | ;; Sometimes we end up with two processes concurrently trying to make |
| 47 | ;; 'libmod_test.la': <http://hydra.gnu.org/build/60266/nixlog/2/raw>. |
| 48 | ;; Thus, build sequentially. |
| 49 | '(#:parallel-build? #f |
| 50 | #:parallel-tests? #f)) |
| 51 | (inputs `(("perl" ,perl) |
| 52 | ("libltdl" ,libltdl))) |
| 53 | (home-page "http://apr.apache.org/") |
| 54 | (synopsis "The Apache Portable Runtime Library") |
| 55 | (description |
| 56 | "The mission of the Apache Portable Runtime (APR) project is to create and |
| 57 | maintain software libraries that provide a predictable and consistent interface |
| 58 | to underlying platform-specific implementations. The primary goal is to provide |
| 59 | an API to which software developers may code and be assured of predictable if |
| 60 | not identical behaviour regardless of the platform on which their software is |
| 61 | built, relieving them of the need to code special-case conditions to work |
| 62 | around or take advantage of platform-specific deficiencies or features.") |
| 63 | (license l:asl2.0))) |
| 64 | |
| 65 | (define-public apr-util |
| 66 | (package |
| 67 | (name "apr-util") |
| 68 | (version "1.6.1") |
| 69 | (source (origin |
| 70 | (method url-fetch) |
| 71 | (uri (string-append "mirror://apache/apr/apr-util-" |
| 72 | version ".tar.bz2")) |
| 73 | (sha256 |
| 74 | (base32 |
| 75 | "0nq3s1yn13vplgl6qfm09f7n0wm08malff9s59bqf9nid9xjzqfk")))) |
| 76 | (build-system gnu-build-system) |
| 77 | (inputs |
| 78 | `(("apr" ,apr))) |
| 79 | (propagated-inputs |
| 80 | `(("expat" ,expat))) |
| 81 | (arguments |
| 82 | '(#:phases |
| 83 | (modify-phases %standard-phases |
| 84 | (replace 'configure |
| 85 | (lambda* (#:key inputs outputs #:allow-other-keys) |
| 86 | (let ((out (assoc-ref outputs "out")) |
| 87 | (apr (assoc-ref inputs "apr")) |
| 88 | (expat (assoc-ref inputs "expat"))) |
| 89 | (setenv "CONFIG_SHELL" (which "bash")) |
| 90 | (invoke "./configure" |
| 91 | (string-append "--prefix=" out) |
| 92 | (string-append "--with-apr=" apr) |
| 93 | (string-append "--with-expat=" expat)))))) |
| 94 | |
| 95 | ;; There are race conditions during 'make check'. Typically, the |
| 96 | ;; 'testall' executable is not built yet by the time 'make check' tries |
| 97 | ;; to run it. See |
| 98 | ;; <http://lists.gnu.org/archive/html/guix-devel/2014-03/msg00261.html>. |
| 99 | #:parallel-tests? #f)) |
| 100 | (home-page "http://apr.apache.org/") |
| 101 | (synopsis "One of the Apache Portable Runtime Library companions") |
| 102 | (description |
| 103 | "APR-util provides a number of helpful abstractions on top of APR.") |
| 104 | (license l:asl2.0))) |