summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Schlemmer <azarah@gentoo.org>2002-05-05 10:56:36 +0000
committerMartin Schlemmer <azarah@gentoo.org>2002-05-05 10:56:36 +0000
commit2f15eeee36aa046746843db80d1673adedbbfb87 (patch)
tree001c0274bc149ef404b75dbd932ebb18d3fc5179 /media-libs/id3lib
parentfinal touches (diff)
downloadgentoo-2-2f15eeee36aa046746843db80d1673adedbbfb87.tar.gz
gentoo-2-2f15eeee36aa046746843db80d1673adedbbfb87.tar.bz2
gentoo-2-2f15eeee36aa046746843db80d1673adedbbfb87.zip
bugfixes
Diffstat (limited to 'media-libs/id3lib')
-rw-r--r--media-libs/id3lib/ChangeLog8
-rw-r--r--media-libs/id3lib/files/digest-id3lib-3.8.0_pre2-r11
-rw-r--r--media-libs/id3lib/files/id3lib-3.8.0_pre2-gcc3.patch137
-rw-r--r--media-libs/id3lib/id3lib-3.8.0_pre2-r1.ebuild45
4 files changed, 190 insertions, 1 deletions
diff --git a/media-libs/id3lib/ChangeLog b/media-libs/id3lib/ChangeLog
index b6820a16d132..c7c168b15460 100644
--- a/media-libs/id3lib/ChangeLog
+++ b/media-libs/id3lib/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for media-libs/id3lib
# Copyright 2002 Gentoo Technologies, Inc.; Distributed under the GPL
-# $Header: /var/cvsroot/gentoo-x86/media-libs/id3lib/ChangeLog,v 1.1 2002/02/01 21:53:30 gbevin Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/id3lib/ChangeLog,v 1.2 2002/05/05 10:56:36 azarah Exp $
+
+*id3lib-3.8.0_pre2-r1 (5 May 2002)
+
+ 5 May 2002; Martin Schlemmer <azarah@gentoo.org> id3lib-3.8.0_pre2-r1.ebuild :
+
+ Resolve bug #2128 (do not compile with gcc3).
*id3lib-3.8.0_pre2 (1 Feb 2002)
diff --git a/media-libs/id3lib/files/digest-id3lib-3.8.0_pre2-r1 b/media-libs/id3lib/files/digest-id3lib-3.8.0_pre2-r1
new file mode 100644
index 000000000000..72c7aeafef6d
--- /dev/null
+++ b/media-libs/id3lib/files/digest-id3lib-3.8.0_pre2-r1
@@ -0,0 +1 @@
+MD5 48444a1eb634c034c05388e8e2bb5024 id3lib-3.8.0pre2.tar.gz 680219
diff --git a/media-libs/id3lib/files/id3lib-3.8.0_pre2-gcc3.patch b/media-libs/id3lib/files/id3lib-3.8.0_pre2-gcc3.patch
new file mode 100644
index 000000000000..08b4968f503d
--- /dev/null
+++ b/media-libs/id3lib/files/id3lib-3.8.0_pre2-gcc3.patch
@@ -0,0 +1,137 @@
+diff -w -b -B -u -U 5 -r -P -x *~ -x *.[oa] id3lib-3.8.0pre2/src/tag_file.cpp id3lib-3.8.0pre2.doj/src/tag_file.cpp
+--- id3lib-3.8.0pre2/src/tag_file.cpp Sat Sep 8 04:30:18 2001
++++ id3lib-3.8.0pre2.doj/src/tag_file.cpp Thu Oct 4 23:22:40 2001
+@@ -268,18 +268,11 @@
+ }
+ char sTempFile[ID3_PATH_LENGTH];
+ strcpy(sTempFile, filename.c_str());
+ strcat(sTempFile, sTmpSuffix.c_str());
+
+- int fd = mkstemp(sTempFile);
+- if (fd < 0)
+- {
+- remove(sTempFile);
+- //ID3_THROW_DESC(ID3E_NoFile, "couldn't open temp file");
+- }
+-
+- ofstream tmpOut(fd);
++ ofstream tmpOut(sTempFile);
+ if (!tmpOut)
+ {
+ tmpOut.close();
+ remove(sTempFile);
+ return 0;
+@@ -290,13 +283,13 @@
+ tmpOut.write(tagData, tagSize);
+ file.seekg(tag.GetPrependedBytes(), ios::beg);
+ uchar tmpBuffer[BUFSIZ];
+ while (file)
+ {
+- file.read(tmpBuffer, BUFSIZ);
++ file.read((char *)tmpBuffer, BUFSIZ);
+ size_t nBytes = file.gcount();
+- tmpOut.write(tmpBuffer, nBytes);
++ tmpOut.write((char *)tmpBuffer, nBytes);
+ }
+
+ tmpOut.close();
+
+ file.close();
+diff -w -b -B -u -U 5 -r -P -x *~ -x *.[oa] id3lib-3.8.0pre2/src/utils.cpp id3lib-3.8.0pre2.doj/src/utils.cpp
+--- id3lib-3.8.0pre2/src/utils.cpp Sat Sep 8 04:30:18 2001
++++ id3lib-3.8.0pre2.doj/src/utils.cpp Thu Oct 4 23:31:17 2001
+@@ -31,12 +31,14 @@
+ #if defined HAVE_ICONV_H
+ # include <iconv.h>
+ # include <errno.h>
+ #endif
+
+-#include <ctype.h>
+-#include <iostream.h>
++#include <cctype>
++#include <iostream>
++#include <string>
++using namespace std;
+
+ #ifdef macintosh
+ #define NOCREATE ((std::ios_base::openmode)0)
+ #define toascii(X) (X)
+ #else
+@@ -115,11 +117,11 @@
+ size_t target_size = BUFSIZ;
+
+ do
+ {
+ size_t nconv = iconv(cd,
+- &source_str, &source_size,
++ (char **)&source_str, &source_size,
+ &target_str, &target_size);
+ if (nconv == (size_t) -1 && errno != EINVAL && errno != E2BIG)
+ {
+ return target;
+ }
+@@ -214,11 +216,11 @@
+
+ namespace
+ {
+ bool exists(String name)
+ {
+- ifstream file(name.c_str(), NOCREATE);
++ ifstream file(name.c_str()/*, NOCREATE*/);
+ return file.is_open() != 0;
+ }
+ };
+
+ ID3_Err dami::createFile(String name, fstream& file)
+@@ -285,11 +287,11 @@
+
+ if (file.is_open())
+ {
+ file.close();
+ }
+- file.open(name.c_str(), ios::in | ios::out | ios::binary | NOCREATE);
++ file.open(name.c_str(), ios::in | ios::out | ios::binary /*| NOCREATE*/);
+ if (!file)
+ {
+ return ID3E_ReadOnly;
+ }
+
+@@ -305,11 +307,11 @@
+
+ if (file.is_open())
+ {
+ file.close();
+ }
+- file.open(name.c_str(), ios::in | ios::out | ios::binary | NOCREATE);
++ file.open(name.c_str(), ios::in | ios::out | ios::binary /*| NOCREATE*/);
+ if (!file)
+ {
+ return ID3E_ReadOnly;
+ }
+
+@@ -320,11 +322,11 @@
+ {
+ if (file.is_open())
+ {
+ file.close();
+ }
+- file.open(name.c_str(), ios::in | ios::binary | NOCREATE);
++ file.open(name.c_str(), ios::in | ios::binary /*| NOCREATE*/);
+ if (!file)
+ {
+ return ID3E_NoFile;
+ }
+
+@@ -335,11 +337,11 @@
+ {
+ if (file.is_open())
+ {
+ file.close();
+ }
+- file.open(name.c_str(), ios::in | ios::binary | NOCREATE);
++ file.open(name.c_str(), ios::in | ios::binary /*| NOCREATE*/);
+ if (!file)
+ {
+ return ID3E_NoFile;
+ }
+
diff --git a/media-libs/id3lib/id3lib-3.8.0_pre2-r1.ebuild b/media-libs/id3lib/id3lib-3.8.0_pre2-r1.ebuild
new file mode 100644
index 000000000000..cfea6c3da78a
--- /dev/null
+++ b/media-libs/id3lib/id3lib-3.8.0_pre2-r1.ebuild
@@ -0,0 +1,45 @@
+# Copyright 1999-2000 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License, v2 or later
+# Author Tom von Schwerdtner <tvon@etria.org>
+# $Header: /var/cvsroot/gentoo-x86/media-libs/id3lib/id3lib-3.8.0_pre2-r1.ebuild,v 1.1 2002/05/05 10:56:36 azarah Exp $
+
+A=${PN}-3.8.0pre2.tar.gz
+S=${WORKDIR}/${PN}-3.8.0pre2
+DESCRIPTION="Id3 library for C/C++"
+SRC_URI="http://prdownloads.sourceforge.net/id3lib/${A}"
+HOMEPAGE="http://id3lib.sourceforge.net/"
+
+DEPEND="virtual/glibc"
+
+src_unpack() {
+
+ unpack ${A}
+
+ if [ "`gcc --version | cut -f1 -d.`" -eq 3 ] ||
+ ([ -n "${CXX}" ] && [ "`${CXX} --version | cut -f1 -d.`" -eq 3 ])
+ then
+ cd ${S}
+ # Patch for compilation with gcc-3.0.x thanks to Dirk Jagdmann (doj),
+ # and me (fixed the const char** in utils.cpp)
+ #
+ # Azarah - 5 May 2002
+ patch -p1 <${FILESDIR}/${P}-gcc3.patch || die
+ fi
+}
+
+src_compile() {
+
+ ./configure --host=${CHOST} --prefix=/usr || die
+ emake || die
+}
+
+src_install() {
+
+ make DESTDIR=${D} install || die
+
+ dodoc AUTHORS COPYING ChangeLog HISTORY INSTALL README THANKS TODO
+# some example programs to be placed in docs dir.
+ make clean
+ cp -a examples ${D}/usr/share/doc/${PF}/examples
+}
+