Subject: Re: pkgsrc IRIX64 6.5/mipseb bulk build results 2005-07-10
To: None <pkgsrc-bulk@netbsd.org>
From: Roland Illig <rillig@NetBSD.org>
List: pkgsrc-bulk
Date: 07/18/2005 14:37:05
This is a multi-part message in MIME format.
--------------070503040800080109080702
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit

Jan Schaumann wrote:
> Roland Illig <rillig@NetBSD.org> wrote:
> 
>>Jan Schaumann wrote:
>>
>>>audio/id3lib                       10      tech-pkg@NetBSD.org
> 
>  
> 
>>What about this patch?
> 
> 
> No luck, it seems:

Next try.

Roland

--------------070503040800080109080702
Content-Type: text/plain;
 name="id3lib.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="id3lib.patch"

Index: Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/audio/id3lib/Makefile,v
retrieving revision 1.23
diff -u -p -r1.23 Makefile
--- Makefile	31 May 2005 21:56:37 -0000	1.23
+++ Makefile	18 Jul 2005 12:35:23 -0000
@@ -16,7 +16,15 @@ USE_LANGUAGES=		c c++
 GNU_CONFIGURE=		yes
 USE_LIBTOOL=		yes
 
-CPPFLAGS+=-DID3_NEED_WCHAR_TEMPLATE
+CPPFLAGS+=		-DID3_NEED_WCHAR_TEMPLATE
+CPPFLAGS+=		-DDAMI_USE_STD_MIN_MAX
+
+SUBST_CLASSES+=		std_min
+SUBST_MESSAGE.std_min=	"Replacing dami::min with std::min"
+SUBST_STAGE.std_min=	pre-configure
+SUBST_FILES.std_min=	src/*.cpp
+SUBST_SED.std_min=	-e 's,dami::min(,std::min(,g'
+SUBST_SED.std_min+=	-e 's,dami::min<,std::min<,g'
 
 .include "../../devel/zlib/buildlink3.mk"
 .include "../../mk/bsd.pkg.mk"
Index: distinfo
===================================================================
RCS file: /cvsroot/pkgsrc/audio/id3lib/distinfo,v
retrieving revision 1.11
diff -u -p -r1.11 distinfo
--- distinfo	23 Feb 2005 20:39:47 -0000	1.11
+++ distinfo	18 Jul 2005 12:35:23 -0000
@@ -6,3 +6,4 @@ Size (id3lib-3.8.3.tar.gz) = 950726 byte
 SHA1 (patch-aa) = 75b19258eeaeb65aa2fa43cd44769aa1d6e575c3
 SHA1 (patch-af) = 0266e9220791b7b14a35dc9b7564ab75cbc6562b
 SHA1 (patch-ag) = a047fe90d83c88e0f6d0a6a0595a440ef49276e3
+SHA1 (patch-ah) = a029662e824c5c8eb4af7df7d1d8239a7acec25b

--------------070503040800080109080702
Content-Type: text/plain;
 name="patch-ah"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="patch-ah"

$NetBSD$

--- include/id3/utils.h.orig	Sun Mar  2 01:23:00 2003
+++ include/id3/utils.h	Mon Jul 18 14:18:11 2005
@@ -36,6 +36,12 @@
 #include "id3/globals.h" //has <stdlib.h> "id3/sized_types.h"
 #include "id3/id3lib_strings.h"
 
+#ifdef DAMI_USE_STD_MIN_MAX
+#  include <algorithm>
+using std::min;
+using std::max;
+#endif
+
 namespace dami
 {
 #ifdef  MAXPATHLEN
@@ -46,6 +52,7 @@ namespace dami
 #  define ID3_PATH_LENGTH   (2048 + 1)
 #endif  /* !MAXPATHLEN && !PATH_MAX */
 
+#ifndef DAMI_USE_STD_MIN_MAX
 #ifndef min
   template<typename T>
   const T& min(const T& a, const T& b)
@@ -60,6 +67,7 @@ namespace dami
   {
     return (b < a) ? a : b;
   }
+#endif
 #endif
 
 #ifndef mid

--------------070503040800080109080702--