pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/archivers/advancecomp Fixed the build for sunpro on So...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/d74f1a44fe85
branches:  trunk
changeset: 523891:d74f1a44fe85
user:      rillig <rillig%pkgsrc.org@localhost>
date:      Sun Jan 14 16:28:40 2007 +0000

description:
Fixed the build for sunpro on Solaris 10.

diffstat:

 archivers/advancecomp/Makefile         |   8 +++++++-
 archivers/advancecomp/distinfo         |   5 ++++-
 archivers/advancecomp/patches/patch-aa |  18 ++++++++++++++++++
 archivers/advancecomp/patches/patch-ab |  26 ++++++++++++++++++++++++++
 archivers/advancecomp/patches/patch-ac |  17 +++++++++++++++++
 5 files changed, 72 insertions(+), 2 deletions(-)

diffs (107 lines):

diff -r 9f4124aa8cc4 -r d74f1a44fe85 archivers/advancecomp/Makefile
--- a/archivers/advancecomp/Makefile    Sun Jan 14 16:25:47 2007 +0000
+++ b/archivers/advancecomp/Makefile    Sun Jan 14 16:28:40 2007 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.11 2006/07/22 04:46:13 rillig Exp $
+# $NetBSD: Makefile,v 1.12 2007/01/14 16:28:40 rillig Exp $
 
 DISTNAME=      advancecomp-1.15
 CATEGORIES=    archivers
@@ -13,5 +13,11 @@
 GNU_CONFIGURE=         yes
 USE_LANGUAGES=         c c++
 
+.include "../../mk/compiler.mk"
+
+.if !empty(PKGSRC_COMPILER:Msunpro)
+CFLAGS+=       -features=extensions
+.endif
+
 .include "../../devel/zlib/buildlink3.mk"
 .include "../../mk/bsd.pkg.mk"
diff -r 9f4124aa8cc4 -r d74f1a44fe85 archivers/advancecomp/distinfo
--- a/archivers/advancecomp/distinfo    Sun Jan 14 16:25:47 2007 +0000
+++ b/archivers/advancecomp/distinfo    Sun Jan 14 16:28:40 2007 +0000
@@ -1,5 +1,8 @@
-$NetBSD: distinfo,v 1.4 2006/04/12 20:12:56 rillig Exp $
+$NetBSD: distinfo,v 1.5 2007/01/14 16:28:40 rillig Exp $
 
 SHA1 (advancecomp-1.15.tar.gz) = 74fed754841efadcb8dd156d2c5e095bfaff83e6
 RMD160 (advancecomp-1.15.tar.gz) = 13468f350e15e7f23778d8351819a792fbf07c9a
 Size (advancecomp-1.15.tar.gz) = 259340 bytes
+SHA1 (patch-aa) = bb74883968ec79e3f5f62085668cf3341c46570c
+SHA1 (patch-ab) = 1e6e10943bd2a414d4f704bd94b1de3d1036dd90
+SHA1 (patch-ac) = d08d44224c4351c66c920b26bacc3f749a54d31a
diff -r 9f4124aa8cc4 -r d74f1a44fe85 archivers/advancecomp/patches/patch-aa
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/archivers/advancecomp/patches/patch-aa    Sun Jan 14 16:28:40 2007 +0000
@@ -0,0 +1,18 @@
+$NetBSD: patch-aa,v 1.1 2007/01/14 16:28:40 rillig Exp $
+
+--- portable.h.orig    2004-08-09 15:04:02.000000000 +0200
++++ portable.h 2007-01-14 17:05:21.524063100 +0100
+@@ -148,5 +148,13 @@ int vsnprintf(char *str, size_t count, c
+ }
+ #endif
+ 
++#if !defined(__GNUC__) && !defined(__PRETTY_FUNCTION__)
++#  define __PRETTY_FUNCTION__ __func__
++#endif
++
++#if !defined(__GNUC__) && !defined(__attribute__)
++#  define __attribute__(x) /**/
++#endif
++
+ #endif
+ 
diff -r 9f4124aa8cc4 -r d74f1a44fe85 archivers/advancecomp/patches/patch-ab
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/archivers/advancecomp/patches/patch-ab    Sun Jan 14 16:28:40 2007 +0000
@@ -0,0 +1,26 @@
+$NetBSD: patch-ab,v 1.1 2007/01/14 16:28:40 rillig Exp $
+
+SunPro complains about an overloading abiguity when std::log(2) is
+called. It doesn't know whether to take log(double) or log(long double).
+
+There also seems to be some namespace issues, maybe an #include
+directive for a standard header has been placed into a namespace?
+
+--- 7z/AriBitCoder.cc.orig     2003-02-10 20:25:06.000000000 +0100
++++ 7z/AriBitCoder.cc  2007-01-14 17:00:56.250636464 +0100
+@@ -10,10 +10,12 @@ static const double kDummyMultMid = (1.0
+ 
+ CPriceTables::CPriceTables()
+ {
+-  double aLn2 = log(2);
+-  double aLnAll = log(kBitModelTotal >> kNumMoveReducingBits);
++  using ::std::log;
++  using ::std::fabs;
++  double aLn2 = log(2.0);
++  double aLnAll = log((double)(kBitModelTotal >> kNumMoveReducingBits));
+   for(UINT32 i = 1; i < (kBitModelTotal >> kNumMoveReducingBits) - 1; i++)
+-    m_StatePrices[i] = UINT32((fabs(aLnAll - log(i)) / aLn2 + kDummyMultMid) * kBitPrice);
++    m_StatePrices[i] = UINT32((fabs(aLnAll - log((double)i)) / aLn2 + kDummyMultMid) * kBitPrice);
+ }
+ 
+ CPriceTables g_PriceTables;
diff -r 9f4124aa8cc4 -r d74f1a44fe85 archivers/advancecomp/patches/patch-ac
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/archivers/advancecomp/patches/patch-ac    Sun Jan 14 16:28:40 2007 +0000
@@ -0,0 +1,17 @@
+$NetBSD: patch-ac,v 1.1 2007/01/14 16:28:40 rillig Exp $
+
+- A string<char> cannot be initialized with an unsigned char *.
+- There is no constructor string(const char *, const char *).
+
+--- zip.cc.orig        2004-11-07 21:14:28.000000000 +0100
++++ zip.cc     2007-01-14 17:11:15.104504656 +0100
+@@ -452,7 +452,8 @@ void zip_entry::name_set(const string& A
+ 
+ string zip_entry::name_get() const
+ {
+-      return string(file_name, file_name + info.filename_length);
++      /* file_name is an unsigned char *. */
++      return string(reinterpret_cast<const char *>(file_name), info.filename_length);
+ }
+ 
+ /** Check central directory entry. */



Home | Main Index | Thread Index | Old Index