diff options
| author | Nox <noximilien@riseup.net> | 2026-05-19 00:31:14 +0200 |
|---|---|---|
| committer | Nguyễn Gia Phong <cnx@loang.net> | 2026-06-07 22:38:55 +0900 |
| commit | 773933ede3d61e606b0d611ffac4aba0dc735a8d (patch) | |
| tree | 3a20653369b867fca11043fc20ce571b283d199e /gnu/packages/lua.scm | |
| parent | 1c9090024fda1dacf8dd0daa0a2982361cad87f3 (diff) | |
gnu: Add lua-unbound and variants.
* gnu/packages/lua.scm (make-lua-unbound): New procedure.
(lua5.2-unbound, lua-unbound, lua5.4-unbound, lua5.5-unbound):
New variables.
Change-Id: Ia11ba1b951cdccaebe2f1efe6646bc8701caebb9
Merges: https://codeberg.org/guix/guix/pulls/8711
Reviewed-by: Carlo Zancanaro <carlo@zancanaro.id.au>
Signed-off-by: Nguyễn Gia Phong <cnx@loang.net>
Diffstat (limited to 'gnu/packages/lua.scm')
| -rw-r--r-- | gnu/packages/lua.scm | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/gnu/packages/lua.scm b/gnu/packages/lua.scm index 96bbe229325..84fd2c51da0 100644 --- a/gnu/packages/lua.scm +++ b/gnu/packages/lua.scm | |||
| @@ -49,6 +49,7 @@ | |||
| 49 | #:use-module (guix download) | 49 | #:use-module (guix download) |
| 50 | #:use-module (guix git-download) | 50 | #:use-module (guix git-download) |
| 51 | #:use-module (guix gexp) | 51 | #:use-module (guix gexp) |
| 52 | #:use-module (guix hg-download) | ||
| 52 | #:use-module (guix utils) | 53 | #:use-module (guix utils) |
| 53 | #:use-module (guix build-system gnu) | 54 | #:use-module (guix build-system gnu) |
| 54 | #:use-module (guix build-system cmake) | 55 | #:use-module (guix build-system cmake) |
| @@ -63,6 +64,7 @@ | |||
| 63 | #:use-module (gnu packages build-tools) | 64 | #:use-module (gnu packages build-tools) |
| 64 | #:use-module (gnu packages check) | 65 | #:use-module (gnu packages check) |
| 65 | #:use-module (gnu packages compression) | 66 | #:use-module (gnu packages compression) |
| 67 | #:use-module (gnu packages dns) | ||
| 66 | #:use-module (gnu packages gcc) | 68 | #:use-module (gnu packages gcc) |
| 67 | #:use-module (gnu packages glib) | 69 | #:use-module (gnu packages glib) |
| 68 | #:use-module (gnu packages gperf) | 70 | #:use-module (gnu packages gperf) |
| @@ -2166,3 +2168,61 @@ from within Lua programs.") | |||
| 2166 | 2168 | ||
| 2167 | (define-public lua5.4-lsqlite3 | 2169 | (define-public lua5.4-lsqlite3 |
| 2168 | (make-lua-lsqlite3 "lua5.4-lsqlite3" lua-5.4 lua5.4-lunitx)) | 2170 | (make-lua-lsqlite3 "lua5.4-lsqlite3" lua-5.4 lua5.4-lunitx)) |
| 2171 | |||
| 2172 | (define (make-lua-unbound name lua) | ||
| 2173 | (package | ||
| 2174 | (name name) | ||
| 2175 | (version "1.1.0") | ||
| 2176 | (source | ||
| 2177 | (origin | ||
| 2178 | (method hg-fetch) | ||
| 2179 | (uri (hg-reference | ||
| 2180 | (url "https://hg.sr.ht/~zash/luaunbound") | ||
| 2181 | (changeset version))) | ||
| 2182 | (file-name (hg-file-name name version)) | ||
| 2183 | (sha256 | ||
| 2184 | (base32 "17q5n9h1hnlx00x4k3h93rwyy41gfpd42yyp13rqkhhkmimw6q2y")))) | ||
| 2185 | (build-system gnu-build-system) | ||
| 2186 | (arguments | ||
| 2187 | (list | ||
| 2188 | #:tests? #f ;no test | ||
| 2189 | #:make-flags | ||
| 2190 | #~(let ((lua-version #$(version-major+minor (package-version lua)))) | ||
| 2191 | (list | ||
| 2192 | (string-append "CC=" #$(cc-for-target)) | ||
| 2193 | (string-append "LUA_VERSION=" lua-version) | ||
| 2194 | (string-append "LUA_LIBDIR=/lib/lua/" lua-version) | ||
| 2195 | (string-append "MYLDFLAGS=-L" | ||
| 2196 | #$(this-package-input "unbound") "/lib") | ||
| 2197 | (string-append "DESTDIR=" #$output))) | ||
| 2198 | #:phases | ||
| 2199 | #~(modify-phases %standard-phases | ||
| 2200 | (delete 'configure)))) | ||
| 2201 | (native-inputs (list pkg-config)) | ||
| 2202 | (inputs (list lua unbound)) | ||
| 2203 | (home-page "https://www.zash.se/luaunbound.html") | ||
| 2204 | (synopsis "Unbound binding for Lua") | ||
| 2205 | (description | ||
| 2206 | "This is a binding to libunbound for Lua, allowing both asynchronous | ||
| 2207 | and DNSSEC-secured DNS lookups of arbitrary DNS record types. | ||
| 2208 | |||
| 2209 | It was created because Prosody needs an asynchronous DNS library with support | ||
| 2210 | for SRV records, and the ones found at the time did one or the other, or was | ||
| 2211 | missing DNSSEC that allowed implementing DANE. | ||
| 2212 | |||
| 2213 | It originated out of a need in the XMPP server software Prosody for an | ||
| 2214 | async-capable resolver library supporting SRV records, as well as a desire to | ||
| 2215 | experiment with DNSSEC and new DNS records.") | ||
| 2216 | (license license:expat))) | ||
| 2217 | |||
| 2218 | (define-public lua5.2-unbound | ||
| 2219 | (make-lua-unbound "lua5.2-unbound" lua-5.2)) | ||
| 2220 | |||
| 2221 | (define-public lua-unbound | ||
| 2222 | (make-lua-unbound "lua-unbound" lua)) | ||
| 2223 | |||
| 2224 | (define-public lua5.4-unbound | ||
| 2225 | (make-lua-unbound "lua5.4-unbound" lua-5.4)) | ||
| 2226 | |||
| 2227 | (define-public lua5.5-unbound | ||
| 2228 | (make-lua-unbound "lua5.5-unbound" lua-5.5)) | ||
