From dan.naumov@ofw.fi  Thu Apr 10 17:25:44 2003
Return-Path: <dan.naumov@ofw.fi>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 3D1CC37B401
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 10 Apr 2003 17:25:44 -0700 (PDT)
Received: from MAILSERVER.ofw.fi (ns.ofw.fi [194.111.144.200])
	by mx1.FreeBSD.org (Postfix) with ESMTP id CFFB143F93
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 10 Apr 2003 17:25:42 -0700 (PDT)
	(envelope-from dan.naumov@ofw.fi)
Received: from [172.16.161.81] by MAILSERVER.ofw.fi (NTMail 7.00.0022/NT1439.00.90501b21) with ESMTP id qjjgjaaa for FreeBSD-gnats-submit@freebsd.org; Fri, 11 Apr 2003 03:24:44 +0300
Message-Id: <20030411032931.10b964e7.dan.naumov@ofw.fi>
Date: Fri, 11 Apr 2003 03:29:31 +0300
From: Dan Naumov <dan.naumov@ofw.fi>
To: FreeBSD-gnats-submit@freebsd.org
Subject: audio/faad does not build

>Number:         50798
>Category:       ports
>Synopsis:       audio/faad does not build
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Apr 10 17:30:07 PDT 2003
>Closed-Date:    Sat Jul 12 13:51:46 PDT 2003
>Last-Modified:  Sat Jul 12 13:51:46 PDT 2003
>Originator:     Dan Naumov
>Release:        
>Organization:
none, home user
>Environment:
FreeBSD localhost.localdomain 5.0-RELEASE-p7 FreeBSD 5.0-RELEASE-p7 #0:
Mon Apr  7 05:17:14 EEST 2003
root@localhost.localdomain:/usr/obj/usr/src/sys/JAGO  i386
>Description:
Building audio/faad results in:

=======================================
===>  Extracting for faad2-1.1
>How-To-Repeat:
cd /usr/ports/audio/faad
make install

>Fix:
>Release-Note:
>Audit-Trail:

From: Dan Naumov <dan.naumov@ofw.fi>
To: freebsd-gnats-submit@FreeBSD.org
Cc:  
Subject: RE: ports/50798: audio/faad does not build
Date: Fri, 11 Apr 2003 03:46:05 +0300

 Gah, sorry for the horrible formatting. I have to fix my mail client.
 
 --
 Dan Naumov <dan.naumov [at] ofw.fi>

From: Martin.Kaeske@Stud.TU-Ilmenau.DE
To: freebsd-gnats-submit@FreeBSD.org, dan.naumov@ofw.fi
Cc:  
Subject: Re: ports/50798: audio/faad does not build
Date: Mon, 14 Apr 2003 13:14:55 +0200 (CEST)

 Hello,
 You have to have automake-1.5 installed because faad's Makefile contains
 "USE_AUTOMAKE_VER=15". I have no idea why it is not installed as a 
 dependency. If i try to build faad everything works fine (automake-1.5
 build as dependency).
 
 HTH
 Martin
 

From: Dan Naumov <dan.naumov@ofw.fi>
To: Martin.Kaeske@Stud.TU-Ilmenau.DE
Cc: freebsd-gnats-submit@FreeBSD.org
Subject: Re: ports/50798: audio/faad does not build
Date: Mon, 14 Apr 2003 15:09:22 +0300

 With no automake 1.5 installed, this is what happens:
 
 ===================================
 localhost# pkg_info | grep automake
 automake14-1.4.5_9  GNU Standards-compliant Makefile generator
 
 localhost# pwd
 /usr/ports/audio/faad
 
 localhost# make install clean
 ===>  Extracting for faad2-1.1
 >> Checksum OK for faad2-1.1.tar.gz.
 ===>  Patching for faad2-1.1
 ===>  Applying FreeBSD patches for faad2-1.1
 aclocal: not found
 *** Error code 127
 
 Stop in /usr/ports/audio/faad.
 ===================================
 
 It doesn't even try to install automake... With automake15 installed
 (manually through ports), the faad2 port seems to build though... Do you
 have any idea why it would fail to see automake 1.5 as a dependancy ?
 
 Sincerely,
 -- 
 Dan Naumov <dan.naumov [at] ofw.fi>
