From dm@home.dinoex.sub.org  Tue Jul 31 02:45:55 2001
Return-Path: <dm@home.dinoex.sub.org>
Received: from net2.dinoex.sub.org (net2.dinoex.de [212.184.201.182])
	by hub.freebsd.org (Postfix) with ESMTP id EB02137B401
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 31 Jul 2001 02:45:48 -0700 (PDT)
	(envelope-from dm@home.dinoex.sub.org)
Received: from home.dinoex.sub.org (home [217.6.200.196])
	by net2.dinoex.sub.org (8.11.4/8.11.4) with ESMTP id f6V9jc802800
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 31 Jul 2001 11:45:39 +0200 (CEST)
	(envelope-from dm@home.dinoex.sub.org)
Received: (from dm@localhost)
	by home.dinoex.sub.org (8.11.4/8.11.4) id f6V9hJ914839; Tue, 31 Jul 2001 11:43:19 +0200 (CEST)
	(envelope-from dm)
Message-Id: <200107310943.f6V9hJ914839@home.dinoex.sub.org>
Date: Tue, 31 Jul 2001 11:43:19 +0200 (CEST)
From: dirk.meyer@dinoex.sub.org
Reply-To: dirk.meyer@dinoex.sub.org
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: audio/esound fails with -ansi
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         29347
>Category:       ports
>Synopsis:       audio/esound fails with -ansi
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    dinoex
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jul 31 02:50:01 PDT 2001
>Closed-Date:    Wed Aug 1 05:42:12 PDT 2001
>Last-Modified:  Sun Jul 07 02:01:50 PDT 2002
>Originator:     Dirk Meyer
>Release:        FreeBSD 4.3-STABLE i386
>Organization:
privat
>Environment:

System: FreeBSD 4.3-STABLE: Fri Jul 20 22:04:45 CEST 2001 i386

/etc/make.conf:
CFLAGS+= -pipe -Wall
CFLAGS+=${BDECFLAGS}

>Description:

	port fails to compile, if "-ansi" is set.

>How-To-Repeat:

	cd /usr/ports/audio/esound && make
[...]
cc -DHAVE_CONFIG_H -I. -I. -I. -I/usr/local/include -DSYSCONFDIR=\"/usr/local/et
c\" -O -pipe -pipe -Wall -W -Wall -ansi -pedantic -Wbad-function-cast -Wcast-ali
gn -Wcast-qual -Wchar-subscripts -Wconversion -Winline -Wmissing-prototypes -Wne
sted-externs -Wpointer-arith -Wredundant-decls -Wshadow -Wstrict-prototypes -Wwr
ite-strings -c genrand.c  -fPIC -DPIC -o .libs/genrand.lo
genrand.c: In function `genrand_dev':
genrand.c:50: warning: passing arg 3 of `read' as unsigned due to prototype
genrand.c:44: warning: unused variable `curbuf'
genrand.c:43: warning: unused variable `readlen'
genrand.c: In function `handle_alarm':
genrand.c:64: warning: unused parameter `signum'
genrand.c: At top level:
genrand.c:69: syntax error before `unsigned'
genrand.c:71: warning: no previous prototype for `hashlong'
genrand.c: In function `hashlong':
genrand.c:75: warning: comparison between signed and unsigned
genrand.c:72: warning: `retval' might be used uninitialized in this function
genrand.c: In function `genrand_unix':
genrand.c:103: warning: unused variable `mycount'
*** Error code 1

>Fix:

	add in Makefile.local or Makefile

