diff options
author | Martin Wilke <miwi@FreeBSD.org> | 2008-02-15 17:39:03 +0000 |
---|---|---|
committer | Martin Wilke <miwi@FreeBSD.org> | 2008-02-15 17:39:03 +0000 |
commit | c4adc8534a0e26b7b00b4a258ea43fb0721646d3 (patch) | |
tree | 034f88b668d23255c88b42700e56e74e69349ea2 /graphics/nurbs++ | |
parent | 7ade77179ed800bfda14bdede104d07924dfe1c4 (diff) |
- Fix build with gcc 4.2
- Pass maintainership to submitter
PR: 120626
Submitted by: Pietro Cerutti <gahr@gahr.ch>
Notes
Notes:
svn path=/head/; revision=207258
Diffstat (limited to 'graphics/nurbs++')
18 files changed, 373 insertions, 8 deletions
diff --git a/graphics/nurbs++/Makefile b/graphics/nurbs++/Makefile index a3d74a674321..5917c7773106 100644 --- a/graphics/nurbs++/Makefile +++ b/graphics/nurbs++/Makefile @@ -12,7 +12,7 @@ CATEGORIES= graphics MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} MASTER_SITE_SUBDIR= libnurbs -MAINTAINER= ports@FreeBSD.org +MAINTAINER= gahr@gahr.ch COMMENT= A C++ library for representing curves or surfaces USE_AUTOTOOLS= libtool:15 @@ -22,10 +22,4 @@ USE_LDCONFIG= yes MAN1= nurbs++-config.1 -.include <bsd.port.pre.mk> - -.if ${OSVERSION} >= 700042 -BROKEN= Broken with gcc 4.2 -.endif - -.include <bsd.port.post.mk> +.include <bsd.port.mk> diff --git a/graphics/nurbs++/files/patch-image_color.cpp b/graphics/nurbs++/files/patch-image_color.cpp new file mode 100644 index 000000000000..92830f043182 --- /dev/null +++ b/graphics/nurbs++/files/patch-image_color.cpp @@ -0,0 +1,29 @@ +--- image/color.cpp.orig 2008-02-13 22:28:08.000000000 +0100 ++++ image/color.cpp 2008-02-13 22:28:56.000000000 +0100 +@@ -50,7 +50,7 @@ + Color blackColor(0,0,0) ; + */ + +- double ++ template<> double + Matrix<Color>::norm(void) { + #ifdef USE_EXCEPTION + throw MatrixErr(); +@@ -63,7 +63,7 @@ + } + + #ifndef USING_VCC +- int Matrix<Color>::read(char* filename,int r, int c) { ++ template<> int Matrix<Color>::read(char* filename,int r, int c) { + ifstream fin(filename) ; + if(!fin) { + resize(1,1) ; +@@ -89,7 +89,7 @@ + } + #endif + +- int Vector<Color>::minIndex() const { ++ template<> int Vector<Color>::minIndex() const { + #ifdef USE_EXCEPTION + throw MatrixErr() ; + #else diff --git a/graphics/nurbs++/files/patch-matrix_barray2d_uchar.cpp b/graphics/nurbs++/files/patch-matrix_barray2d_uchar.cpp new file mode 100644 index 000000000000..36c8aa860eb8 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_barray2d_uchar.cpp @@ -0,0 +1,11 @@ +--- matrix/barray2d_uchar.cpp.orig 2008-02-13 22:18:33.000000000 +0100 ++++ matrix/barray2d_uchar.cpp 2008-02-13 22:18:50.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +-ostream& ++template<> ostream& + Basic2DArray<unsigned char>::print(ostream& os) const + { + int i, j; diff --git a/graphics/nurbs++/files/patch-matrix_barray_complex.cpp b/graphics/nurbs++/files/patch-matrix_barray_complex.cpp new file mode 100644 index 000000000000..39af5c841c12 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_barray_complex.cpp @@ -0,0 +1,11 @@ +--- matrix/barray_complex.cpp.orig 2008-02-13 22:26:03.000000000 +0100 ++++ matrix/barray_complex.cpp 2008-02-13 22:26:20.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +-ostream& ++template<> ostream& + BasicArray<Complex>::print(ostream& os) const{ + const int iend = size(); + diff --git a/graphics/nurbs++/files/patch-matrix_matrix_char.cpp b/graphics/nurbs++/files/patch-matrix_matrix_char.cpp new file mode 100644 index 000000000000..c1eee4075273 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_matrix_char.cpp @@ -0,0 +1,38 @@ +--- matrix/matrix_char.cpp.orig 2008-02-13 22:21:07.000000000 +0100 ++++ matrix/matrix_char.cpp 2008-02-13 22:21:42.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- Matrix<char>& ++ template<> Matrix<char>& + Matrix<char>::operator*=(double a) + { + char *p1 ; +@@ -40,7 +40,7 @@ + return *this ; + } + +- Matrix<char>& ++ template<> Matrix<char>& + Matrix<char>::operator+=(double a) + { + char *p1 ; +@@ -51,7 +51,7 @@ + return *this ; + } + +- Matrix<char>& ++ template<> Matrix<char>& + Matrix<char>::operator-=(double a) + { + char *p1 ; +@@ -62,7 +62,7 @@ + return *this ; + } + +- Matrix<char>& ++ template<> Matrix<char>& + Matrix<char>::operator/=(double a) + { + char *p1 ; diff --git a/graphics/nurbs++/files/patch-matrix_matrix_complex.cpp b/graphics/nurbs++/files/patch-matrix_matrix_complex.cpp new file mode 100644 index 000000000000..2b85957043a1 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_matrix_complex.cpp @@ -0,0 +1,11 @@ +--- matrix/matrix_complex.cpp.orig 2008-02-13 22:27:09.000000000 +0100 ++++ matrix/matrix_complex.cpp 2008-02-13 22:27:30.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- double Matrix<Complex>::norm(void){ ++ template<> double Matrix<Complex>::norm(void){ + int i,j ; + double sumR, sumI, maxsum; + int init=0 ; diff --git a/graphics/nurbs++/files/patch-matrix_matrix_double.cpp b/graphics/nurbs++/files/patch-matrix_matrix_double.cpp new file mode 100644 index 000000000000..2f9983544561 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_matrix_double.cpp @@ -0,0 +1,11 @@ +--- matrix/matrix_double.cpp.orig 2008-02-13 22:16:31.000000000 +0100 ++++ matrix/matrix_double.cpp 2008-02-13 22:16:45.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- void Matrix<double>::qSort(){ ++ template<> void Matrix<double>::qSort(){ + qsort((char*)m,rows()*cols(),sizeof(double),compareDouble) ; + } + diff --git a/graphics/nurbs++/files/patch-matrix_matrix_float.cpp b/graphics/nurbs++/files/patch-matrix_matrix_float.cpp new file mode 100644 index 000000000000..c60b8c8cf1a1 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_matrix_float.cpp @@ -0,0 +1,11 @@ +--- matrix/matrix_float.cpp.orig 2008-02-13 22:14:25.000000000 +0100 ++++ matrix/matrix_float.cpp 2008-02-13 22:14:45.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- void Matrix<float>::qSort(){ ++ template<> void Matrix<float>::qSort(){ + qsort((char*)m,rows()*cols(),sizeof(float),compareFloat) ; + } + diff --git a/graphics/nurbs++/files/patch-matrix_matrix_hpoint.cpp b/graphics/nurbs++/files/patch-matrix_matrix_hpoint.cpp new file mode 100644 index 000000000000..67eb18a33891 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_matrix_hpoint.cpp @@ -0,0 +1,38 @@ +--- matrix/matrix_hpoint.cpp.orig 2008-02-13 22:23:41.000000000 +0100 ++++ matrix/matrix_hpoint.cpp 2008-02-13 22:24:43.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- double ++ template<> double + Matrix<HPoint3Df>::norm(void) { + int i,j ; + double sumX, sumY, sumZ, sumW, maxsum; +@@ -58,7 +58,7 @@ + } + + +- double ++ template<> double + Matrix<HPoint3Dd>::norm(void) { + int i,j ; + double sumX, sumY, sumZ, sumW, maxsum; +@@ -89,7 +89,7 @@ + } + + +- double ++ template<> double + Matrix<HPoint2Df>::norm(void) { + int i,j ; + double sumX, sumY, sumZ, sumW, maxsum; +@@ -119,7 +119,7 @@ + return sqrt(maxsum); + } + +- double ++ template<> double + Matrix<HPoint2Dd>::norm(void) { + int i,j ; + double sumX, sumY, sumZ, sumW, maxsum; diff --git a/graphics/nurbs++/files/patch-matrix_matrix_int.cpp b/graphics/nurbs++/files/patch-matrix_matrix_int.cpp new file mode 100644 index 000000000000..4a951646984e --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_matrix_int.cpp @@ -0,0 +1,43 @@ +--- matrix/matrix_int.cpp.orig 2008-02-13 22:11:44.000000000 +0100 ++++ matrix/matrix_int.cpp 2008-02-13 22:12:25.000000000 +0100 +@@ -29,11 +29,11 @@ + + namespace PLib { + +- void Matrix<int>::qSort(){ ++ template<> void Matrix<int>::qSort(){ + qsort((char*)m,rows()*cols(),sizeof(int),compareInt) ; + } + +- Matrix<int>& ++ template<> Matrix<int>& + Matrix<int>::operator*=(double a) + { + int *p1 ; +@@ -46,7 +46,7 @@ + return *this ; + } + +- Matrix<int>& ++ template<> Matrix<int>& + Matrix<int>::operator+=(double a) + { + int *p1 ; +@@ -57,7 +57,7 @@ + return *this ; + } + +- Matrix<int>& ++ template<> Matrix<int>& + Matrix<int>::operator-=(double a) + { + int *p1 ; +@@ -68,7 +68,7 @@ + return *this ; + } + +- Matrix<int>& ++ template<> Matrix<int>& + Matrix<int>::operator/=(double a) + { + int *p1 ; diff --git a/graphics/nurbs++/files/patch-matrix_matrix_point.cpp b/graphics/nurbs++/files/patch-matrix_matrix_point.cpp new file mode 100644 index 000000000000..079c8eda3ab1 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_matrix_point.cpp @@ -0,0 +1,38 @@ +--- matrix/matrix_point.cpp.orig 2008-02-13 22:22:23.000000000 +0100 ++++ matrix/matrix_point.cpp 2008-02-13 22:23:16.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- double ++ template<> double + Matrix<Point3Df>::norm(void) { + int i,j ; + double sumX, sumY, sumZ, maxsum; +@@ -55,7 +55,7 @@ + return sqrt(maxsum); + } + +- double ++ template<> double + Matrix<Point3Dd>::norm(void) { + int i,j ; + double sumX, sumY, sumZ, maxsum; +@@ -83,7 +83,7 @@ + return sqrt(maxsum); + } + +- double ++ template<> double + Matrix<Point2Df>::norm(void) { + int i,j ; + double sumX, sumY, sumZ, maxsum; +@@ -111,7 +111,7 @@ + return sqrt(maxsum); + } + +- double ++ template<> double + Matrix<Point2Dd>::norm(void) { + int i,j ; + double sumX, sumY, sumZ, maxsum; diff --git a/graphics/nurbs++/files/patch-matrix_matrix_uchar.cpp b/graphics/nurbs++/files/patch-matrix_matrix_uchar.cpp new file mode 100644 index 000000000000..c71fea3227fb --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_matrix_uchar.cpp @@ -0,0 +1,38 @@ +--- matrix/matrix_uchar.cpp.orig 2008-02-13 22:39:32.000000000 +0100 ++++ matrix/matrix_uchar.cpp 2008-02-13 22:40:11.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- Matrix<unsigned char>& ++ template<> Matrix<unsigned char>& + Matrix<unsigned char>::operator*=(double a) + { + unsigned char *p1 ; +@@ -40,7 +40,7 @@ + return *this ; + } + +- Matrix<unsigned char>& ++ template<> Matrix<unsigned char>& + Matrix<unsigned char>::operator+=(double a) + { + unsigned char *p1 ; +@@ -52,7 +52,7 @@ + } + + +- Matrix<unsigned char>& ++ template<> Matrix<unsigned char>& + Matrix<unsigned char>::operator-=(double a) + { + unsigned char *p1 ; +@@ -64,7 +64,7 @@ + } + + +- Matrix<unsigned char>& ++ template<> Matrix<unsigned char>& + Matrix<unsigned char>::operator/=(double a) + { + unsigned char *p1 ; diff --git a/graphics/nurbs++/files/patch-matrix_vector_double.cpp b/graphics/nurbs++/files/patch-matrix_vector_double.cpp new file mode 100644 index 000000000000..370dea064155 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_vector_double.cpp @@ -0,0 +1,11 @@ +--- matrix/vector_double.cpp.orig 2008-02-13 22:17:22.000000000 +0100 ++++ matrix/vector_double.cpp 2008-02-13 22:17:40.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- void Vector<double>::qSortStd(){ ++ template<> void Vector<double>::qSortStd(){ + qsort((char*)memory(),n(),sizeof(float),compareDouble) ; + } + diff --git a/graphics/nurbs++/files/patch-matrix_vector_float.cpp b/graphics/nurbs++/files/patch-matrix_vector_float.cpp new file mode 100644 index 000000000000..063dd1ac321c --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_vector_float.cpp @@ -0,0 +1,11 @@ +--- matrix/vector_float.cpp.orig 2008-02-13 22:15:33.000000000 +0100 ++++ matrix/vector_float.cpp 2008-02-13 22:15:51.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- void Vector<float>::qSortStd(){ ++ template<> void Vector<float>::qSortStd(){ + qsort((char*)memory(),n(),sizeof(float),compareFloat) ; + } + diff --git a/graphics/nurbs++/files/patch-matrix_vector_int.cpp b/graphics/nurbs++/files/patch-matrix_vector_int.cpp new file mode 100644 index 000000000000..66ebaf1998c9 --- /dev/null +++ b/graphics/nurbs++/files/patch-matrix_vector_int.cpp @@ -0,0 +1,11 @@ +--- matrix/vector_int.cpp.orig 2008-02-13 22:13:23.000000000 +0100 ++++ matrix/vector_int.cpp 2008-02-13 22:13:39.000000000 +0100 +@@ -27,7 +27,7 @@ + + namespace PLib { + +- void Vector<int>::qSortStd(){ ++ template<> void Vector<int>::qSortStd(){ + qsort((char*)memory(),n(),sizeof(int),compareInt) ; + } + diff --git a/graphics/nurbs++/files/patch-nurbs_d_nurbs.cpp b/graphics/nurbs++/files/patch-nurbs_d_nurbs.cpp new file mode 100644 index 000000000000..6d67f607e307 --- /dev/null +++ b/graphics/nurbs++/files/patch-nurbs_d_nurbs.cpp @@ -0,0 +1,11 @@ +--- nurbs/d_nurbs.cpp.orig 2008-02-13 22:33:03.000000000 +0100 ++++ nurbs/d_nurbs.cpp 2008-02-13 22:33:32.000000000 +0100 +@@ -10,7 +10,7 @@ + return firstDn(u) ; + } + +-void NurbsCurve<double,2>::makeCircle(const Point_nD<double,2>& O, double r, double as, double ae){ ++template<> void NurbsCurve<double,2>::makeCircle(const Point_nD<double,2>& O, double r, double as, double ae){ + makeCircle(O,Point_nD<double,2>(1,0),Point_nD<double,2>(0,1),r,as,ae) ; + } + diff --git a/graphics/nurbs++/files/patch-nurbs_d_surface.cpp b/graphics/nurbs++/files/patch-nurbs_d_surface.cpp new file mode 100644 index 000000000000..09cd985bfe79 --- /dev/null +++ b/graphics/nurbs++/files/patch-nurbs_d_surface.cpp @@ -0,0 +1,24 @@ +--- nurbs/d_surface.cpp.orig 2008-02-13 22:34:54.000000000 +0100 ++++ nurbs/d_surface.cpp 2008-02-13 22:35:05.000000000 +0100 +@@ -19,21 +19,4 @@ + cerr << "NOT DEFINED FOR 2D SURFACES.\n" ; + return 0; + } +- +-#ifdef NO_IMPLICIT_TEMPLATES +- +- template class InterPoint<double,2> ; +- template class InterPoint<double,3> ; +- +- template class BasicList<InterPoint<double,2> > ; +- template class BasicList<InterPoint<double,3> > ; +- +- template class ParaSurface<double,2> ; +- template class ParaSurface<double,3> ; +- +- template void intersectSurfaces(const ParaSurface<double,2>&, const ParaSurface<double,2>&, BasicList<InterPoint<double,2> >&, int, double, double, double, double) ; +- template void intersectSurfaces(const ParaSurface<double,3>&, const ParaSurface<double,3>&, BasicList<InterPoint<double,3> >&, int, double, double, double, double) ; +- +-#endif +- + } diff --git a/graphics/nurbs++/files/patch-nurbs_f_surface.cpp b/graphics/nurbs++/files/patch-nurbs_f_surface.cpp new file mode 100644 index 000000000000..23fbdaeb22ee --- /dev/null +++ b/graphics/nurbs++/files/patch-nurbs_f_surface.cpp @@ -0,0 +1,24 @@ +--- nurbs/f_surface.cpp.orig 2008-02-13 22:31:09.000000000 +0100 ++++ nurbs/f_surface.cpp 2008-02-13 22:31:32.000000000 +0100 +@@ -20,21 +20,4 @@ + return 0; + } + +-#ifdef NO_IMPLICIT_TEMPLATES +- +- template class InterPoint<float,2> ; +- template class InterPoint<float,3> ; +- +- template class BasicList<InterPoint<float,2> > ; +- template class BasicList<InterPoint<float,3> > ; +- +- template class ParaSurface<float,2> ; +- template class ParaSurface<float,3> ; +- +- template void intersectSurfaces(const ParaSurface<float,2>&, const ParaSurface<float,2>&, BasicList<InterPoint<float,2> >&, int, float, float, float, float) ; +- +- template void intersectSurfaces(const ParaSurface<float,3>&, const ParaSurface<float,3>&, BasicList<InterPoint<float,3> >&, int, float, float, float, float) ; +- +-#endif +- + } |