State-Changed-From-To: open->closed 
State-Changed-By: arved 
State-Changed-When: Mon Apr 14 05:21:58 PDT 2003 
State-Changed-Why:  
You probably had a stale file named /usr/local/bin/automake on your system. 

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

From: Martin Kaeske <Martin.Kaeske@Stud.TU-Ilmenau.DE>
To: Dan Naumov <dan.naumov@ofw.fi>
Cc: freebsd-gnats-submit@freebsd.org, sean@sfarc.net
Subject: Re: ports/50798: audio/faad does not build
Date: Mon, 14 Apr 2003 17:14:17 +0200

 On Mon, Apr 14, 2003 at 03:09:22PM +0300, Dan Naumov wrote:
 > With no automake 1.5 installed, this is what happens:
 [SNIP] 
 > localhost# make install clean
 > ===>  Extracting for faad2-1.1
 > >> Checksum OK for faad2-1.1.tar.gz.
 > ===>  Patching for faad2-1.1
 > ===>  Applying FreeBSD patches for faad2-1.1
 > aclocal: not found
 > *** Error code 127
 > 
 > Stop in /usr/ports/audio/faad.
 > ===================================
 
 I think i found the solution. audio/faad uses aclocal during the
 post-patch target. If you use "USE_AUTOMAKE_VER" the appropriate
 port is added to the variable BUILD_DEPENDS (devel/automake in our
 case) but the build-depends are checked _after_ "make patch"
 (build-depends are actually part of the configure target).
 The reason why it worked for me was that i did "make patch" before
 deinstalling automake-1.5, because i thought it would be a configure
 problem.
 
 So the solution is to add "automake" to faad's PATCH_DEPENDS or to
 add "automake" to PATCH_DEPENDS in bsd.port.mk. I prefer the former
 because i often want to just look at the source of a tool without
 compiling any "unnecessary" dependencies.
 
 The only other port that has the same problem is www/tidy-devel (if
 compiled with -DWITH_SHLIB).
 
 Martin
 
 
 PS: i make a CC for the maintainer to let him know about the
     problem
 -- 
 "At the beginning of the week, we sealed ten BSD programmers into a
  computer room with a single distribution of BSD Unix. Upon opening
  the room after seven days, we found all ten programmers dead,
  clutching each others throats, and thirteen new flavors of BSD."
State-Changed-From-To: closed->analyzed 
State-Changed-By: arved 
State-Changed-When: Tue Apr 15 04:18:28 PDT 2003 
State-Changed-Why:  
reopen on request of Martin Kaeske.  
Possible solution: Autoconf is required as PATCH_DEPENDS 

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

From: Dan Naumov <dan.naumov@ofw.fi>
To: freebsd-gnats-submit@FreeBSD.org
Cc:  
Subject: Re: ports/50798: audio/faad does not build
Date: Thu, 17 Apr 2003 15:10:52 +0300

 This minor patch to the Makefile should fix things:
 
 diff -ruN faad.orig/Makefile faad/Makefile
 --- faad.orig/Makefile	Thu Apr 17 15:04:22 2003
 +++ faad/Makefile	Thu Apr 17 15:06:35 2003
 @@ -16,6 +16,8 @@
  LIB_DEPENDS=	sndfile.1:${PORTSDIR}/audio/libsndfile \
  		gnugetopt.1:${PORTSDIR}/devel/libgnugetopt
  
 +PATCH_DEPENDS=	aclocal:${PORTSDIR}/devel/automake
 +
  WRKSRC=		${WRKDIR}/${PORTNAME}
  
  USE_AUTOMAKE_VER= 15

From: Sean McGovern <sean@sfarc.net>
To: freebsd-gnats-submit@FreeBSD.org, dan.naumov@ofw.fi
Cc:  
Subject: Re: ports/50798: audio/faad does not build
Date: Thu, 17 Apr 2003 08:21:11 -0400

 Is the patch phase considered too early to call aclocal? I wonder if 
 this can be done pre-configure... is the automake dependency brought in 
 at that point?
 