CFLAGS:= ${CFLAGS:S/-ansi//g}

cc -DHAVE_CONFIG_H -I. -I. -I. -I/usr/local/include -DSYSCONFDIR=\"/usr/local/et
c\" -O -pipe -pipe -Wall -W -Wall -pedantic -Wbad-function-cast -Wcast-align -Wc
ast-qual -Wchar-subscripts -Wconversion -Winline -Wmissing-prototypes -Wnested-e
xterns -Wpointer-arith -Wredundant-decls -Wshadow -Wstrict-prototypes -Wwrite-st
rings -c genrand.c  -fPIC -DPIC -o .libs/genrand.lo
genrand.c: In function `genrand_dev':
genrand.c:50: warning: passing arg 3 of `read' as unsigned due to prototype
genrand.c:44: warning: unused variable `curbuf'
genrand.c:43: warning: unused variable `readlen'
genrand.c: In function `handle_alarm':
genrand.c:64: warning: unused parameter `signum'
genrand.c: At top level:
genrand.c:69: warning: ANSI does not permit the keyword `inline'
genrand.c: In function `hashlong':
genrand.c:75: warning: comparison between signed and unsigned
genrand.c: In function `genrand_unix':
genrand.c:103: warning: unused variable `mycount'
genrand.c:72: warning: `retval' might be used uninitialized in this function

>Release-Note:
>Audit-Trail:

From: Maxim Sobolev <sobomax@FreeBSD.org>
To: dirk.meyer@dinoex.sub.org
Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: Re: ports/29347: audio/esound fails with -ansi
Date: Wed, 01 Aug 2001 14:48:01 +0300

 dirk.meyer@dinoex.sub.org wrote:
 
 >         port fails to compile, if "-ansi" is set.
 
 I wonder what do you expect us to do in this case. There are thousand  ports in our
 collection that wouldn't compile with `-ansi' and it is unreasonably to expect that
 somebody will fix 'em all, or even smal fraction of them. Do you understand that
 even if we'd fix some of them somebody will need to maintain and update those
 patches from release to release, which IMO is not something that the Project can
 afford?
 
 If you are really concerned, please contact authors of packages in question and try
 to convice them instead. Sorry, I'm just trying to be realistic.
 
 -Maxim
 

From: dirk.meyer@dinoex.sub.org (Dirk Meyer)
To: FreeBSD-gnats-submit@FreeBSD.ORG, sobomax@FreeBSD.org
Cc:  
Subject: Re: ports/29347: audio/esound fails with -ansi
Date: Wed, 01 Aug 2001 14:10:12 +0200

 Maxim Sobolev schrieb:,
 
 > >         port fails to compile, if "-ansi" is set.
 > 
 > I wonder what do you expect us to do in this case. There are thousand  ports i
 > n our collection that wouldn't compile with `-ansi' and it is unreasonably to
 > expect that somebody will fix 'em all, or even smal fraction of them.
 
 out on 225 ports I have compiled, I found only 5 which given an
 error (not only a warning).
 
 > even if we'd fix some of them somebody will need to maintain and update those
 > patches from release to release, [...]
 
 No I don't think that is necessary, No source should be changed.
 Just if some ports known to fail with some opions,
 we can have a single Line in the Makefile:
 
 CFLAGS:= ${CFLAGS:S/-ansi//g}	# port doesn't compile with -ansi.
 
 That is all we can/might do,
 
 kind regards Dirk
 
 - Dirk Meyer, Im Grund 4, 34317 Habichtswald, Germany

From: Maxim Sobolev <sobomax@FreeBSD.org>
To: Dirk Meyer <dirk.meyer@dinoex.sub.org>
Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: Re: ports/29347: audio/esound fails with -ansi
Date: Wed, 01 Aug 2001 15:30:36 +0300

 Dirk Meyer wrote:
 
 > Maxim Sobolev schrieb:,
 >
 > > >         port fails to compile, if "-ansi" is set.
 > >
 > > I wonder what do you expect us to do in this case. There are thousand  ports i
 > > n our collection that wouldn't compile with `-ansi' and it is unreasonably to
 > > expect that somebody will fix 'em all, or even smal fraction of them.
 >
 > out on 225 ports I have compiled, I found only 5 which given an
 > error (not only a warning).
 
 Gmmm, ok, I was probably thinking of BDEFLAGS coupled with -Werror, which is a
 totall killer.:)
 
 > > even if we'd fix some of them somebody will need to maintain and update those
 > > patches from release to release, [...]
 >
 > No I don't think that is necessary, No source should be changed.
 > Just if some ports known to fail with some opions,
 > we can have a single Line in the Makefile:
 >
 > CFLAGS:= ${CFLAGS:S/-ansi//g}   # port doesn't compile with -ansi.
 >
 > That is all we can/might do,
 
 Well, Ok then. It was really not very clear from your PR.  :-/
 
 Though I am not very fond of it because `-pipe -O' is what we support for CFLAGS -
 all other options are completely unsupported and should be a user's problem if
 he/she want to use them. CFLAGS:= ${CFLAGS:S/-ansi//g}might give a wrong impression
 that we support -ansi, while we don't and probably will not.
 
 -Maxim
 
State-Changed-From-To: open->closed 
State-Changed-By: dinoex 
State-Changed-When: Wed Aug 1 05:42:12 PDT 2001 
State-Changed-Why:  
My problem, no action. 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=29347 
>Unformatted:
