diff options
author | wiz <wiz@pkgsrc.org> | 2012-03-28 20:40:38 +0000 |
---|---|---|
committer | wiz <wiz@pkgsrc.org> | 2012-03-28 20:40:38 +0000 |
commit | b5269dd1e512e1371deece3073683583c51ff648 (patch) | |
tree | fa4640b553098e92786d3899b801fe0783b5ef75 /net/mldonkey/patches | |
parent | 9b51510d9a999c772629f0a0f248000ff70208f9 (diff) | |
download | pkgsrc-b5269dd1e512e1371deece3073683583c51ff648.tar.gz |
Fix build with clang.
Diffstat (limited to 'net/mldonkey/patches')
-rw-r--r-- | net/mldonkey/patches/patch-Makefile | 15 | ||||
-rw-r--r-- | net/mldonkey/patches/patch-src_utils_lib_CryptoPP.cc | 15 | ||||
-rw-r--r-- | net/mldonkey/patches/patch-src_utils_lib_CryptoPP.h | 24 |
3 files changed, 54 insertions, 0 deletions
diff --git a/net/mldonkey/patches/patch-Makefile b/net/mldonkey/patches/patch-Makefile new file mode 100644 index 00000000000..5e080bbea4c --- /dev/null +++ b/net/mldonkey/patches/patch-Makefile @@ -0,0 +1,15 @@ +$NetBSD: patch-Makefile,v 1.1 2012/03/28 20:40:38 wiz Exp $ + +clang does not know -O6. + +--- Makefile.orig 2011-08-08 05:11:57.000000000 +0000 ++++ Makefile +@@ -5033,7 +5033,7 @@ ocamldoc_html: $(CORE_DOC) $(libclient_D + $(OCAMLDOC) -sort -dump ocamldoc/ocamldocdump -html -d ocamldoc $(INCLUDES) $(libclient_DOC) $(CORE_DOC) + + $(LIB)/md4_cc.o: $(LIB)/md4.c +- $(OCAMLC) -ccopt "$(CFLAGS) -O6 -o $(LIB)/md4_cc.o" -ccopt "" -c $(LIB)/md4.c ++ $(OCAMLC) -ccopt "$(CFLAGS) -o $(LIB)/md4_cc.o" -ccopt "" -c $(LIB)/md4.c + + $(CDK)/heap_c.o: $(CDK)/heap_c.c + $(OCAMLC) -ccopt "$(CFLAGS) $(MORECFLAGS) -o $(CDK)/heap_c.o" -ccopt "" -c $(CDK)/heap_c.c diff --git a/net/mldonkey/patches/patch-src_utils_lib_CryptoPP.cc b/net/mldonkey/patches/patch-src_utils_lib_CryptoPP.cc new file mode 100644 index 00000000000..2897ea74c27 --- /dev/null +++ b/net/mldonkey/patches/patch-src_utils_lib_CryptoPP.cc @@ -0,0 +1,15 @@ +$NetBSD: patch-src_utils_lib_CryptoPP.cc,v 1.1 2012/03/28 20:40:38 wiz Exp $ + +Fix build with clang-3.1. + +--- src/utils/lib/CryptoPP.cc.orig 2010-10-23 18:23:38.000000000 +0000 ++++ src/utils/lib/CryptoPP.cc +@@ -5413,7 +5413,7 @@ template <class T> const T& AbstractEucl + Element g[3]={b, a}; + unsigned int i0=0, i1=1, i2=2; + +- while (!Equal(g[i1], this->Identity())) ++ while (!this->Equal(g[i1], this->Identity())) + { + g[i2] = Mod(g[i0], g[i1]); + unsigned int t = i0; i0 = i1; i1 = i2; i2 = t; diff --git a/net/mldonkey/patches/patch-src_utils_lib_CryptoPP.h b/net/mldonkey/patches/patch-src_utils_lib_CryptoPP.h new file mode 100644 index 00000000000..80195c204f6 --- /dev/null +++ b/net/mldonkey/patches/patch-src_utils_lib_CryptoPP.h @@ -0,0 +1,24 @@ +$NetBSD: patch-src_utils_lib_CryptoPP.h,v 1.1 2012/03/28 20:40:38 wiz Exp $ + +Fix build with clang-3.1. + +--- src/utils/lib/CryptoPP.h.orig 2011-05-07 18:40:00.000000000 +0000 ++++ src/utils/lib/CryptoPP.h +@@ -2633,7 +2633,7 @@ public: + + pointer allocate(size_type n, const void * = NULL) + { +- CheckSize(n); ++ this->CheckSize(n); + if (n == 0) + return NULL; + return new T[n]; +@@ -5612,7 +5612,7 @@ template <class T, class B, class BASE> + { + this->ThrowIfInvalidTruncatedSize(size); + +- PadLastBlock(this->BlockSize() - 2*sizeof(HashWordType)); ++ this->PadLastBlock(this->BlockSize() - 2*sizeof(HashWordType)); + CorrectEndianess(this->m_data, this->m_data, this->BlockSize() - 2*sizeof(HashWordType)); + + this->m_data[this->m_data.size()-2] = B::ToEnum() ? this->GetBitCountHi() : this->GetBitCountLo(); |