Patched faac to support the new libsndfile-1.x API. Please comment on
authorNick Hadaway <raker@gentoo.org>
Wed, 6 Nov 2002 05:21:17 +0000 (05:21 +0000)
committerNick Hadaway <raker@gentoo.org>
Wed, 6 Nov 2002 05:21:17 +0000 (05:21 +0000)
bug #9827 regarding any application that is not libsndfile-1.x
compatible

media-libs/faac/ChangeLog
media-libs/faac/faac-26102001-r1.ebuild [new file with mode: 0644]
media-libs/faac/files/digest-faac-26102001-r1 [new file with mode: 0644]
media-libs/faac/files/libsndfile-1.0.diff [new file with mode: 0644]

index d4a86b3cc764e87c130a174587d86c02498c149c..83a928facef4dfddad164dc5680bec2f98cc3af6 100644 (file)
@@ -1,11 +1,17 @@
 # ChangeLog for media-libs/faac
 # Copyright 2002 Gentoo Technologies, Inc.; Distributed under the GPL
-# $Header: /var/cvsroot/gentoo-x86/media-libs/faac/ChangeLog,v 1.1 2002/06/18 21:24:37 rphillips Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/faac/ChangeLog,v 1.2 2002/11/06 05:21:16 raker Exp $
+
+*faac-26102001-r1 (05 Nov 2002)
+
+  05 Nov 2002; Nick Hadaway <raker@gentoo.org> faac-26102001-r1.ebuild,
+  files/digest-faac-26102001-r1, files/libsndfile-1.0.diff :
+  Updated ebuild to support the libsndfile-1.x series.  Only minor
+  changes were needed to support the new api.
 
 *faac-26102001 (18 Jun 2002)
 
   18 Jun 2002; Ryan Phillips <rphillips@gentoo.org> ChangeLog :
-  
   Added initial ChangeLog which should be updated whenever the package is
   updated in any way. This changelog is targetted to users. This means that the
   comments should well explained and written in clean English. The details about
diff --git a/media-libs/faac/faac-26102001-r1.ebuild b/media-libs/faac/faac-26102001-r1.ebuild
new file mode 100644 (file)
index 0000000..4a5f9e4
--- /dev/null
@@ -0,0 +1,45 @@
+# Copyright 1999-2002 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/faac/faac-26102001-r1.ebuild,v 1.1 2002/11/06 05:21:17 raker Exp $
+
+S=${WORKDIR}/faac
+DESCRIPTION="Free MPEG-4 audio codecs by AudioCoding.com"
+SRC_URI="http://faac.sourceforge.net/files/faac_src_26102001.zip"
+HOMEPAGE="http://faac.sourceforge.net/"
+
+SLOT="0"
+LICENSE="LGPL-2"
+KEYWORDS="x86 sparc sparc64"
+
+DEPEND=">=media-libs/libsndfile-1.0.0
+       >=sys-devel/libtool-1.3.5
+       sys-devel/autoconf
+       sys-devel/automake"
+
+src_unpack() {
+
+       unpack ${A}
+       sh ${FILESDIR}/fix-linefeeds.sh $S
+
+       cd ${S}
+       patch -p1 < ${FILESDIR}/libsndfile-1.0.diff || die "patch failed"
+
+}
+
+src_compile() {
+       aclocal -I .
+       autoheader
+       libtoolize --automake
+       automake --add-missing
+       autoconf
+
+       econf || die
+       emake || die
+}
+
+src_install() {
+
+       make DESTDIR=${D} install || die
+
+       dodoc AUTHORS COPYING ChangeLog INSTALL NEWS README TODO docs/libfaac.pdf
+}
diff --git a/media-libs/faac/files/digest-faac-26102001-r1 b/media-libs/faac/files/digest-faac-26102001-r1
new file mode 100644 (file)
index 0000000..1556bfa
--- /dev/null
@@ -0,0 +1 @@
+MD5 f26af3b37fa913154e47ad5522c459e0 faac_src_26102001.zip 563800
diff --git a/media-libs/faac/files/libsndfile-1.0.diff b/media-libs/faac/files/libsndfile-1.0.diff
new file mode 100644 (file)
index 0000000..8a36105
--- /dev/null
@@ -0,0 +1,43 @@
+diff -urN faac/frontend/main.c faac-modified/frontend/main.c
+--- faac/frontend/main.c       2002-11-05 23:02:47.000000000 -0600
++++ faac-modified/frontend/main.c      2002-11-05 23:13:01.000000000 -0600
+@@ -219,7 +219,7 @@
+     aacFileName = argv[optind++];
+ 
+     /* open the audio input file */
+-    infile = sf_open_read(audioFileName, &sfinfo);
++    infile = sf_open(audioFileName, SFM_READ, &sfinfo);
+     if (infile == NULL)
+     {
+         fprintf(stderr, "Couldn't open input file %s\n", audioFileName);
+@@ -263,7 +263,7 @@
+ #ifdef _WIN32
+         begin = GetTickCount();
+ #endif
+-        frames = (int)(sfinfo.samples/1024+0.5);
++        frames = (int)(sfinfo.frames/1024+0.5);
+         currentFrame = 0;
+ 
+         /* encoding loop */
+diff -urN faac/include/faac.h faac-modified/include/faac.h
+--- faac/include/faac.h        2002-11-05 23:02:47.000000000 -0600
++++ faac-modified/include/faac.h       2002-11-05 23:06:38.000000000 -0600
+@@ -116,4 +116,5 @@
+ }
+ #endif /* __cplusplus */
+ 
+-#endif /* FAACLIB_H */
+\ No newline at end of file
++#endif /* FAACLIB_H */
++
+diff -urN faac/libfaac/psych.h faac-modified/libfaac/psych.h
+--- faac/libfaac/psych.h       2002-11-05 23:02:47.000000000 -0600
++++ faac-modified/libfaac/psych.h      2002-11-05 23:03:56.000000000 -0600
+@@ -145,4 +145,5 @@
+ }
+ #endif /* __cplusplus */
+ 
+-#endif /* PSYCH_H */
+\ No newline at end of file
++#endif /* PSYCH_H */
++