Commit | Line | Data |
---|---|---|
342005e7 LC |
1 | ;;; GNU Guix --- Functional package management for GNU |
2 | ;;; Copyright © 2014 Ludovic Courtès <ludo@gnu.org> | |
e73a016d | 3 | ;;; Copyright © 2015, 2016, 2018, 2020 Efraim Flashner <efraim@flashner.co.il> |
e2931e99 | 4 | ;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net> |
c1cb85bf | 5 | ;;; Copyright © 2019 Marius Bakke <mbakke@fastmail.com> |
342005e7 LC |
6 | ;;; |
7 | ;;; This file is part of GNU Guix. | |
8 | ;;; | |
9 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
10 | ;;; under the terms of the GNU General Public License as published by | |
11 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
12 | ;;; your option) any later version. | |
13 | ;;; | |
14 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
15 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
16 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
17 | ;;; GNU General Public License for more details. | |
18 | ;;; | |
19 | ;;; You should have received a copy of the GNU General Public License | |
20 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
21 | ||
22 | (define-module (gnu packages adns) | |
23 | #:use-module (guix licenses) | |
24 | #:use-module (guix packages) | |
25 | #:use-module (guix download) | |
e2931e99 | 26 | #:use-module (guix build-system cmake) |
cd44f1c1 | 27 | #:use-module (guix build-system gnu) |
e73a016d | 28 | #:use-module (gnu packages m4) |
cd44f1c1 | 29 | #:use-module (gnu packages pkg-config)) |
342005e7 LC |
30 | |
31 | (define-public adns | |
32 | (package | |
33 | (name "adns") | |
e73a016d | 34 | (version "1.6.0") |
342005e7 LC |
35 | (source (origin |
36 | (method url-fetch) | |
37 | (uri (list (string-append "mirror://gnu/adns/adns-" | |
38 | version ".tar.gz") | |
39 | (string-append | |
e73a016d EF |
40 | "https://www.chiark.greenend.org.uk/~ian/adns/ftp/adns-" |
41 | version ".tar.gz"))) | |
342005e7 LC |
42 | (sha256 |
43 | (base32 | |
e73a016d | 44 | "1pi0xl07pav4zm2jrbrfpv43s1r1q1y12awgak8k7q41m5jp4hpv")))) |
342005e7 LC |
45 | (build-system gnu-build-system) |
46 | (arguments | |
47 | ;; Make sure the programs under bin/ fine libadns.so. | |
48 | '(#:configure-flags (list (string-append "LDFLAGS=-Wl,-rpath -Wl," | |
49 | (assoc-ref %outputs "out") | |
50 | "/lib")) | |
51 | ||
52 | ;; XXX: Tests expect real name resolution to work. | |
53 | #:tests? #f)) | |
e73a016d EF |
54 | (native-inputs |
55 | `(("m4" ,m4))) | |
6fd52309 | 56 | (home-page "https://www.gnu.org/software/adns/") |
342005e7 LC |
57 | (synopsis "Asynchronous DNS client library and utilities") |
58 | (description | |
59 | "GNU adns is a C library that provides easy-to-use DNS resolution | |
60 | functionality. The library is asynchronous, allowing several concurrent | |
61 | calls. The package also includes several command-line utilities for use in | |
62 | scripts.") | |
63 | (license gpl3+))) | |
cd44f1c1 EF |
64 | |
65 | (define-public c-ares | |
e2931e99 RW |
66 | (package |
67 | (name "c-ares") | |
96630159 | 68 | (version "1.16.0") |
e2931e99 RW |
69 | (source (origin |
70 | (method url-fetch) | |
71 | (uri (string-append | |
72 | "https://c-ares.haxx.se/download/" name "-" version | |
73 | ".tar.gz")) | |
74 | (sha256 | |
75 | (base32 | |
96630159 | 76 | "129sm0wzij0mp8vdv68v18hnykcjb6ivi66wnqnnw598q7bql1fy")))) |
e8393ebe | 77 | (build-system gnu-build-system) |
e2931e99 RW |
78 | (native-inputs |
79 | `(("pkg-config" ,pkg-config))) | |
80 | (home-page "https://c-ares.haxx.se/") | |
81 | (synopsis "C library for asynchronous DNS requests") | |
82 | (description | |
83 | "C-ares is a C library that performs DNS requests and name resolution | |
84 | asynchronously. It is intended for applications which need to perform DNS | |
85 | queries without blocking, or need to perform multiple DNS queries in parallel. | |
86 | The primary examples of such applications are servers which communicate with | |
87 | multiple clients and programs with graphical user interfaces.") | |
88 | (license (x11-style "https://c-ares.haxx.se/license.html")))) | |
c1cb85bf MB |
89 | |
90 | ;; gRPC requires a c-ares built with CMake in order to get the .cmake modules. | |
91 | ;; We can not build c-ares itself with CMake because that would introduce a | |
92 | ;; circular dependency through nghttp2. | |
93 | ;; XXX: It would be nice if we could extract the modules somehow and make them | |
94 | ;; work with the "normal" c-ares package instead of building a whole new library. | |
95 | (define-public c-ares/cmake | |
96 | (hidden-package | |
97 | (package | |
98 | (inherit c-ares) | |
99 | (build-system cmake-build-system) | |
100 | (arguments | |
101 | `(;; XXX: Tests require name resolution (the normal variant runs no tests). | |
102 | #:tests? #f))))) |