gnu: inspircd: Use G-expressions.

* gnu/packages/irc.scm (inspircd)[arguments]:
Rewrite as G-expressions.
This commit is contained in:
Tobias Geerinckx-Rice 2022-01-12 05:13:26 +00:00
parent a83bab6bae
commit 496a02d293
No known key found for this signature in database
GPG key ID: 0DB0FF884F556D79

View file

@ -5,7 +5,7 @@
;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2016 Nikita <nikita@n0.is>
;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com>
;;; Copyright © 20172021 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 20172022 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2020 Oleg Pykhalov <go.wigust@gmail.com>
;;; Copyright © 2020, 2021 Vinicius Monego <monego@posteo.net>
;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
@ -28,6 +28,7 @@
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages irc)
#:use-module (guix gexp)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix download)
#:use-module (guix git-download)
@ -626,42 +627,42 @@ (define-public inspircd
(base32 "0xlfs269iaw7dfryzl6vjzqsn2g4nqh6kpf5xfgk3zbjhqaczknx"))))
(build-system gnu-build-system)
(arguments
`(#:configure-flags (map (lambda (module)
(string-append "--enable-extras=" module))
'("m_argon2.cpp"
"m_geo_maxmind.cpp"
"m_ldap.cpp"
"m_mysql.cpp"
"m_pgsql.cpp"
"m_regex_pcre.cpp"
"m_regex_posix.cpp"
"m_regex_stdlib.cpp"
"m_regex_re2.cpp"
"m_regex_tre.cpp"
"m_sqlite3.cpp"
"m_ssl_gnutls.cpp"
"m_ssl_openssl.cpp"
"m_ssl_mbedtls.cpp"
"m_sslrehashsignal.cpp"))
#:tests? #f ; Figure out later.
#:phases
(modify-phases %standard-phases
(add-before 'configure 'module-configure
(lambda* (#:key configure-flags #:allow-other-keys)
(apply invoke "./configure"
configure-flags)))
(replace 'configure
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(out-lib (string-append out "/lib/"))
(out-bin (string-append out "/bin/"))
(out-etc (string-append out "/etc/"))
(name "inspircd"))
(invoke "./configure"
(string-append "--prefix=" out-lib name)
(string-append "--binary-dir=" out-bin)
(string-append "--module-dir=" out-lib name "/modules/")
(string-append "--config-dir=" out-etc name))))))))
(list #:configure-flags
#~(map (lambda (module)
(string-append "--enable-extras=" module))
'("m_argon2.cpp"
"m_geo_maxmind.cpp"
"m_ldap.cpp"
"m_mysql.cpp"
"m_pgsql.cpp"
"m_regex_pcre.cpp"
"m_regex_posix.cpp"
"m_regex_stdlib.cpp"
"m_regex_re2.cpp"
"m_regex_tre.cpp"
"m_sqlite3.cpp"
"m_ssl_gnutls.cpp"
"m_ssl_openssl.cpp"
"m_ssl_mbedtls.cpp"
"m_sslrehashsignal.cpp"))
#:tests? #f ; XXX figure out later
#:phases
#~(modify-phases %standard-phases
(add-before 'configure 'module-configure
(lambda* (#:key configure-flags #:allow-other-keys)
(apply invoke "./configure"
configure-flags)))
(replace 'configure
(lambda _
(let ((lib (string-append #$output "/lib/"))
(bin (string-append #$output "/bin/"))
(etc (string-append #$output "/etc/"))
(name "inspircd"))
(invoke "./configure"
(string-append "--prefix=" lib name)
(string-append "--binary-dir=" bin)
(string-append "--module-dir=" lib name "/modules/")
(string-append "--config-dir=" etc name))))))))
(native-inputs
(list pkg-config))
(inputs