[arch-commits] Commit in freehdl/repos (3 files)

Felix Yan felixonmars at archlinux.org
Tue Jul 7 17:05:02 UTC 2020


    Date: Tuesday, July 7, 2020 @ 17:05:02
  Author: felixonmars
Revision: 659538

archrelease: copy trunk to community-staging-x86_64

Added:
  freehdl/repos/community-staging-x86_64/
  freehdl/repos/community-staging-x86_64/PKGBUILD
    (from rev 659536, freehdl/trunk/PKGBUILD)
  freehdl/repos/community-staging-x86_64/build-fix.patch
    (from rev 659536, freehdl/trunk/build-fix.patch)

-----------------+
 PKGBUILD        |   34 ++++++++++++++
 build-fix.patch |  131 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 165 insertions(+)

Copied: freehdl/repos/community-staging-x86_64/PKGBUILD (from rev 659536, freehdl/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2020-07-07 17:05:02 UTC (rev 659538)
@@ -0,0 +1,34 @@
+# Maintainer: Sergej Pupykin <pupykin.s+arch at gmail.com>
+# Contributor: Neil Darlow <neil at darlow.co.uk>
+# Contributor: Jens Maucher <defcon at archlinux.us>
+
+pkgname=freehdl
+pkgver=0.0.8
+pkgrel=10
+pkgdesc='An open-source (C++ generating) VHDL simulator'
+arch=('x86_64')
+url='http://freehdl.seul.org'
+license=('GPL')
+depends=('perl')
+optdepends=('gtkwave: to view output when run standalone')
+options=('libtool')
+source=("https://downloads.sourceforge.net/qucs/$pkgname-$pkgver.tar.gz"
+	"build-fix.patch")
+sha256sums=('7f0978f8252329450de43e98c04c15fdd8a3f2bdc5ca91f75f8f5dd280c6ed84'
+            '08d49fc621d48099afcbe42c99ba25474409dbe5c16748a1cd01f50c0e1bae25')
+
+prepare() {
+  cd "${srcdir}"/$pkgname-$pkgver
+  patch -p1 -i "$srcdir"/build-fix.patch
+}
+
+build() {
+  cd "${srcdir}"/$pkgname-$pkgver
+  ./configure --prefix=/usr
+  make
+}
+
+package() {
+  cd "${srcdir}"/$pkgname-$pkgver
+  make DESTDIR="${pkgdir}" install
+}

Copied: freehdl/repos/community-staging-x86_64/build-fix.patch (from rev 659536, freehdl/trunk/build-fix.patch)
===================================================================
--- community-staging-x86_64/build-fix.patch	                        (rev 0)
+++ community-staging-x86_64/build-fix.patch	2020-07-07 17:05:02 UTC (rev 659538)
@@ -0,0 +1,131 @@
+diff -wbBur freehdl-0.0.8/freehdl/kernel-db.hh freehdl-0.0.8.my/freehdl/kernel-db.hh
+--- freehdl-0.0.8/freehdl/kernel-db.hh	2009-03-15 20:51:51.000000000 +0300
++++ freehdl-0.0.8.my/freehdl/kernel-db.hh	2018-11-16 13:52:59.586301664 +0300
+@@ -254,10 +254,10 @@
+ 
+ // 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 std::hash<unsigned long> {
+ public:
+   size_t operator()(const db_basic_key& x) const {
+-    return (*(hash<unsigned long> *)this)(((unsigned long)x.value)>>2);
++    return (*(std::hash<unsigned long> *)this)(((unsigned long)x.value)>>2);
+   }
+ };
+ 
+diff -wbBur freehdl-0.0.8/freehdl/kernel-util.hh freehdl-0.0.8.my/freehdl/kernel-util.hh
+--- freehdl-0.0.8/freehdl/kernel-util.hh	2008-02-15 21:30:07.000000000 +0300
++++ freehdl-0.0.8.my/freehdl/kernel-util.hh	2018-11-16 13:52:26.466302045 +0300
+@@ -24,10 +24,10 @@
+ // 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 std::hash<unsigned long> {
+ public:
+   size_t operator()(const T& x) const {
+-    return (*(hash<unsigned long> *)this)(((unsigned long)x)>>2);
++    return (*(std::hash<unsigned long> *)this)(((unsigned long)x)>>2);
+   }
+ };
+ 
+diff -wbBur freehdl-0.0.8/v2cc/gvhdl.in freehdl-0.0.8.my/v2cc/gvhdl.in
+--- freehdl-0.0.8/v2cc/gvhdl.in	2011-03-12 16:16:47.000000000 +0300
++++ freehdl-0.0.8.my/v2cc/gvhdl.in	2018-11-16 13:48:18.562971561 +0300
+@@ -9,7 +9,7 @@
+ my $vhdl_source_name = "";
+ my $source = "";
+ my $includes = "";
+-my $cpplibs = "-lm FREEHDL/lib/libfreehdl-kernel.la FREEHDL/lib/libfreehdl-std.la";
++my $cpplibs = "-lm -lfreehdl-kernel -lfreehdl-std";
+ my $vhdl_library = ""; # Library the design entity is compiled into
+ my $cpp_options = "";
+ my $vhdl_options = "";
+diff -wbBur freehdl-0.0.8/v2cc/gvhdl-local freehdl-0.0.8.my/v2cc/gvhdl-local
+--- freehdl-0.0.8/v2cc/gvhdl-local	2005-12-02 01:16:20.000000000 +0300
++++ freehdl-0.0.8.my/v2cc/gvhdl-local	2018-11-16 13:48:18.562971561 +0300
+@@ -8,7 +8,7 @@
+ my $vhdl_source_name = "";
+ my $source = "";
+ my $includes = "";
+-my $cpplibs = "-lm FREEHDL/kernel/libfreehdl-kernel.la FREEHDL/std/libfreehdl-std.la";
++my $cpplibs = "-lm -lfreehdl-kernel -lfreehdl-std";
+ my $vhdl_library = ""; # Library the design entity is compiled into
+ my $cpp_options = "-static ";
+ my $vhdl_options = "";
+diff -wbBur freehdl-0.0.8/v2cc/v2cc-decl.cc freehdl-0.0.8.my/v2cc/v2cc-decl.cc
+--- freehdl-0.0.8/v2cc/v2cc-decl.cc	2010-05-08 16:15:38.000000000 +0400
++++ freehdl-0.0.8.my/v2cc/v2cc-decl.cc	2018-11-16 13:57:39.026298452 +0300
+@@ -1901,12 +1901,12 @@
+       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" + 
++	std::to_string(range.left) + ","+ std::to_string(range.right) + "," + 
++	std::to_string(min(range.left,range.right)) + "," + std::to_string(max(range.left, range.right)) + ") {};\n" + 
++	"   static floatingpoint low() { return " + std::to_string(min(range.left, range.right)) + "; }\n" +
++	"   static floatingpoint high() { return " + std::to_string(max(range.left, range.right)) + "; }\n" +
++	"   static floatingpoint left() { return " + std::to_string(range.left) + "; }\n" +
++	"   static floatingpoint right() { return " + std::to_string(range.right) + "; }\n" + 
+ 	"};\n";
+     } else {
+       // Integer info class definition with non static bounds (i.e.,
+diff -wbBur freehdl-0.0.8/v2cc/v2cc-expr.cc freehdl-0.0.8.my/v2cc/v2cc-expr.cc
+--- freehdl-0.0.8/v2cc/v2cc-expr.cc	2008-02-15 21:13:46.000000000 +0300
++++ freehdl-0.0.8.my/v2cc/v2cc-expr.cc	2018-11-16 13:57:59.986298211 +0300
+@@ -602,7 +602,7 @@
+     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 ());
++	std::to_string (folded_value(ale).double_value ());
+     else
+       abort ();
+   } else
+diff -wbBur freehdl-0.0.8/v2cc/v2cc-util.cc freehdl-0.0.8.my/v2cc/v2cc-util.cc
+--- freehdl-0.0.8/v2cc/v2cc-util.cc	2009-04-19 02:51:38.000000000 +0400
++++ freehdl-0.0.8.my/v2cc/v2cc-util.cc	2018-11-16 13:56:43.602965757 +0300
+@@ -137,7 +137,7 @@
+     }
+   else if (base_type->is (IR_FLOATING_TYPE))
+     {
+-      str = to_string (v.double_value ());
++      str = std::to_string (v.double_value ());
+     }
+ 
+   return str;
+@@ -536,7 +536,7 @@
+   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 += std::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 @@
+   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 = std::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 @@
+   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 = std::to_string(range.left);
++  string right_str = std::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.



More information about the arch-commits mailing list