From owner-svn-ports-all@FreeBSD.ORG Fri Dec 20 20:00:55 2013 Return-Path: Delivered-To: svn-ports-all@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 9EF41D1; Fri, 20 Dec 2013 20:00:55 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (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 70F7915E7; Fri, 20 Dec 2013 20:00:55 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id rBKK0tG3017718; Fri, 20 Dec 2013 20:00:55 GMT (envelope-from adamw@svn.freebsd.org) Received: (from adamw@localhost) by svn.freebsd.org (8.14.7/8.14.7/Submit) id rBKK0tw3017716; Fri, 20 Dec 2013 20:00:55 GMT (envelope-from adamw@svn.freebsd.org) Message-Id: <201312202000.rBKK0tw3017716@svn.freebsd.org> From: Adam Weinberger Date: Fri, 20 Dec 2013 20:00:55 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r337087 - in head/shells/bash-completion: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Dec 2013 20:00:55 -0000 Author: adamw Date: Fri Dec 20 20:00:54 2013 New Revision: 337087 URL: http://svnweb.freebsd.org/changeset/ports/337087 Log: Fix staging as non-root. Submitted by: Anton Yuzhaninov While I'm here, convert bash selection to OPTIONS. Added: head/shells/bash-completion/files/patch-Makefile.am (contents, props changed) Modified: head/shells/bash-completion/Makefile Modified: head/shells/bash-completion/Makefile ============================================================================== --- head/shells/bash-completion/Makefile Fri Dec 20 19:55:29 2013 (r337086) +++ head/shells/bash-completion/Makefile Fri Dec 20 20:00:54 2013 (r337087) @@ -10,14 +10,12 @@ MASTER_SITES= http://bash-completion.ali MAINTAINER= adamw@FreeBSD.org COMMENT= Programmable completion library for Bash -.if defined(WITH_BASH_DEVEL) -RUN_DEPENDS=bash:${PORTSDIR}/shells/bash-devel -.else -RUN_DEPENDS=bash:${PORTSDIR}/shells/bash -.endif +OPTIONS_DEFINE= BASH_DEVEL +BASH_DEVEL_DESC= Use shells/bash-devel instead of shells/bash CONFLICTS= bash-completion-classic-[0-9]* +USE_AUTOTOOLS= aclocal automake GNU_CONFIGURE= yes USE_GMAKE= yes @@ -26,7 +24,15 @@ USE_BZIP2= yes SUB_FILES= pkg-message SUB_LIST+= RUNFILE=${DATADIR}/bash_completion.sh -post-patch: +.include + +.if ${PORT_OPTIONS:MBASH_DEVEL} +RUN_DEPENDS=bash:${PORTSDIR}/shells/bash-devel +.else +RUN_DEPENDS=bash:${PORTSDIR}/shells/bash +.endif + +post-configure: @${REINPLACE_CMD} -e 's|/usr/local|${PREFIX}|g; \ s|/etc/bash_completion|${PREFIX}&|g; \ s|/usr\(/sbin/postconf\)|${PREFIX}\1|g; \ Added: head/shells/bash-completion/files/patch-Makefile.am ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/shells/bash-completion/files/patch-Makefile.am Fri Dec 20 20:00:54 2013 (r337087) @@ -0,0 +1,13 @@ +--- Makefile.am.orig 2013-12-20 13:44:12.000000000 -0500 ++++ Makefile.am 2013-12-20 13:44:17.000000000 -0500 +@@ -20,8 +20,10 @@ + .dir-locals.el + + install-data-hook: ++ chmod 644 $(DESTDIR)$(pkgdatadir)/bash_completion + tmpfile=`mktemp $${TMPDIR:-/tmp}/bash_completion.XXXXXX` && \ + sed -e 's|=/etc/bash_completion\.d|=$(compatdir)|' \ + $(DESTDIR)$(pkgdatadir)/bash_completion > $$tmpfile && \ + cat $$tmpfile > $(DESTDIR)$(pkgdatadir)/bash_completion && \ + rm $$tmpfile ++ chmod 444 $(DESTDIR)$(pkgdatadir)/bash_completion