From 0e8efe061139be8a8ed14711f9ec0937161cf566 Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Thu, 20 Jan 2022 23:12:32 +0100 Subject: gnu: OpenLDAP: Add 2.6.1. * gnu/packages/openldap.scm (openldap-2.6): New variable. --- gnu/packages/openldap.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) (limited to 'gnu/packages/openldap.scm') diff --git a/gnu/packages/openldap.scm b/gnu/packages/openldap.scm index b0ce899696..54a0571a1b 100644 --- a/gnu/packages/openldap.scm +++ b/gnu/packages/openldap.scm @@ -8,6 +8,7 @@ ;;; Copyright © 2020 Lars-Dominik Braun ;;; Copyright © 2020 Efraim Flashner ;;; Copyright © 2021 Maxim Cournoyer +;;; Copyright © 2022 Marius Bakke ;;; ;;; This file is part of GNU Guix. ;;; @@ -54,6 +55,7 @@ #:use-module (gnu packages) #:use-module ((guix licenses) #:select (openldap2.8 lgpl2.1+ gpl3+ psfl expat)) #:use-module (guix packages) + #:use-module (guix gexp) #:use-module (guix utils) #:use-module (guix download) #:use-module (guix build-system gnu) @@ -120,6 +122,48 @@ (license openldap2.8) (home-page "https://www.openldap.org/"))) +;; TODO: Update the main package in the next rebuild cycle. +(define-public openldap-2.6 + (package + (inherit openldap) + (version "2.6.1") + (source (origin + (method url-fetch) + ;; See for a list of + ;; mirrors. + (uri (list (string-append + "http://mirror.eu.oneandone.net/software/openldap" + "/openldap-release/openldap-" version ".tgz") + (string-append + "https://www.openldap.org/software/download/OpenLDAP/" + "openldap-release/openldap-" version ".tgz") + (string-append + "ftp://ftp.dti.ad.jp/pub/net/OpenLDAP/" + "openldap-release/openldap-" version ".tgz"))) + (sha256 + (base32 + "1wz6f3g3bbqgbbxs20zlappmmhapqbl791c0waibhz9djsk6wmwx")))) + (arguments + (substitute-keyword-arguments (package-arguments openldap) + ((#:phases phases) + #~(modify-phases #$phases + (replace 'patch-sasl-path + ;; Give -L arguments for cyrus-sasl to avoid propagation. + (lambda* (#:key inputs #:allow-other-keys) + (let ((krb5 (search-input-file inputs "/lib/libkrb5.so"))) + (substitute* (string-append #$output "/lib/libldap.la") + (("-lkrb5" lib) + (string-append "-L" (dirname krb5) "/lib " lib)))))) + (add-after 'install 'provide-ldap_r + (lambda _ + ;; The re-entrant libldap_r no longer exists since 2.6 + ;; as it has become the default: provide a linker alias + ;; for now. + (call-with-output-file (string-append #$output + "/lib/libldap_r.so") + (lambda (port) + (format port "INPUT ( libldap.so )~%"))))))))))) + (define-public nss-pam-ldapd (package (name "nss-pam-ldapd") -- cgit 1.4.1