From patchwork Wed Dec 23 15:02:51 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 25902 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 9DE0627BC06; Wed, 23 Dec 2020 15:04:09 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 3817127BC05 for ; Wed, 23 Dec 2020 15:04:09 +0000 (GMT) Received: from localhost ([::1]:41652 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ks5gO-0000wr-Ei for patchwork@mira.cbaines.net; Wed, 23 Dec 2020 10:04:08 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:44314) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ks5gI-0000wk-Tg for guix-patches@gnu.org; Wed, 23 Dec 2020 10:04:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:42259) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ks5gI-0000WD-Mm for guix-patches@gnu.org; Wed, 23 Dec 2020 10:04:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ks5gI-0002mv-HL for guix-patches@gnu.org; Wed, 23 Dec 2020 10:04:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#45153] [PATCH v2] gnu: rottlog: Fix mail reporting. Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 23 Dec 2020 15:04:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 45153 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: John Doe Received: via spool by 45153-submit@debbugs.gnu.org id=B45153.160873578510647 (code B ref 45153); Wed, 23 Dec 2020 15:04:02 +0000 Received: (at 45153) by debbugs.gnu.org; 23 Dec 2020 15:03:05 +0000 Received: from localhost ([127.0.0.1]:53805 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ks5fN-0002le-3e for submit@debbugs.gnu.org; Wed, 23 Dec 2020 10:03:05 -0500 Received: from eggs.gnu.org ([209.51.188.92]:50826) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ks5fJ-0002l9-Jh for 45153@debbugs.gnu.org; Wed, 23 Dec 2020 10:03:03 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:51274) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ks5fD-00006V-Ae; Wed, 23 Dec 2020 10:02:55 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=46042 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1ks5fC-0002zq-8c; Wed, 23 Dec 2020 10:02:54 -0500 From: Ludovic =?utf-8?q?Court=C3=A8s?= References: <2691c330f7615c298baeb859c35f489f0de30467.camel@free.fr> <20201212084639.29377-1-dftxbs3e@free.fr> Date: Wed, 23 Dec 2020 16:02:51 +0100 In-Reply-To: <20201212084639.29377-1-dftxbs3e@free.fr> (John Doe's message of "Sat, 12 Dec 2020 09:46:39 +0100") Message-ID: <87sg7wwoo4.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 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: , Cc: =?utf-8?q?L=C3=A9o?= Le Bouter , 45153@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches Hi! John Doe skribis: > From: Léo Le Bouter > > * gnu/packages/admin.scm (rottlog): > [inputs]: Add sendmail. > [phases]: Modify 'patch-paths to substitute sendmail command with > /gnu/store item. [...] > + (("/usr/sbin/sendmail") > + (string-append (assoc-ref inputs "sendmail") > + "/usr/sbin/sendmail"))) I thought this was a typo and then realized that our ‘sendmail’ package is this broken, due to an incorrect use of ‘DESTDIR’. The patch below is an attempt to fix that but some of the files are silently not getting installed. Anyone has ideas here? Anyhow, can we instead use ‘mail’ from ‘mailutils’ instead? (I wrongfully mentioned Inetutils earlier, sorry for the confusion.) Thanks, Ludo’. diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index f85713433e..1f06450e6a 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -2759,23 +2759,39 @@ powerful user customization features.") (("SHELL=/bin/sh") (string-append "SHELL=" (which "sh")))) #t)) (replace 'configure - (lambda _ + (lambda* (#:key outputs #:allow-other-keys) ;; Render harmless any attempts to chown or chgrp (substitute* "devtools/bin/install.sh" (("owner=\\$2") "owner=''") (("group=\\$2") "group=''")) - (with-output-to-file "devtools/Site/site.config.m4" - (lambda () - (format #t " + (let ((out (assoc-ref outputs "out"))) + (with-output-to-file "devtools/Site/site.config.m4" + (lambda () + ;; See 'devtools/M4/UNIX/defines.m4' for the list of + ;; installation directories. + (format #t " define(`confCC', `gcc') define(`confOPTIMIZE', `-g -O2') define(`confLIBS', `-lresolv') define(`confINSTALL', `~a/devtools/bin/install.sh') define(`confDEPEND_TYPE', `CC-M') define(`confINST_DEP', `') -" (getcwd)))) + +define(`confMBINDIR', `~a/bin') +define(`confUBINDIR', `~a/bin') +define(`confSBINDIR', `~a/sbin') +define(`confEBINDIR', `~a/libexec') +define(`confMANROOT', `~a/share/man')~%" + (getcwd) + out out out out out)))) + + (substitute* "cf/cf/Makefile" + (("^MAILDIR=.*") + (string-append "MAILDIR = " + (assoc-ref outputs "out") + "/etc/mail\n"))) #t)) (replace 'build (lambda _ @@ -2787,10 +2803,9 @@ define(`confINST_DEP', `') (add-before 'install 'pre-install (lambda _ (let ((out (assoc-ref %outputs "out"))) - (mkdir-p (string-append out "/usr/bin")) - (mkdir-p (string-append out "/usr/sbin")) + (mkdir-p (string-append out "/bin")) + (mkdir-p (string-append out "/sbin")) (mkdir-p (string-append out "/etc/mail")) - (setenv "DESTDIR" out) (with-directory-excursion "cf/cf" (invoke "sh" "Build" "install-cf")) #t))))