summaryrefslogtreecommitdiff
path: root/math/mtl/files
diff options
context:
space:
mode:
authorBrendan Fabeny <bf@FreeBSD.org>2012-01-01 17:34:49 +0000
committerBrendan Fabeny <bf@FreeBSD.org>2012-01-01 17:34:49 +0000
commit486a856d6bb14bad22e55b3d87f80a69725aa3dd (patch)
tree2a445277d1931fe7cb8a0742786c969c93e84c21 /math/mtl/files
parent- Update to 1.241 (diff)
update to 2.1.2.23; add LICENSE and test targets; respect CXX and
CXXFLAGS; fix the build with lang/gcc46 (refactored libstdc++ headers) and clang (stricter unqualified lookups in templates); install examples
Notes
Notes: svn path=/head/; revision=288375
Diffstat (limited to 'math/mtl/files')
-rw-r--r--math/mtl/files/patch-mtl__external_vector.h10
-rw-r--r--math/mtl/files/patch-mtl__light1D.h12
-rw-r--r--math/mtl/files/patch-mtl__linalg_vec.h10
-rw-r--r--math/mtl/files/patch-test__src__algo_test.h60
-rw-r--r--math/mtl/files/patch-test__src__matrix_test.h12
5 files changed, 104 insertions, 0 deletions
diff --git a/math/mtl/files/patch-mtl__external_vector.h b/math/mtl/files/patch-mtl__external_vector.h
new file mode 100644
index 000000000000..55cff6e58159
--- /dev/null
+++ b/math/mtl/files/patch-mtl__external_vector.h
@@ -0,0 +1,10 @@
+--- mtl/external_vector.h.orig 2007-04-10 16:03:10.000000000 -0400
++++ mtl/external_vector.h 2012-01-01 03:59:14.000000000 -0500
+@@ -3,6 +3,7 @@
+
+ #include "mtl/mtl_iterator.h"
+ #include "mtl/mtl_exception.h"
++#include <cstddef>
+
+ namespace mtl {
+
diff --git a/math/mtl/files/patch-mtl__light1D.h b/math/mtl/files/patch-mtl__light1D.h
new file mode 100644
index 000000000000..dfd3ad8d296f
--- /dev/null
+++ b/math/mtl/files/patch-mtl__light1D.h
@@ -0,0 +1,12 @@
+--- mtl/light1D.h.orig 2007-04-10 16:03:10.000000000 -0400
++++ mtl/light1D.h 2012-01-01 03:58:53.000000000 -0500
+@@ -19,7 +19,8 @@
+ #include "mtl/reverse_iter.h"
+ #include "mtl/matrix_traits.h"
+ #include "mtl/scaled1D.h"
+-#include <stdlib.h>
++#include <cstddef>
++#include <cstdlib>
+
+ namespace mtl {
+
diff --git a/math/mtl/files/patch-mtl__linalg_vec.h b/math/mtl/files/patch-mtl__linalg_vec.h
new file mode 100644
index 000000000000..d8910e343a12
--- /dev/null
+++ b/math/mtl/files/patch-mtl__linalg_vec.h
@@ -0,0 +1,10 @@
+--- mtl/linalg_vec.h.orig 2007-04-10 16:03:10.000000000 -0400
++++ mtl/linalg_vec.h 2012-01-01 06:06:12.000000000 -0500
+@@ -116,6 +116,7 @@
+ typedef difference_type Vec_difference_type;
+ typedef iterator Vec_iterator;
+ typedef const_iterator Vec_const_iterator;
++ typedef value_type Vec_value_type;
+
+ class IndexArray {
+ public:
diff --git a/math/mtl/files/patch-test__src__algo_test.h b/math/mtl/files/patch-test__src__algo_test.h
new file mode 100644
index 000000000000..69d901ccdb2c
--- /dev/null
+++ b/math/mtl/files/patch-test__src__algo_test.h
@@ -0,0 +1,60 @@
+--- test/src/algo_test.h.orig 2007-04-10 16:03:10.000000000 -0400
++++ test/src/algo_test.h 2012-01-01 08:04:04.000000000 -0500
+@@ -8,6 +8,28 @@
+ using mtl::dense1D;
+
+ template <class Matrix>
++void
++set_diagonal_test(std::string test_name, Matrix& A, bool& success)
++{
++ if (A.is_unit()) {
++ std::cout << test_name.c_str() << " skipping set_diagonal" << std::endl;
++ return;
++ }
++ typedef typename mtl::matrix_traits<Matrix>::value_type T;
++ typedef typename mtl::matrix_traits<Matrix>::size_type Int;
++ // set_diagnal
++ Int i;
++ mtl::set_diagonal(A, T(1));
++
++ for (i = 0; i < A.nrows() && i < A.ncols(); ++i)
++ if (A(i,i) != T(1)) {
++ std::cout << test_name.c_str() << " failed set_diagnal(A,a) *****" << std::endl;
++ success = false;
++ break;
++ }
++}
++
++template <class Matrix>
+ bool
+ mat_algo_test(Matrix& A, std::string test_name)
+ {
+@@ -110,28 +132,6 @@
+ return success;
+ }
+
+-template <class Matrix>
+-void
+-set_diagonal_test(std::string test_name, Matrix& A, bool& success)
+-{
+- if (A.is_unit()) {
+- std::cout << test_name.c_str() << " skipping set_diagonal" << std::endl;
+- return;
+- }
+- typedef typename mtl::matrix_traits<Matrix>::value_type T;
+- typedef typename mtl::matrix_traits<Matrix>::size_type Int;
+- // set_diagnal
+- Int i;
+- mtl::set_diagonal(A, T(1));
+-
+- for (i = 0; i < A.nrows() && i < A.ncols(); ++i)
+- if (A(i,i) != T(1)) {
+- std::cout << test_name.c_str() << " failed set_diagnal(A,a) *****" << std::endl;
+- success = false;
+- break;
+- }
+-}
+-
+ template <class Mat>
+ inline void
+ fill_matrix(Mat& A, int /*sub*/, int /*super*/, mtl::rectangle_tag)
diff --git a/math/mtl/files/patch-test__src__matrix_test.h b/math/mtl/files/patch-test__src__matrix_test.h
new file mode 100644
index 000000000000..11d3d411cdce
--- /dev/null
+++ b/math/mtl/files/patch-test__src__matrix_test.h
@@ -0,0 +1,12 @@
+--- test/src/matrix_test.h.orig 2007-04-10 16:03:10.000000000 -0400
++++ test/src/matrix_test.h 2012-01-01 07:40:34.000000000 -0500
+@@ -52,6 +52,9 @@
+
+ #include "fill_matrix.h"
+
++template <class Matrix>
++void
++do_test(Matrix& A, std::string test_name);
+
+ template <class Matrix>
+ void