From: Martin.Kaeske@Stud.TU-Ilmenau.DE
To: freebsd-gnats-submit@FreeBSD.org, dan.naumov@ofw.fi
Cc: sean@sfarc.net
Subject: Re: ports/50798: audio/faad does not build
Date: Tue, 29 Apr 2003 14:06:33 +0200 (CEST)

 You can use aclocal during post-patch if you add it to PATCH_DEPENDS :).
 Since the BUILD_DEPENDS are evaluated before pre-configure it seems to
 be safe to call aclocal pre-configure. I tried this and sadly it failed,
 because patch-libtool is executed directly after patch and patch-libtool
 needs aclocal.m4 to work. I've looked at some other ports and they have
 aclocal.m4 in there source (i.e. in the distfile) so they don't have this
 problem.
 I'd suggest you apply Dan's patch to circumvent the bug. Nevertheless i
 think its quite confusing to have USE_AUTOMAKE in the Makefile and it 
 take effect somewhere in between the whole make process. Maybe this is
 done on purpose and means that the program itself needs automake not the 
 ports-framework around it.
 
 HTH
 Martin
 
State-Changed-From-To: analyzed->feedback 
State-Changed-By: osa 
State-Changed-When: Fri Jul 11 13:43:27 PDT 2003 
State-Changed-Why:  
Looks like at this time faad2 port builds fine, 
isn't it? 
Also I have a little patch for change MASTER_SITES 
from old to ${MASTER_SITE_SOURCEFORGE} with 
MASTER_SITE_SUBDIR=faac. 


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

From: Sean McGovern <sean@sfarc.net>
To: freebsd-gnats-submit@FreeBSD.org, dan.naumov@ofw.fi
Cc:  
Subject: Re: ports/50798: audio/faad does not build
Date: Fri, 11 Jul 2003 17:05:13 -0400

 Here is a patch to audio/faad/Makefile that should fix building.
 
 Index: ports/audio/faad/Makefile
 ===================================================================
 RCS file: /home/pcvs/ports/audio/faad/Makefile,v
 retrieving revision 1.5
 diff -u -r1.5 Makefile
 --- ports/audio/faad/Makefile	26 Jun 2003 22:58:22 -0000	1.5
 +++ ports/audio/faad/Makefile	11 Jul 2003 20:49:20 -0000
 @@ -9,19 +9,20 @@
   PORTVERSION=	1.1
   PORTREVISION=	1
   CATEGORIES=	audio
 -MASTER_SITES=	http://faac.sourceforge.net/files/
 +MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
 +MASTER_SITE_SUBDIR=	faac
 
   MAINTAINER=	sean@sfarc.net
   COMMENT=	A LC, MAIN and LTP profile, MPEG2 and MPEG-4 AAC decoder
 
 -LIB_DEPENDS=	sndfile.1:${PORTSDIR}/audio/libsndfile \
 -		gnugetopt.1:${PORTSDIR}/devel/libgnugetopt
 +LIB_DEPENDS=	sndfile.1:${PORTSDIR}/audio/libsndfile
 
   WRKSRC=		${WRKDIR}/${PORTNAME}
 
   USE_AUTOMAKE_VER= 15
   AUTOMAKE_ARGS=	--add-missing
 
 +USE_GETOPT_LONG=	yes
   GNU_CONFIGURE=	yes
   USE_GMAKE=	yes
   USE_LIBTOOL=	yes
 
State-Changed-From-To: feedback->closed 
State-Changed-By: osa 
State-Changed-When: Sat Jul 12 13:51:12 PDT 2003 
State-Changed-Why:  
Committed, thanks. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=50798 
>Unformatted:
 >> Checksum OK for faad2-1.1.tar.gz.
 ===>  Patching for faad2-1.1
 ===>  Applying FreeBSD patches for faad2-1.1
 aclocal: not found
 *** Error code 127
 
 Stop in /usr/ports/audio/faad.
 =======================================
 
 =======================================
 localhost# pkg_info | grep automake
 automake14-1.4.5_9  GNU Standards-compliant Makefile generator
 =======================================
 
 =======================================
 localhost# pkg_info -L automake14-1.4.5_9 | grep bin/aclocal
 /usr/local/bin/aclocal14
 =======================================
 
