From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id iE2WFr63vWGE6AAAgWs5BA (envelope-from ) for ; Sat, 18 Dec 2021 11:28:14 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id WKg4Er63vWFGDQAAbx9fmQ (envelope-from ) for ; Sat, 18 Dec 2021 10:28:14 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id EFFCA3762F for ; Sat, 18 Dec 2021 11:28:13 +0100 (CET) Received: from localhost ([::1]:44574 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1myWwn-00071I-21 for larch@yhetil.org; Sat, 18 Dec 2021 05:28:13 -0500 Received: from eggs.gnu.org ([209.51.188.92]:55108) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1myWwc-00070p-Hz for guix-patches@gnu.org; Sat, 18 Dec 2021 05:28:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:57991) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1myWwc-00043A-9m for guix-patches@gnu.org; Sat, 18 Dec 2021 05:28:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1myWwb-0004at-Ua for guix-patches@gnu.org; Sat, 18 Dec 2021 05:28:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#52578] [PATCH] updating openldap and adding service definition Resent-From: zimoun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 18 Dec 2021 10:28:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 52578 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Jean-Francois GUILLAUME , 52578@debbugs.gnu.org Received: via spool by 52578-submit@debbugs.gnu.org id=B52578.163982323017602 (code B ref 52578); Sat, 18 Dec 2021 10:28:01 +0000 Received: (at 52578) by debbugs.gnu.org; 18 Dec 2021 10:27:10 +0000 Received: from localhost ([127.0.0.1]:41304 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1myWvl-0004Zq-Tr for submit@debbugs.gnu.org; Sat, 18 Dec 2021 05:27:10 -0500 Received: from mail-wr1-f42.google.com ([209.85.221.42]:39780) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1myWvi-0004ZO-Tz for 52578@debbugs.gnu.org; Sat, 18 Dec 2021 05:27:08 -0500 Received: by mail-wr1-f42.google.com with SMTP id s1so3409694wra.6 for <52578@debbugs.gnu.org>; Sat, 18 Dec 2021 02:27:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:subject:in-reply-to:references:date:message-id:mime-version :content-transfer-encoding; bh=n2XQkFEd6HsNKm9aYfdjdsHwp8HzFzOGw/xFNiTfygo=; b=irrqQ1o3v7mjTAhtdq0dbm43eTuscFrubliC2b1uNidkt3ktaqlKsRichmyXtq8o3e mn5ZRa3llKvPXGGcadI7orMUUCjjHznLuncOdUJjbfSneBg+XqPpaRgSOaZvzQJd98mL bA+py/R0a/2XELNnhFtUnuFGFSQ1zrXn3L/OCLoRN9HEhmfmNfQbmi2ZvUyuo27//LaA sFSjwyW2At563UagzmR9d3V9N4oKTSuJ61z44LBTJA7C0V3I6TvueT+Ry8HWZlxaNnfc FMhCiCOto1WSSjRWNPsyXQjRt7TpFPWGSOHv0MDEUl1zBP7nXYDb3xBpCf+kBQRswarD o8+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:in-reply-to:references:date :message-id:mime-version:content-transfer-encoding; bh=n2XQkFEd6HsNKm9aYfdjdsHwp8HzFzOGw/xFNiTfygo=; b=FuCdwmEfctnTVtsnQlbfsRRR7YQ4M9cKzvKTpE9OKFjPmtaSUABPhyoLMaYTqzzeHI Pf/imoDhIRcZYFOfvvSDTIckQW9vOH6MhcqZXsbx+p86xW2qpNz7RBhqxRRL1cnynbW4 21zAkjtvd95evs17A7nWOcjRw/K9tgegzoew4Q+9BTFFGXoOFor3WlEXkgVswTPXG715 21hrt3zPxDUCMAKqm6/VECD7/zMwbpIf0F2ReeeWGZ46/LSzFHAdIZmkiXPhO0WhS4xK Epx7B9bm5BALnlO2Dkq1l1mnDa8BVDrQQ6gQLjudMtEQ+bL1wgkBs/G+XdTNvTc2K4vH hY8A== X-Gm-Message-State: AOAM531MDWMsmlJGbP4FTnCkhWxeh4zD4WO58OqEwZDCBXsrNY9YBZgR 7U1uiAYptUT7u1Rnm6Vez+LWTFAc4mw= X-Google-Smtp-Source: ABdhPJxmtvQYf4IS9KoI2dqX4h4XCbaKaW4sMelXarIw2tEGB4ul2W3d/BB6CGK9AG0wX5odHEOiPQ== X-Received: by 2002:adf:ec09:: with SMTP id x9mr5831443wrn.111.1639823220868; Sat, 18 Dec 2021 02:27:00 -0800 (PST) Received: from lili ([2a01:e0a:59b:9120:65d2:2476:f637:db1e]) by smtp.gmail.com with ESMTPSA id r5sm5511575wrj.4.2021.12.18.02.27.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Dec 2021 02:27:00 -0800 (PST) From: zimoun In-Reply-To: References: Date: Sat, 18 Dec 2021 11:22:05 +0100 Message-ID: <86ee6aqkky.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1639823294; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=n2XQkFEd6HsNKm9aYfdjdsHwp8HzFzOGw/xFNiTfygo=; b=OI4ZcZlXZf3JNgBpO9/ReD7itaFeU4b2t9O0f+3Al+HYrGM219JVWwjMysgCds7Dkd/5HT nliuDnm6KmU2wnRuZCNm3iQISCqwxmOmhus6wLCas2XWyxS/E/KVEFeo4+ToRSW6d9XNLG kA/ZrgHJVBETmQGk2rniVcLsJaNR+DHNkPMySn6TXhYJWTTO7+MZHpqSX2ny1XvhrLwtcQ IWUYkOeiaKvxfrprD0MaMxE6BqLIUWipYMeTQ4/7d6I23HnfAW+Y456WRGbm9c+XXZM53U wkgjPlDZLNlgi7HA3KGUFrc+0APjLmAozVkwxWy1BZAgavTyc1VsTqPFhMk4zw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1639823294; a=rsa-sha256; cv=none; b=bJeQ6OKy7rzCcjYqtcOmVLiql/Y9FouMdUgaOl6UTYqvvNyfPEWdLz5JrjVymJARR/ZN4+ 09tOnHyvVMe4OPPqe4QuahyNTlfTNgDNNvsjJw5CuPv0GfrPPLOm6OE6Obhj6x3n8yXb4G CkwV/3Ht8w55e0+/7piWpQOsefUI3RSvHPyMQau5lUw+Pvo6HF18kM4MBCtl2U7kMelvx0 YlfY+gm7H+2hm7UpxUs2zMVqQnKadcSTQQ1XYUncmhBs0wX9PPZHafm0fhiR5y3gEx11FV 2X7RThUhonLP8phyxwauMjeUXyudy5EUjTeMVAFuzFOx5slJHlzjwoblQO36UQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=irrqQ1o3; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -3.20 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=irrqQ1o3; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: EFFCA3762F X-Spam-Score: -3.20 X-Migadu-Scanner: scn0.migadu.com X-TUID: Rnphyurg4DNU Hi Jean-Fran=C3=A7ois, Nice to see you here. :-) Various comments for improving the submission. On Fri, 17 Dec 2021 at 14:52, Jean-Francois GUILLAUME wrote: > * gnu/packages/openldap.scm (openldap): Update to 2.6.0, adding 2.5.7,=20 > 2.5.8, 2.5.9 > * gnu/services/openldap.scm (openldap): Adding slapd service I would split: one commit for adding a big openldap and another for adding the service. WDYT? (I have not looked yet to the service.) > (define-public openldap > + (package > + (name "openldap") > + (version "2.6.0") > + (source (origin > + (method url-fetch) > + (uri (list > + (string-append=20 > "https://www.openldap.org/software/download/OpenLDAP/openldap-release/ope= nldap-"=20 > version ".tgz") Why the mirror list had been removed? > + (string-append=20 > "http://repository.linagora.org/OpenLDAP/openldap-release/openldap-"=20 > version ".tgz") This is new, right? > + (string-append=20 > "ftp://ftp.dti.ad.jp/pub/net/OpenLDAP/openldap-release/openldap-"=20 > version ".tgz") As it is currently and already done in gnu/packages/openldap.scm, to ease the reading, this long string could be slip as, --8<---------------cut here---------------start------------->8--- (string-append "ftp://ftp.dti.ad.jp/pub/net/OpenLDAP/" "openldap-release/openldap-" version ".tgz"))) --8<---------------cut here---------------end--------------->8--- (See below for details if many variants are required.) > + (inputs `( > + ("argon2", argon2) > + ("cyrus-sasl", cyrus-sasl) > + ("libevent", libevent) > + ("libgcrypt", libgcrypt) > + ("libltdl", libltdl) > + ("lz4", lz4) > + ("openssl", openssl) > + ("perl", perl) > + ("snappy", snappy) > + ("unixodbc", unixodbc) > + ("wiredtiger", wiredtiger) > + ("zlib", zlib) > + )) > + (native-inputs `( > + ("bdb", bdb) > + ("groff", groff) > + ("libtool", libtool) > + ("pkg-config", pkg-config) > + )) Currently, openldap@2.4.57 is built using (reformatted by me to ease the comparison): --8<---------------cut here---------------start------------->8--- (inputs (list bdb-5.3=20 cyrus-sasl=20 gnutls=20 libgcrypt=20 zlib)) (native-inputs (list libtool=20 groff=20 bdb-5.3)) --8<---------------cut here---------------end--------------->8--- Aside the new style vs the old style which is a detail, are these lists expanded because the version bump or because more OpenLDAP is built using more features? > + (arguments `( > + ; this is needed because the make check does not work inside guix > + #:tests? #f It was already off, but I do not understand the new comment. Well, maybe this commentary is not necessary. > + #:configure-flags '( > + "--enable-debug" > + "--enable-dynamic" > + "--enable-syslog" > + "--enable-ipv6" > + "--enable-local" > + "--enable-slapd" > + "--enable-dynacl" > + "--enable-aci" > + "--enable-cleartext" > + "--enable-crypt" > + "--enable-spasswd" > + "--enable-modules" > + "--enable-rlookups" > + "--enable-slapi" > + "--enable-backends=3Dmod" > + "--enable-overlays=3Dmod" > + "--enable-argon2" > + "--enable-balancer" > + "--disable-static" > + "--enable-shared" > + "--with-tls=3Dopenssl" > + "--disable-static" This is a lot more. :-) Therefore, the question is: is it better=20 - to have only one BIG openldap package? - or to have one minimal openldap and a bigger variant? Well, =E2=80=9Cguix refresh -l openldap=E2=80=9D answers for us. ;-) I propose to keep openldap@2.4.57 minimal, as it currently is, and use =E2=80=99inherit=E2=80=99 to build BIG =E2=80=99openldap@2.6.0.=E2=80=99 an= d variants. > + ,@(if (%current-target-system) > + '("--with-yielding_select=3Dyes"=20 > "ac_cv_func_memcmp_working=3Dyes") > + '() > + ) > + ) > + #:make-flags '("STRIP=3D") > + #:parallel-build? #t This is not necessary because it is the default. > + #:phases (modify-phases %standard-phases > + (add-before 'build 'make-depend > + (lambda* (#:key input #:allow-other-keys) > + (invoke "make" "depend") > + ) > + ) > + ,@(if (%current-target-system) > + '( > + (add-before 'make-depend 'fix-cross-gcc > + (lambda* (#:key target #:allow-other-keys) > + (setenv "CC" (string-append target "-gcc")) > + #t > + ) > + ) > + ) > + '() > + ) > + ) > + )) A minor comment, usually, we do: --8<---------------cut here---------------start------------->8--- ,@(if (%current-target-system) '((add-before 'make-depend 'fix-cross-gcc (lambda* (#:key target #:allow-other-keys) (setenv "CC" (string-append target "-gcc")) #t))) '())))) --8<---------------cut here---------------end--------------->8--- instead of all these closing parens, each on one line. Using =E2=80=99inherit=E2=80=99, this is even probably not required. :-) > +(define-public openldap-2.5.9 > + (package > + (inherit openldap) > + (name "openldap") > + (version "2.5.9") > + (source (origin > + (method url-fetch) > + (uri (list > + (string-append=20 > "https://www.openldap.org/software/download/OpenLDAP/openldap-release/ope= nldap-"=20 > version ".tgz") > + (string-append=20 > "http://repository.linagora.org/OpenLDAP/openldap-release/openldap-"=20 > version ".tgz") > + (string-append=20 > "ftp://ftp.dti.ad.jp/pub/net/OpenLDAP/openldap-release/openldap-"=20 > version ".tgz") > + )) > + (sha256 ( base32=20 > "17pvwrj27jybbmjqpv0p7kd2qa4i6jnp134lz7cxa0sqrbs153n0" )) > + ) Do you need all these variants? If yes, it could be nice to have, instead of copy/paste all, something like: --8<---------------cut here---------------start------------->8--- (define (openldap-uris version) (let ((openldap-release "OpenLDAP/openldap-release/") (openldap-version.tgz (string-append "openldap-" version ".tgz"))) (map (lambda (url) (string-append url openldap-release openldap-version.tgz)) (list "https://www.openldap.org/software/download/" "http://repository.linagora.org/" "ftp://ftp.dti.ad.jp/pub/net/")))) (define-public openldap-2.5.8 (package (inherit openldap) (name "openldap") (version "2.5.8") (source (origin (method url-fetch) (uri (openldap-uris version)) (sha256 (base32 "1p3jck2kh7rsz6mkrqaailaf9ky050hn72wph52dw0j2nb1s2vin"))))) [=E2=80=A6] --8<---------------cut here---------------end--------------->8--- (Untested though. :-))) Cheers, simon