Re: ITL build on gcc 3.2?

Lie-Quan Lee <[email protected]>
Newsgroups gmane.comp.lib.mtl.devel
Message-ID <[email protected]>
Hi Bastian,

I can use gcc3.2.2 to compile itl-4.0.0-1 with the patch attached. I
will continue to support ITL. Let me know if you still have any problem.
On Thu, 2003-04-03 at 02:00, Bastian Goldluecke wrote:

> ... and so on. My experience with templates is limited, and I'm not be able to 
> fix the errors myself in a reasonable amount of time. Will there be an 
> official fix for the ITL to compile on gcc 3.2 anytime soon, or do I have to 
> look for another library? If in the latter case anybody can suggest a good 
> alternative for solving sparse systems, I would be grateful.
> 
> Thanks,
> Bastian.
> 
> _______________________________________________
> This list is archived at http://www.osl.iu.edu/MailArchives/mtl-devel/
-- 
Lie-Quan Lee                           Tel:   650-926-3533
Advanced Computations Department       Fax:   650-926-4603
Stanford Linear Accelerator Center     Email: [email protected]

_______________________________________________
This list is archived at http://www.osl.iu.edu/MailArchives/mtl-devel/
itl-gcc3.2.2.patch (text/x-patch, 1.4 KB)
diff -Naur itl-4.0.0-1-orig/itl/interface/detail/mtl_amend.h itl-4.0.0-1/itl/interface/detail/mtl_amend.h
--- itl-4.0.0-1-orig/itl/interface/detail/mtl_amend.h	Fri Oct 26 10:45:44 2001
+++ itl-4.0.0-1/itl/interface/detail/mtl_amend.h	Wed Feb 19 10:37:23 2003
@@ -1,3 +1,13 @@
+
+#ifndef ITL_MTL_AMEND_H
+#define ITL_MTL_AMEND_H
+
+#include <vector>
+
+template <class T>
+class pointer_vector;
+
+
 namespace mtl {
 
   template <class T>
@@ -9,4 +19,16 @@
               magnitude_type;
     };
 
+  template <class T>
+    struct linalg_traits<std::vector<T> > {
+      typedef oned_tag  dimension;
+      typedef dense_tag sparsity;
+      typedef T         value_type;
+      typedef typename number_traits<value_type>::magnitude_type 
+              magnitude_type;
+    };
+
+
 }
+
+#endif // ITL_MTL_AMEND_H
diff -Naur itl-4.0.0-1-orig/itl/interface/detail/mtl_classical_gram_schmidt.h itl-4.0.0-1/itl/interface/detail/mtl_classical_gram_schmidt.h
--- itl-4.0.0-1-orig/itl/interface/detail/mtl_classical_gram_schmidt.h	Fri Oct 26 10:45:44 2001
+++ itl-4.0.0-1/itl/interface/detail/mtl_classical_gram_schmidt.h	Wed Feb 19 10:37:14 2003
@@ -69,6 +69,8 @@
 #include <itl/itl.h>
 #include <itl/itl_tags.h>
 #include <mtl/matrix.h>
+#include <itl/interface/detail/mtl_amend.h> //for linalg_traits of std::vector
+
 
 namespace itl {
   //in parallel envirnment, this is an all-reduce operation
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.