summaryrefslogtreecommitdiff
path: root/cad/freehdl
diff options
context:
space:
mode:
authorjoerg <joerg>2013-04-30 22:13:57 +0000
committerjoerg <joerg>2013-04-30 22:13:57 +0000
commit2162f2eea64aea4152f98749345b00ce7b3aa281 (patch)
tree7a391d945cd5137aeb691d6a710c8292b273284d /cad/freehdl
parent363c43a20e781a15c8987d421d6591352f51cadb (diff)
downloadpkgsrc-2162f2eea64aea4152f98749345b00ce7b3aa281.tar.gz
Explicitly use the GNU namespace for finding hash, C++11 uses the same
identifier in std. Reference the local to_string as it is now also support by std::string.
Diffstat (limited to 'cad/freehdl')
-rw-r--r--cad/freehdl/distinfo8
-rw-r--r--cad/freehdl/patches/patch-freehdl_kernel-db.hh17
-rw-r--r--cad/freehdl/patches/patch-freehdl_kernel-util.hh17
-rw-r--r--cad/freehdl/patches/patch-v2cc_v2cc-decl.cc23
-rw-r--r--cad/freehdl/patches/patch-v2cc_v2cc-explore.cc13
-rw-r--r--cad/freehdl/patches/patch-v2cc_v2cc-expr.cc13
-rw-r--r--cad/freehdl/patches/patch-v2cc_v2cc-util.cc42
7 files changed, 132 insertions, 1 deletions
diff --git a/cad/freehdl/distinfo b/cad/freehdl/distinfo
index 6801146a9ce..1fff9610c78 100644
--- a/cad/freehdl/distinfo
+++ b/cad/freehdl/distinfo
@@ -1,9 +1,15 @@
-$NetBSD: distinfo,v 1.4 2013/02/26 10:23:50 joerg Exp $
+$NetBSD: distinfo,v 1.5 2013/04/30 22:13:57 joerg Exp $
SHA1 (freehdl-0.0.7.tar.gz) = eca7ad3ac58e56b72842e83a0a702c05b8f86aa4
RMD160 (freehdl-0.0.7.tar.gz) = d00e14d6b1cd97154b221717124c6e20b0d4f776
Size (freehdl-0.0.7.tar.gz) = 1394351 bytes
SHA1 (patch-aa) = 4c7b147c47079931506366ce50fc0eeac187fd65
+SHA1 (patch-freehdl_kernel-db.hh) = a8bcb578151e5a310ada2b909d9ea180cf74445e
SHA1 (patch-freehdl_kernel-sig-info.hh) = 86279768c0501434951e4d9cd6b2870c09278e9b
+SHA1 (patch-freehdl_kernel-util.hh) = 0fcc43c840e49210dc0d8020b21130808b96396c
SHA1 (patch-freehdl_std-vhdl-types.hh) = eb5d237c9df90adf057ab9d5c650e76fe0ae5b28
SHA1 (patch-kernel_driver__info.cc) = 7db334da74f9e5856e1dd8b3c7b627d2f3d27646
+SHA1 (patch-v2cc_v2cc-decl.cc) = 220ef0bea3788004a6546354b6d76664d9f359a8
+SHA1 (patch-v2cc_v2cc-explore.cc) = 5ced1d568f2f441d65dea962a11f19f9a1b04b0c
+SHA1 (patch-v2cc_v2cc-expr.cc) = d8513d1d7e40ba4ef684c8078c0b12b9185b6eae
+SHA1 (patch-v2cc_v2cc-util.cc) = aeab1d9a5a6a191ca591211acd0863a8a6cdbe00
diff --git a/cad/freehdl/patches/patch-freehdl_kernel-db.hh b/cad/freehdl/patches/patch-freehdl_kernel-db.hh
new file mode 100644
index 00000000000..537e03c5c16
--- /dev/null
+++ b/cad/freehdl/patches/patch-freehdl_kernel-db.hh
@@ -0,0 +1,17 @@
+$NetBSD: patch-freehdl_kernel-db.hh,v 1.1 2013/04/30 22:13:57 joerg Exp $
+
+--- freehdl/kernel-db.hh.orig 2013-04-30 20:25:10.000000000 +0000
++++ freehdl/kernel-db.hh
+@@ -254,10 +254,10 @@ public:
+
+ // A hash function template used tp generate a hash number from
+ // d
+-class db_basic_key_hash : public hash<unsigned long> {
++class db_basic_key_hash : public __gnu_cxx::hash<unsigned long> {
+ public:
+ size_t operator()(const db_basic_key& x) const {
+- return (*(hash<unsigned long> *)this)(((unsigned long)x.value)>>2);
++ return (*(__gnu_cxx::hash<unsigned long> *)this)(((unsigned long)x.value)>>2);
+ }
+ };
+
diff --git a/cad/freehdl/patches/patch-freehdl_kernel-util.hh b/cad/freehdl/patches/patch-freehdl_kernel-util.hh
new file mode 100644
index 00000000000..2625855de8c
--- /dev/null
+++ b/cad/freehdl/patches/patch-freehdl_kernel-util.hh
@@ -0,0 +1,17 @@
+$NetBSD: patch-freehdl_kernel-util.hh,v 1.1 2013/04/30 22:13:57 joerg Exp $
+
+--- freehdl/kernel-util.hh.orig 2013-04-30 20:24:07.000000000 +0000
++++ freehdl/kernel-util.hh
+@@ -24,10 +24,10 @@ using namespace __gnu_cxx;
+ // A hash function template used tp generate a hash number from
+ // pointer values.
+ template<class T>
+-class pointer_hash : public hash<unsigned long> {
++class pointer_hash : public __gnu_cxx::hash<unsigned long> {
+ public:
+ size_t operator()(const T& x) const {
+- return (*(hash<unsigned long> *)this)(((unsigned long)x)>>2);
++ return (*(__gnu_cxx::hash<unsigned long> *)this)(((unsigned long)x)>>2);
+ }
+ };
+
diff --git a/cad/freehdl/patches/patch-v2cc_v2cc-decl.cc b/cad/freehdl/patches/patch-v2cc_v2cc-decl.cc
new file mode 100644
index 00000000000..fa18731be0a
--- /dev/null
+++ b/cad/freehdl/patches/patch-v2cc_v2cc-decl.cc
@@ -0,0 +1,23 @@
+$NetBSD: patch-v2cc_v2cc-decl.cc,v 1.1 2013/04/30 22:13:57 joerg Exp $
+
+--- v2cc/v2cc-decl.cc.orig 2013-04-30 20:28:00.000000000 +0000
++++ v2cc/v2cc-decl.cc
+@@ -1900,12 +1900,12 @@ m_emit_hdr (pIIR_ScalarSubtype sst, stri
+ str += "class " + qid(decl, rstack, INFO) + ":public float_info_base{\n" +
+ "public:\n" +
+ " " + qid(decl, rstack, INFO) + "():float_info_base(" +
+- to_string(range.left) + ","+ to_string(range.right) + "," +
+- to_string(min(range.left,range.right)) + "," + to_string(max(range.left, range.right)) + ") {};\n" +
+- " static floatingpoint low() { return " + to_string(min(range.left, range.right)) + "; }\n" +
+- " static floatingpoint high() { return " + to_string(max(range.left, range.right)) + "; }\n" +
+- " static floatingpoint left() { return " + to_string(range.left) + "; }\n" +
+- " static floatingpoint right() { return " + to_string(range.right) + "; }\n" +
++ ::to_string(range.left) + ","+ ::to_string(range.right) + "," +
++ ::to_string(min(range.left,range.right)) + "," + ::to_string(max(range.left, range.right)) + ") {};\n" +
++ " static floatingpoint low() { return " + ::to_string(min(range.left, range.right)) + "; }\n" +
++ " static floatingpoint high() { return " + ::to_string(max(range.left, range.right)) + "; }\n" +
++ " static floatingpoint left() { return " + ::to_string(range.left) + "; }\n" +
++ " static floatingpoint right() { return " + ::to_string(range.right) + "; }\n" +
+ "};\n";
+ } else {
+ // Integer info class definition with non static bounds (i.e.,
diff --git a/cad/freehdl/patches/patch-v2cc_v2cc-explore.cc b/cad/freehdl/patches/patch-v2cc_v2cc-explore.cc
new file mode 100644
index 00000000000..230f4c634de
--- /dev/null
+++ b/cad/freehdl/patches/patch-v2cc_v2cc-explore.cc
@@ -0,0 +1,13 @@
+$NetBSD: patch-v2cc_v2cc-explore.cc,v 1.1 2013/04/30 22:13:57 joerg Exp $
+
+--- v2cc/v2cc-explore.cc.orig 2013-04-30 20:29:08.000000000 +0000
++++ v2cc/v2cc-explore.cc
+@@ -2799,7 +2799,7 @@ check_association(pIIR_AssociationList a
+ // Add entries
+ association_map [key].push_back (range_vector [j]);
+ // XXX - why is the cast needed?
+- association_type_map [key] = (vector<vector<pair<pIIR_Type, pIIR_Type > > >::iterator) &association_type_vectors [i];
++ association_type_map [key] = association_type_vectors.begin()+i;
+ // Generate a new key
+ key.push_back (range_vector [j]);
+ }
diff --git a/cad/freehdl/patches/patch-v2cc_v2cc-expr.cc b/cad/freehdl/patches/patch-v2cc_v2cc-expr.cc
new file mode 100644
index 00000000000..0d49d342363
--- /dev/null
+++ b/cad/freehdl/patches/patch-v2cc_v2cc-expr.cc
@@ -0,0 +1,13 @@
+$NetBSD: patch-v2cc_v2cc-expr.cc,v 1.1 2013/04/30 22:13:57 joerg Exp $
+
+--- v2cc/v2cc-expr.cc.orig 2013-04-30 20:28:47.000000000 +0000
++++ v2cc/v2cc-expr.cc
+@@ -602,7 +602,7 @@ m_emit_expr (pIIR_AbstractLiteralExpress
+ else if (ale->value->is(IR_FLOATING_POINT_LITERAL))
+ str += (folded_value(ale).original_string () != "") ?
+ folded_value(ale).original_string () :
+- to_string (folded_value(ale).double_value ());
++ ::to_string (folded_value(ale).double_value ());
+ else
+ abort ();
+ } else
diff --git a/cad/freehdl/patches/patch-v2cc_v2cc-util.cc b/cad/freehdl/patches/patch-v2cc_v2cc-util.cc
new file mode 100644
index 00000000000..1d6f0c02056
--- /dev/null
+++ b/cad/freehdl/patches/patch-v2cc_v2cc-util.cc
@@ -0,0 +1,42 @@
+$NetBSD: patch-v2cc_v2cc-util.cc,v 1.1 2013/04/30 22:13:57 joerg Exp $
+
+--- v2cc/v2cc-util.cc.orig 2013-04-30 20:26:59.000000000 +0000
++++ v2cc/v2cc-util.cc
+@@ -137,7 +137,7 @@ to_string(pIIR_ScalarType type, const St
+ }
+ else if (base_type->is (IR_FLOATING_TYPE))
+ {
+- str = to_string (v.double_value ());
++ str = ::to_string (v.double_value ());
+ }
+
+ return str;
+@@ -536,7 +536,7 @@ emit_folded_value(StaticDataType &data,
+ if (base_type->is(IR_ENUMERATION_TYPE))
+ str += "enumeration(" + to_string(data.long_value()) + ")";
+ else if (base_type->is(IR_FLOATING_TYPE))
+- str += to_string(data.double_value());
++ str += ::to_string(data.double_value());
+ else if (base_type->is(IR_PHYSICAL_TYPE))
+ str += to_string(data.long_value()) + "LL";
+ else if (base_type->is(IR_ARRAY_TYPE))
+@@ -568,7 +568,7 @@ cdfg_emit_folded_value(StaticDataType &d
+ else if (base_type->is(IR_FLOATING_TYPE)) {
+ // Replace 'e' ein the floating point number by 'l' in order to
+ // match the definition of doubles in lisp.
+- string result = to_string(data.double_value());
++ string result = ::to_string(data.double_value());
+ for (unsigned int i = 0; i < result.length(); i++)
+ if (result[i] == 'e' ||
+ result[i] == 'E')
+@@ -1772,8 +1772,8 @@ check_scalar_against_bounds(pIIR_Root n,
+ StaticRangeDescriptor<double, IR_Direction> range =
+ range_des_vec[0].rangedes_to_double(rstack);
+
+- string left_str = to_string(range.left);
+- string right_str = to_string(range.right);
++ string left_str = ::to_string(range.left);
++ string right_str = ::to_string(range.right);
+ if (!range.valid[1]) {
+ // If the range is not static then do not perform any furhter
+ // checks. All checks will be done at runtime.