From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id bEupIHNC514gHgAA0tVLHw (envelope-from ) for ; Mon, 15 Jun 2020 09:42:11 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id 6NAbHHNC517XNAAAbx9fmQ (envelope-from ) for ; Mon, 15 Jun 2020 09:42:11 +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 E69AF9400B1 for ; Mon, 15 Jun 2020 09:42:10 +0000 (UTC) Received: from localhost ([::1]:48940 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jkld3-0005ZL-EU for larch@yhetil.org; Mon, 15 Jun 2020 05:42:09 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39864) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jklcw-0005ZC-ND for bug-guix@gnu.org; Mon, 15 Jun 2020 05:42:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:33706) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jklcw-0005yl-Dj for bug-guix@gnu.org; Mon, 15 Jun 2020 05:42:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jklcw-0002f8-9Q for bug-guix@gnu.org; Mon, 15 Jun 2020 05:42:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#32934: [PATCH] gnu: privoxy: Fix default logging configuration. Resent-From: Brice Waegeneire Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Mon, 15 Jun 2020 09:42:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 32934 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Pierre Neidhardt Received: via spool by 32934-submit@debbugs.gnu.org id=B32934.159221410410208 (code B ref 32934); Mon, 15 Jun 2020 09:42:02 +0000 Received: (at 32934) by debbugs.gnu.org; 15 Jun 2020 09:41:44 +0000 Received: from localhost ([127.0.0.1]:45252 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jklca-0002eU-Q9 for submit@debbugs.gnu.org; Mon, 15 Jun 2020 05:41:44 -0400 Received: from relay12.mail.gandi.net ([217.70.178.232]:37897) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jklcY-0002eH-Ov for 32934@debbugs.gnu.org; Mon, 15 Jun 2020 05:41:39 -0400 Received: from localhost (luy13-1-78-237-113-178.fbx.proxad.net [78.237.113.178]) (Authenticated sender: brice@waegenei.re) by relay12.mail.gandi.net (Postfix) with ESMTPSA id B021520000F; Mon, 15 Jun 2020 09:41:31 +0000 (UTC) From: Brice Waegeneire Date: Mon, 15 Jun 2020 11:41:22 +0200 Message-Id: <20200615094122.5629-1-brice@waegenei.re> X-Mailer: git-send-email 2.26.2 In-Reply-To: <87d0spmqdo.fsf@ambrevar.xyz> References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.7 (-) X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: 32934@debbugs.gnu.org Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Spam-Score: -0.01 X-TUID: +VeJMMplUJ0Z Fixes . * gnu/packages/tor.scm (privoxy)[arguments]: Add 'localstatedir'. : Add 'patch-default-logging'. --- Hello Pierre, This patch should allow one to use privoxy's default configuration as is: --8<---------------cut here---------------start------------->8--- $ /gnu/store/1705l8br2bc4lvs7wf7mpzj4ss0zkl9c-privoxy-3.0.28/sbin/privoxy /gnu/store/1705l8br2bc4lvs7wf7mpzj4ss0zkl9c-privoxy-3.0.28/etc/privoxy/config $ echo $? 0 --8<---------------cut here---------------end--------------->8--- - Brice gnu/packages/tor.scm | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/gnu/packages/tor.scm b/gnu/packages/tor.scm index 2f2623b0e6..19ab5cf374 100644 --- a/gnu/packages/tor.scm +++ b/gnu/packages/tor.scm @@ -8,6 +8,7 @@ ;;; Copyright © 2017 Rutger Helling ;;; Copyright © 2018 Ricardo Wurmus ;;; Copyright © 2020 Vincent Legoll +;;; Copyright © 2020 Brice Waegeneire ;;; ;;; This file is part of GNU Guix. ;;; @@ -141,8 +142,28 @@ rejects UDP traffic from the application you're using.") ;; $out/etc/privoxy. #:configure-flags (list (string-append "--sysconfdir=" (assoc-ref %outputs "out") - "/etc/privoxy")) - #:tests? #f)) + "/etc/privoxy") + "--localstatedir=/var") + #:tests? #f ; no test suite + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'patch-default-logging + (lambda _ + (with-fluids ((%default-port-encoding "ISO-8859-1")) + ;; Do not create /var/run nor /var/log/privoxy/logfile. + (substitute* "GNUmakefile.in" + (("(logfile \\|\\| exit )1" _ match) + (string-append match "0")) + (("(\\$\\(DESTDIR\\)\\$\\(SHARE_DEST\\)) \\\\" _ match) + match) + ((".*\\$\\(LOG_DEST\\) \\$\\(DESTDIR\\)\\$\\(PID_DEST\\).*") + "")) + ;; Disable logging in the default configuration to allow for + ;; non-root users using it as is. + (substitute* "config" + (("^logdir") "#logdir") + (("^logfile") "#logfile"))) + #t))))) (inputs `(("w3m" ,w3m) ("pcre" ,pcre) -- 2.26.2