From nobody@FreeBSD.org  Sun Jan 29 18:48:27 2012
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id D85C1106564A
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 29 Jan 2012 18:48:27 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id C7B888FC0A
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 29 Jan 2012 18:48:27 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.4/8.14.4) with ESMTP id q0TImRHW000435
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 29 Jan 2012 18:48:27 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.4/8.14.4/Submit) id q0TImRon000434;
	Sun, 29 Jan 2012 18:48:27 GMT
	(envelope-from nobody)
Message-Id: <201201291848.q0TImRon000434@red.freebsd.org>
Date: Sun, 29 Jan 2012 18:48:27 GMT
From: Ryan Steinmetz <zi@FreeBSD.org>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [patch] Add option to devel/ccache to statically build ccache
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         164606
>Category:       ports
>Synopsis:       [patch] Add option to devel/ccache to statically build ccache
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    ehaupt
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Sun Jan 29 18:50:13 UTC 2012
>Closed-Date:    Mon Jan 30 09:39:07 CET 2012
>Last-Modified:  Mon Jan 30 08:40:10 UTC 2012
>Originator:     Ryan Steinmetz
>Release:        9.0-RELEASE
>Organization:
Rochester Institute of Technology
>Environment:
>Description:
When using tinderbox, having a statically built copy of ccache is ideal as the same shared libraries do not exist under FreeBSD 7, 8, 9 and 10.

Most users of tinderbox build ccache under each jail, which is time consuming.  This will allow one copy of ccache to be usable regardless of which jail is used.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/devel/ccache/Makefile,v
retrieving revision 1.67
diff -u -r1.67 Makefile
--- Makefile	8 Jan 2012 21:16:53 -0000	1.67
+++ Makefile	29 Jan 2012 18:45:07 -0000
@@ -26,7 +26,8 @@
 PORTDOCS=	ccache-howto-freebsd.txt MANUAL.html
 
 OPTIONS=	CLANGLINK	"Create clang compiler links if clang is installed" off \
-		LLVMLINK	"Create llvm compiler links if llvm is installed" off
+		LLVMLINK	"Create llvm compiler links if llvm is installed" off \
+		STATIC		"Statically build ccache" off
 
 .include <bsd.port.pre.mk>
 
@@ -47,6 +48,10 @@
 CCACHE_COMPILERS+=	llvm-gcc llvm-c++ llvm-g++
 .endif
 
+.if defined(WITH_STATIC)
+LDFLAGS+=		"--static"
+.endif
+
 CCACHE_COMPILERS+=	${EXTRA_COMPILERS}
 SUB_LIST+=	CCACHE_COMPILERS="${CCACHE_COMPILERS}" \
 		CCLINKDIR="${CCLINKDIR}" \


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->ehaupt 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Sun Jan 29 18:50:28 UTC 2012 
Responsible-Changed-Why:  
Over to maintainer (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=164606 
State-Changed-From-To: open->closed 
State-Changed-By: ehaupt 
State-Changed-When: Mon Jan 30 09:38:55 CET 2012 
State-Changed-Why:  
Great idea! Committed, thanks. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=164606 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/164606: commit references a PR
Date: Mon, 30 Jan 2012 08:38:53 +0000 (UTC)

 ehaupt      2012-01-30 08:38:40 UTC
 
   FreeBSD ports repository
 
   Modified files:
     devel/ccache         Makefile 
   Log:
   Add an option to statically build ccache.
   
   PR:             164606
   Submitted by:   zi
   
   Revision  Changes    Path
   1.68      +6 -1      ports/devel/ccache/Makefile
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
>Unformatted:
