From nobody@FreeBSD.org  Wed Sep  7 21:22:43 2011
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 EC2301065677
	for <freebsd-gnats-submit@FreeBSD.org>; Wed,  7 Sep 2011 21:22:43 +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 DC4D78FC08
	for <freebsd-gnats-submit@FreeBSD.org>; Wed,  7 Sep 2011 21:22:43 +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 p87LMhCf059886
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 7 Sep 2011 21:22:43 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.4/8.14.4/Submit) id p87LMhab059879;
	Wed, 7 Sep 2011 21:22:43 GMT
	(envelope-from nobody)
Message-Id: <201109072122.p87LMhab059879@red.freebsd.org>
Date: Wed, 7 Sep 2011 21:22:43 GMT
From: Rene Ladan <rene@FreeBSD.org>
To: freebsd-gnats-submit@FreeBSD.org
Subject: sysutils/lsof: build fails with clang
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         160544
>Category:       ports
>Synopsis:       sysutils/lsof: build fails with clang
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    rene
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Sep 07 21:30:07 UTC 2011
>Closed-Date:    Thu Jan 03 11:23:05 UTC 2013
>Last-Modified:  Thu Jan 03 11:23:05 UTC 2013
>Originator:     Rene Ladan
>Release:        9.0-BETA2 amd64
>Organization:
>Environment:
FreeBSD acer 9.0-BETA2 FreeBSD 9.0-BETA2 #0 r225237M: Mon Aug 29 01:10:18 CEST 2011     rene@acer:/usr/obj/usr/src/sys/ACER  amd64

>Description:
Using the clang built into FreeBSD 9.0 (clang r135360), do:

# cd /usr/ports/sysutils/lsof
# env CC=clang CXX=clang++  make

..
In file included from dvch.c:43:
In file included from ./../lsof.h:195:
In file included from ./../dlsof.h:432:
In file included from /usr/include/string.h:45:
/usr/include/strings.h:47:6: error: conflicting types for '__builtin_ffs'
int      ffs(int) __pure2;
         ^
/usr/include/machine/cpufunc.h:140:24: note: expanded from:
#define        ffs(x)  __builtin_ffs(x)
                       ^
/usr/include/strings.h:47:6: note: '__builtin_ffs' is a builtin with type 'int (unsigned int)'
In file included from ckkv.c:43:
In file included from ./../lsof.h:195:
In file included from ./../dlsof.h:432:
In file included from /usr/include/string.h:45:
/usr/include/strings.h:47:6: error: conflicting types for '__builtin_ffs'
int      ffs(int) __pure2;
         ^
/usr/include/machine/cpufunc.h:140:24: note: expanded from:
#define        ffs(x)  __builtin_ffs(x)
                       ^
/usr/include/strings.h:47:6: note: '__builtin_ffs' is a builtin with type 'int (unsigned int)'
..

In file included from dmnt.c:39:
In file included from ./lsof.h:195:
In file included from ./dlsof.h:432:
In file included from /usr/include/string.h:45:
/usr/include/strings.h:47:6: error: conflicting types for '__builtin_ffs'
int      ffs(int) __pure2;
         ^
/usr/include/machine/cpufunc.h:140:24: note: expanded from:
#define        ffs(x)  __builtin_ffs(x)
                       ^
/usr/include/strings.h:47:6: note: '__builtin_ffs' is a builtin with type 'int (unsigned int)'

The port builds fine with GCC 4.2.1 on the same machine.
>How-To-Repeat:

>Fix:
not known.

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-ports-bugs 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Thu Sep 8 05:59:56 UTC 2011 
Responsible-Changed-Why:  
reclassify. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=160544 
Responsible-Changed-From-To: freebsd-ports-bugs->rene 
Responsible-Changed-By: rene 
Responsible-Changed-When: Mon Sep 12 21:39:26 UTC 2011 
Responsible-Changed-Why:  
Manually assign to myself, maintainer is not a committer 

http://www.freebsd.org/cgi/query-pr.cgi?pr=160544 
State-Changed-From-To: open->feedback 
State-Changed-By: rene 
State-Changed-When: Mon Sep 12 21:44:53 UTC 2011 
State-Changed-Why:  
Awaiting maintainer feedback, "forged" edwin-mail sent. 

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

From: Larry Rosenman <ler@lerctr.org>
To: bug-followup@freebsd.org, rene@freebsd.org
Cc:  
Subject: Re: ports/160544: sysutils/lsof: build fails with clang
Date: Mon, 14 May 2012 15:28:34 -0500

 --f46d04430414602e8304c004ef2e
 Content-Type: text/plain; charset=ISO-8859-1
 
 Just as a follow-up as maintainer, this looks to me like a CLANG error in
 how the builtin for ffs is described.
 
 
 Both Vic Abell (Author) and myself (Maintainer) refuse to support CLANG for
 this port until the system headers and clang headers
 are consistent.
 
 I've whined about this before and was shot down.
 
 We will NOT change this stance until the headers are consistent.
 
 I'm willing to help as much as possible, but have little understanding of
 why the ffs signature is different.
 
 -- 
 Larry Rosenman                     http://www.lerctr.org/~ler
 Phone: +1 512-248-2683                 E-Mail: ler@lerctr.org
 US Mail: 430 Valona Loop, Round Rock, TX 78681-3893
 
 --f46d04430414602e8304c004ef2e
 Content-Type: text/html; charset=ISO-8859-1
 Content-Transfer-Encoding: quoted-printable
 
 Just as a follow-up as maintainer, this looks to me like a CLANG error in h=
 ow the builtin for ffs is described.<br clear=3D"all"><div><br></div><div><=
 br></div><div>Both Vic Abell (Author) and myself (Maintainer) refuse to sup=
 port CLANG for this port until the system headers and clang headers</div>
 
 <div>are consistent.</div><div><br></div><div>I&#39;ve whined about this be=
 fore and was shot down.</div><div><br></div><div>We will NOT change this st=
 ance until the headers are consistent.=A0</div><div><br></div><div>I&#39;m =
 willing to help as much as possible, but have little understanding of why t=
 he ffs signature is different.</div>
 
 <div><br></div>-- <br>Larry Rosenman=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0=
 =A0 <a href=3D"http://www.lerctr.org/~ler">http://www.lerctr.org/~ler</a><b=
 r>Phone: +1 512-248-2683=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0=A0 E-Mail: <a href=
 =3D"mailto:ler@lerctr.org">ler@lerctr.org</a><br>
 
 US Mail: 430 Valona Loop, Round Rock, TX 78681-3893<br>
 <br>
 
 --f46d04430414602e8304c004ef2e--

From: Larry Rosenman <ler@lerctr.org>
To: bug-followup@freebsd.org, rene@freebsd.org
Cc:  
Subject: Re: ports/160544: sysutils/lsof: build fails with clang
Date: Sun, 25 Nov 2012 13:56:46 -0600

 --f46d042f948aa5612904cf5738fc
 Content-Type: text/plain; charset=ISO-8859-1
 
 On current FreeBSD 10-CURRENT CLANG can now be used.
 
 We get some warnings, and Vic Abell is aware of them.
 
 Do we want to change the workaround?
 
 
 -- 
 Larry Rosenman                     http://www.lerctr.org/~ler
 Phone: +1 512-248-2683                 E-Mail: ler@lerctr.org
 US Mail: 430 Valona Loop, Round Rock, TX 78681-3893
 
 --f46d042f948aa5612904cf5738fc
 Content-Type: text/html; charset=ISO-8859-1
 Content-Transfer-Encoding: quoted-printable
 
 <br clear=3D"all"><div>On current FreeBSD 10-CURRENT CLANG can now be used.=
 </div><div><br></div><div>We get some warnings, and Vic Abell is aware of t=
 hem. =A0</div><div><br></div><div>Do we want to change the workaround?</div=
 >
 
 <div><br></div><div><br></div>-- <br>Larry Rosenman =A0 =A0 =A0 =A0 =A0 =A0=
  =A0 =A0 =A0 =A0 <a href=3D"http://www.lerctr.org/~ler">http://www.lerctr.o=
 rg/~ler</a><br>Phone: +1 512-248-2683 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 E-Mai=
 l: <a href=3D"mailto:ler@lerctr.org">ler@lerctr.org</a><br>
 
 US Mail: 430 Valona Loop, Round Rock, TX 78681-3893<br>
 
 --f46d042f948aa5612904cf5738fc--
State-Changed-From-To: feedback->closed 
State-Changed-By: rene 
State-Changed-When: Thu Jan 3 11:22:39 UTC 2013 
State-Changed-Why:  
Superceded by ports/174906 

http://www.freebsd.org/cgi/query-pr.cgi?pr=160544 
>Unformatted:
