From owner-freebsd-ports-bugs@FreeBSD.ORG Wed Jan 22 00:20:01 2014 Return-Path: Delivered-To: freebsd-ports-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8622F5E9 for ; Wed, 22 Jan 2014 00:20:01 +0000 (UTC) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 614D5188A for ; Wed, 22 Jan 2014 00:20:01 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.7/8.14.7) with ESMTP id s0M0K1nW058372 for ; Wed, 22 Jan 2014 00:20:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.7/8.14.7/Submit) id s0M0K1rI058371; Wed, 22 Jan 2014 00:20:01 GMT (envelope-from gnats) Resent-Date: Wed, 22 Jan 2014 00:20:01 GMT Resent-Message-Id: <201401220020.s0M0K1rI058371@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, David Shane Holden Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id E2D8D470 for ; Wed, 22 Jan 2014 00:11:33 +0000 (UTC) Received: from oldred.freebsd.org (oldred.freebsd.org [IPv6:2001:1900:2254:206a::50:4]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id CE836184C for ; Wed, 22 Jan 2014 00:11:33 +0000 (UTC) Received: from oldred.freebsd.org ([127.0.1.6]) by oldred.freebsd.org (8.14.5/8.14.7) with ESMTP id s0M0BXff065478 for ; Wed, 22 Jan 2014 00:11:33 GMT (envelope-from nobody@oldred.freebsd.org) Received: (from nobody@localhost) by oldred.freebsd.org (8.14.5/8.14.5/Submit) id s0M0BXDr065468; Wed, 22 Jan 2014 00:11:33 GMT (envelope-from nobody) Message-Id: <201401220011.s0M0BXDr065468@oldred.freebsd.org> Date: Wed, 22 Jan 2014 00:11:33 GMT From: David Shane Holden To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Subject: ports/185977: [patch] devel/distcc: add rc option to set DISTCCD_PATH X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Jan 2014 00:20:01 -0000 >Number: 185977 >Category: ports >Synopsis: [patch] devel/distcc: add rc option to set DISTCCD_PATH >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Wed Jan 22 00:20:01 UTC 2014 >Closed-Date: >Last-Modified: >Originator: David Shane Holden >Release: 10.0-RELEASE >Organization: >Environment: FreeBSD i7x 10.0-RELEASE FreeBSD 10.0-RELEASE #0 r260789: Thu Jan 16 22:34:59 UTC 2014 root@snap.freebsd.org:/usr/obj/usr/src/sys/GENERIC amd64 >Description: When trying to use gcc with distcc, I found that the remote distccd process couldn't find it and failed because by default it was searching the base system path. This patch allows you to set the DISTCCD_PATH environment variable which is used instead of PATH when it searches for compilers. eg. distccd_enable="YES" distccd_path="/usr/bin:/usr/local/bin" This allows distccd to use compilers installed from ports in /usr/local/bin as well as clang from /usr/bin. >How-To-Repeat: >Fix: Patch attached with submission follows: diff --git a/devel/distcc/files/distccd.in b/devel/distcc/files/distccd.in index c9b9d4a..6d63291 100644 --- a/devel/distcc/files/distccd.in +++ b/devel/distcc/files/distccd.in @@ -10,7 +10,9 @@ # # Add the following lines to /etc/rc.conf to enable distccd: # -# distccd_enable="YES" +# distccd_enable (bool): Set to YES to enable distccd. +# distccd_flags (str): Arguments passed to distccd. +# distccd_path (str): DISTCCD_PATH environment value for distccd.. # distccd_enable=${distccd_enable-"NO"} @@ -32,6 +34,11 @@ distccd_precmd() # distccd drops root privileges and then attempts to create the pid file touch ${pidfile} chown distcc:distcc ${pidfile} + + if [ -n "${distccd_path}" ] + then + export DISTCCD_PATH="${distccd_path}" + fi } start_precmd="distccd_precmd" >Release-Note: >Audit-Trail: >Unformatted: