[mathicgb] 190/393: Fixes to make MathicGB compile on GCC 4.5.3 on Cygwin.

Doug Torrance dtorrance-guest at moszumanska.debian.org
Fri Apr 3 15:58:58 UTC 2015


This is an automated email from the git hooks/post-receive script.

dtorrance-guest pushed a commit to branch upstream
in repository mathicgb.

commit 78e37fbc3694fb43ccdba22409d9656af84842bc
Author: Bjarke Hammersholt Roune <bjarkehr.code at gmail.com>
Date:   Mon Mar 18 17:17:36 2013 +0100

    Fixes to make MathicGB compile on GCC 4.5.3 on Cygwin.
---
 src/mathicgb/mtbb.hpp | 7 ++++---
 src/mathicgb/stdinc.h | 4 ++++
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/src/mathicgb/mtbb.hpp b/src/mathicgb/mtbb.hpp
index 5cacdd1..557c453 100644
--- a/src/mathicgb/mtbb.hpp
+++ b/src/mathicgb/mtbb.hpp
@@ -1,7 +1,7 @@
 #ifndef MATHICGB_TBB_GUARD
 #define MATHICGB_TBB_GUARD
 
-//#define MATHICGB_NO_TBB
+#define MATHICGB_NO_TBB
 
 #ifndef MATHICGB_NO_TBB
 #include <tbb/tbb.h>
@@ -24,6 +24,7 @@ namespace mgb {
 #include <functional>
 #include <vector>
 #include <ctime>
+#include <algorithm>
 
 namespace mgb {
   namespace tbb {
@@ -139,7 +140,7 @@ namespace mgb {
 
       size_type size() const {return end() - begin();}
       bool empty() const {return mBegin == mEnd;}
-      size_type grainsize() const {return grainSize;}
+      size_type grainsize() const {return mGrainSize;}
       bool is_divisible() const {return false;}
 
       const_iterator begin() const {return mBegin;}
@@ -176,7 +177,7 @@ namespace mgb {
 
     template<class InputIterator, class Body>
     void parallel_do(InputIterator begin, InputIterator end, Body body) {
-      typedef std::remove_reference<decltype(*begin)>::type Task;
+      typedef typename std::remove_reference<decltype(*begin)>::type Task;
       std::vector<Task> tasks;
       parallel_do_feeder<Task> feeder(tasks);
       for (; begin != end; ++begin) {
diff --git a/src/mathicgb/stdinc.h b/src/mathicgb/stdinc.h
index 73a5dbd..9258f96 100755
--- a/src/mathicgb/stdinc.h
+++ b/src/mathicgb/stdinc.h
@@ -114,6 +114,10 @@
 
 #endif
 
+#if defined(__CYGWIN__) && !defined(MATHICGB_NO_TBB)
+#define MATHICGB_NO_TBB
+#endif
+
 #include <cstddef>
 #include <memory>
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/mathicgb.git



More information about the debian-science-commits mailing list