From owner-freebsd-ports-bugs@FreeBSD.ORG Sat Nov 24 16:50:00 2012 Return-Path: Delivered-To: freebsd-ports-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C074DA4A for ; Sat, 24 Nov 2012 16:50:00 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id 928428FC15 for ; Sat, 24 Nov 2012 16:50:00 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id qAOGo0SS055089 for ; Sat, 24 Nov 2012 16:50:00 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id qAOGo0Nn055088; Sat, 24 Nov 2012 16:50:00 GMT (envelope-from gnats) Resent-Date: Sat, 24 Nov 2012 16:50:00 GMT Resent-Message-Id: <201211241650.qAOGo0Nn055088@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, Thierry Thomas Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E1CA3A38; Sat, 24 Nov 2012 16:49:19 +0000 (UTC) (envelope-from thierry@pompo.net) Received: from mx1b.lautre.net (etna.lautre.net [80.67.160.72]) by mx1.freebsd.org (Postfix) with ESMTP id 72F418FC08; Sat, 24 Nov 2012 16:49:18 +0000 (UTC) Received: from graf.pompo.net (graf.pompo.net [78.225.128.39]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: thierry@pompo.net) by mx1b.lautre.net (Postfix) with ESMTPSA id 3E8957E10E; Sat, 24 Nov 2012 17:49:17 +0100 (CET) Received: by graf.pompo.net (Postfix, from userid 1001) id C53B81147B; Sat, 24 Nov 2012 17:47:13 +0100 (CET) Message-Id: <20121124164713.C53B81147B@graf.pompo.net> Date: Sat, 24 Nov 2012 17:47:13 +0100 (CET) From: Thierry Thomas To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: ports/173892: Mk/bsd.port.mk: make COPYTREE_SHARE handle symbolic links Cc: gahr@FreeBSD.org, portmgr@FreeBSD.org X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Thierry Thomas List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 24 Nov 2012 16:50:00 -0000 >Number: 173892 >Category: ports >Synopsis: Mk/bsd.port.mk: make COPYTREE_SHARE handle symbolic links >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Sat Nov 24 16:50:00 UTC 2012 >Closed-Date: >Last-Modified: >Originator: Thierry Thomas >Release: FreeBSD 9.0-STABLE i386 >Organization: Kabbale Eros >Environment: System: FreeBSD graf.pompo.net >Description: Weekly run output alerted me that lang/cfortran installs several links with a bad ownership: $ find /usr/local/share/examples/cfortran -type l -ls | head 3442403 0 lrwxrwxrwx 1 8290 1300 5 15 déc 1995 /usr/local/share/examples/cfortran/abc/abc.C -> abc.c 3442405 0 lrwxrwxrwx 1 8290 1300 6 15 déc 1995 /usr/local/share/examples/cfortran/cf14/cf14.C -> cf14.c 3442407 0 lrwxrwxrwx 1 8290 1300 16 15 déc 1995 /usr/local/share/examples/cfortran/e2/e2_f.f -> ../easy/easy_f.f 3442408 0 lrwxrwxrwx 1 8290 1300 4 15 déc 1995 /usr/local/share/examples/cfortran/e2/e2.C -> e2.c 3442410 0 lrwxrwxrwx 1 8290 1300 6 15 déc 1995 /usr/local/share/examples/cfortran/easy/easy.C -> easy.c 3442412 0 lrwxrwxrwx 1 8290 1300 4 15 déc 1995 /usr/local/share/examples/cfortran/eq/eq.C -> eq.c 3442414 0 lrwxrwxrwx 1 8290 1300 4 15 déc 1995 /usr/local/share/examples/cfortran/f0/f0.C -> f0.c 3442416 0 lrwxrwxrwx 1 8290 1300 5 23 oct 1996 /usr/local/share/examples/cfortran/f20/f20.C -> f20.c 3442418 0 lrwxrwxrwx 1 8290 1300 5 29 jul 1998 /usr/local/share/examples/cfortran/f27/f27.C -> f27.c 3442420 0 lrwxrwxrwx 1 8290 1300 4 15 déc 1995 /usr/local/share/examples/cfortran/fa/fa.C -> fa.c >How-To-Repeat: - Install lang/cfortran - find /usr/local/share/examples/cfortran -type l -ls >Fix: Add -h to chown, so that COPYTREE_SHARE will handle symbolic links. I have no example of this bug for COPYTREE_BIN, but guess it should be handled in the same way. Note: gahr@ is Cc:'ed because if this patch get committed, at least PORTREVISION of lang/cfortran should be bumped. --- bsd.port.mk.diff begins here --- --- Mk/bsd.port.mk.orig 2012-10-28 16:10:33.000000000 +0100 +++ Mk/bsd.port.mk 2012-11-24 17:36:25.000000000 +0100 @@ -2386,12 +2386,12 @@ .if ${UID} == 0 COPYTREE_BIN= ${SH} -c '(${FIND} -d $$0 $$2 | ${CPIO} -dumpl $$1 >/dev/null \ 2>&1) && \ - ${CHOWN} -R ${BINOWN}:${BINGRP} $$1 && \ + ${CHOWN} -Rh ${BINOWN}:${BINGRP} $$1 && \ ${FIND} -d $$0 $$2 -type d -exec chmod 755 $$1/{} \; && \ ${FIND} -d $$0 $$2 -type f -exec chmod ${BINMODE} $$1/{} \;' -- COPYTREE_SHARE= ${SH} -c '(${FIND} -d $$0 $$2 | ${CPIO} -dumpl $$1 >/dev/null \ 2>&1) && \ - ${CHOWN} -R ${SHAREOWN}:${SHAREGRP} $$1 && \ + ${CHOWN} -Rh ${SHAREOWN}:${SHAREGRP} $$1 && \ ${FIND} -d $$0 $$2 -type d -exec chmod 755 $$1/{} \; && \ ${FIND} -d $$0 $$2 -type f -exec chmod ${SHAREMODE} $$1/{} \;' -- .else --- bsd.port.mk.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted: