--- src5.1.3/netgen-4.5_SRC/makeForSalome.sh.orig 2010-04-16 21:03:56.447133077 -0300 +++ src5.1.3/netgen-4.5_SRC/makeForSalome.sh 2010-04-16 21:33:34.394130953 -0300 @@ -17,6 +17,8 @@ make -C libsrc/opti make -C libsrc/stlgeom make -C libsrc/occ +make -C libsrc/visualization +make -C libsrc/sockets if [ ! -d install ] ; then mkdir install @@ -29,3 +31,7 @@ fi cp libsrc/interface/nglib.h libsrc/general/*.hpp libsrc/csg/*.hpp libsrc/geom2d/*.hpp \ + libsrc/gprim/*.hpp libsrc/linalg/*.hpp libsrc/meshing/*.hpp \ + libsrc/occ/*.hpp libsrc/opti/*.hpp libsrc/include/mydefs.hpp \ + libsrc/stlgeom/*.hpp libsrc/include/mystdlib.h \ + install/include --- src5.1.3/NETGENPLUGIN_SRC_5.1.3/adm_local/unix/config_files/check_NETGEN.m4.orig 2010-04-16 16:32:59.970134971 -0300 +++ src5.1.3/NETGENPLUGIN_SRC_5.1.3/adm_local/unix/config_files/check_NETGEN.m4 2010-04-16 21:33:50.788131063 -0300 @@ -102,7 +102,7 @@ AC_MSG_CHECKING(for Netgen libraries) LDFLAGS_old="$LDFLAGS" - LDFLAGS="-L. -lNETGEN $CAS_LDPATH -lTKBRep -lTKShHealing -lTKSTEP -lTKXSBase -lTKIGES -lTKSTL -lTKTopAlgo $LDFLAGS" + LDFLAGS="-L. -lNETGEN $CAS_LDPATH -lTKBRep -lTKShHealing -lTKSTEP -lTKXSBase -lTKIGES -lTKSTL -lTKTopAlgo -lTKOffset -lTogl1.7 -lGL -lGLU -ltcl -ltk $LDFLAGS" AC_TRY_COMPILE(#include <iostream> #include <fstream> @@ -123,8 +123,10 @@ ar x "$NETGEN_LIBS_DIR/libla.a"; ar x "$NETGEN_LIBS_DIR/libstlgeom.a"; ar x "$NETGEN_LIBS_DIR/libgeom2d.a"; - $CXX -shared linopt.o bfgs.o linsearch.o global.o bisect.o meshtool.o refine.o ruler3.o improve3.o adfront3.o tetrarls.o prism2rls.o profiler.o pyramidrls.o pyramid2rls.o netrule3.o ruler2.o meshclass.o improve2.o adfront2.o netrule2.o triarls.o geomsearch.o secondorder.o meshtype.o parser3.o quadrls.o specials.o parser2.o meshing2.o meshing3.o meshfunc.o localh.o improve2gen.o delaunay.o boundarylayer.o msghandler.o meshfunc2d.o smoothing2.o smoothing3.o topology.o curvedelems_new.o clusters.o zrefine.o ngexception.o geomtest3d.o geom2d.o geom2dmesh.o geom3d.o adtree.o transform3d.o geomfuncs.o polynomial.o densemat.o vector.o basemat.o sparsmat.o algprim.o brick.o manifold.o bspline2d.o meshsurf.o csgeom.o polyhedra.o curve2d.o singularref.o edgeflw.o solid.o explicitcurve2d.o specpoin.o gencyl.o revolution.o genmesh.o genmesh2d.o spline3d.o surface.o identify.o triapprox.o meshstlsurface.o stlline.o stltopology.o stltool.o stlgeom.o stlgeomchart.o stlgeommesh.o table.o optmem.o spbita2d.o hashtabl.o sort.o flags.o seti.o bitarray.o array.o symbolta.o mystring.o moveablemem.o spline.o splinegeometry.o ngnewdelete.o nglib.o hprefinement.o Partition_Inter2d.o Partition_Loop.o Partition_Loop3d.o Partition_Inter3d.o Partition_Loop2d.o Partition_Spliter.o occgeom.o occgenmesh.o occmeshsurf.o -o libNETGEN.so; - rm -rf linopt.o bfgs.o linsearch.o global.o bisect.o meshtool.o refine.o ruler3.o improve3.o adfront3.o tetrarls.o prism2rls.o profiler.o pyramidrls.o pyramid2rls.o netrule3.o ruler2.o meshclass.o improve2.o adfront2.o netrule2.o triarls.o geomsearch.o secondorder.o meshtype.o parser3.o quadrls.o specials.o parser2.o meshing2.o meshing3.o meshfunc.o localh.o improve2gen.o delaunay.o boundarylayer.o msghandler.o meshfunc2d.o smoothing2.o smoothing3.o topology.o curvedelems_new.o clusters.o zrefine.o ngexception.o geomtest3d.o geom2d.o geom2dmesh.o geom3d.o adtree.o transform3d.o geomfuncs.o polynomial.o densemat.o vector.o basemat.o sparsmat.o algprim.o brick.o manifold.o bspline2d.o meshsurf.o csgeom.o polyhedra.o curve2d.o singularref.o edgeflw.o solid.o explicitcurve2d.o specpoin.o gencyl.o revolution.o genmesh.o genmesh2d.o spline3d.o surface.o identify.o triapprox.o meshstlsurface.o stlline.o stltopology.o stltool.o stlgeom.o stlgeomchart.o stlgeommesh.o table.o optmem.o spbita2d.o hashtabl.o sort.o flags.o seti.o bitarray.o array.o symbolta.o mystring.o moveablemem.o spline.o splinegeometry.o ngnewdelete.o nglib.o hprefinement.o Partition_Inter2d.o Partition_Loop.o Partition_Loop3d.o Partition_Inter3d.o Partition_Loop2d.o Partition_Spliter.o occgeom.o occgenmesh.o occmeshsurf.o csgparser.o dynamicmem.o extrusion.o occconstruction.o parthreads.o readuser.o writeabaqus.o writediffpack.o writeelmer.o writefeap.o writefluent.o writegmsh.o writejcm.o writepermas.o writetecplot.o writetochnog.o writeuser.o wuchemnitz.o, + ar x "$NETGEN_LIBS_DIR/libvis.a"; + ar x "$NETGEN_LIBS_DIR/libsockets.a"; + $CXX -shared *.o $NETGEN_LIBS_DIR/*.o -o libNETGEN.so; + rm -f *.o, Netgen_ok=no) AC_CACHE_VAL(salome_cv_netgen_lib,[ --- src5.1.3/netgen-4.5_SRC/libsrc/include/incvis.hpp.orig 2010-04-16 19:06:26.233131982 -0300 +++ src5.1.3/netgen-4.5_SRC/libsrc/include/incvis.hpp 2010-04-16 19:09:04.058131762 -0300 @@ -12,10 +12,14 @@ #include <tix8.1.h> */ +#define USE_INTERP_RESULT 1 +#define USE_INTERP_ERRORLINE 1 #include <tcl.h> +#undef USE_INTERP_ERRORLINE +#undef USE_INTERP_RESULT #include <tk.h> -#if TK_MAJOR_VERSION==8 && TK_MINOR_VERSION==4 +#if TK_MAJOR_VERSION==8 && TK_MINOR_VERSION>=4 #define tcl_const const #else #define tcl_const --- src5.1.3/netgen-4.5_SRC/libsrc/visualization/vssolution.cpp.orig 2010-04-16 16:57:15.572175880 -0300 +++ src5.1.3/netgen-4.5_SRC/libsrc/visualization/vssolution.cpp 2010-04-16 17:05:14.054132904 -0300 @@ -4021,7 +4021,7 @@ int pointpos; // SZ char * pch; - pch=strchr(scalname,'.'); + pch=strchr((char *)scalname,'.'); pointpos = int(pch-scalname+1); for (i = 0; i < vssolution.soldata.Size(); i++) --- src5.1.3/netgen-4.5_SRC/ngtcltk/ngpkg.cpp.orig 2010-04-16 20:35:14.216134041 -0300 +++ src5.1.3/netgen-4.5_SRC/ngtcltk/ngpkg.cpp 2010-04-16 21:01:56.046134743 -0300 @@ -39,7 +39,7 @@ #include "../libsrc/sockets/socketmanager.hpp" #endif -extern bool nodisplay; +bool nodisplay; namespace netgen { @@ -176,7 +176,8 @@ -#ifndef SMALLLIB +//#ifndef SMALLLIB +#if 0 // Destination for messages, errors, ... void Ng_PrintDest(const char * s) { @@ -191,12 +192,13 @@ #endif static clock_t starttimea; +#if 0 void ResetTime () { starttimea = clock(); } -#ifndef SMALLLIB +//#ifndef SMALLLIB double GetTime () { return double(clock() - starttimea) / CLOCKS_PER_SEC; @@ -2854,7 +2856,8 @@ void SetVisualScene (Tcl_Interp * interp) { #ifdef OPENGL -#ifndef SMALLLIB +//#ifndef SMALLLIB +#if 0 const char * vismode = vispar.selectvisual; // Tcl_GetVar (interp, "selectvisual", 0); vs = &vscross; --- src5.1.3/netgen-4.5_SRC/libsrc/interface/Makefile.orig 2010-04-16 21:06:39.248134463 -0300 +++ src5.1.3/netgen-4.5_SRC/libsrc/interface/Makefile 2010-04-16 21:21:38.895130787 -0300 @@ -1,5 +1,5 @@ #src = nginterface.cpp writeuser.cpp writediffpack.cpp writeabaqus.cpp writefluent.cpp writepermas.cpp writetochnog.cpp writetecplot.cpp wuchemnitz.cpp writetochnog.cpp writefeap.cpp writeelmer.cpp writegmsh.cpp writejcm.cpp readuser.cpp importsolution.cpp -src = writeuser.cpp writediffpack.cpp writeabaqus.cpp writefluent.cpp writepermas.cpp writetochnog.cpp writetecplot.cpp wuchemnitz.cpp writetochnog.cpp writefeap.cpp writeelmer.cpp writegmsh.cpp writejcm.cpp readuser.cpp nglib.cpp ngnewdelete.cpp +src = nginterface.cpp writeuser.cpp writediffpack.cpp writeabaqus.cpp writefluent.cpp writepermas.cpp writetochnog.cpp writetecplot.cpp wuchemnitz.cpp writetochnog.cpp writefeap.cpp writeelmer.cpp writegmsh.cpp writejcm.cpp readuser.cpp nglib.cpp ngnewdelete.cpp importsolution.cpp # lib = nginterface libpath = libsrc/interface --- src5.1.3/netgen-4.5_SRC/libsrc/sockets/sockets.cpp.orig 2010-04-16 21:42:16.675133307 -0300 +++ src5.1.3/netgen-4.5_SRC/libsrc/sockets/sockets.cpp 2010-04-16 21:49:37.042133061 -0300 @@ -10,7 +10,9 @@ #include "sockets.hpp" -#include <string> +#include <string.h> +#include <stdio.h> +#include <stdlib.h> #include <sstream> #include <iostream> #include <errno.h> @@ -142,7 +144,7 @@ m_sock ( -1 ) { - memset ( &m_addr, + ::memset ( &m_addr, 0, sizeof ( m_addr ) ); @@ -353,7 +355,7 @@ s = ""; - memset ( buf, 0, MAXRECV + 1 ); + ::memset ( buf, 0, MAXRECV + 1 ); int status = ::recv ( m_sock, buf, MAXRECV, 0 ); @@ -364,7 +366,7 @@ #else latesterror = errno; #endif - printf("status == -1 errno == %d in Socket::recv\n", latesterror); + ::printf("status == -1 errno == %d in Socket::recv\n", latesterror); return 0; } else if ( status == 0 ) @@ -378,7 +380,7 @@ //cout << "sizestring " << sizestring << endl; - int size = atoi(sizestring.c_str()); + int size = ::atoi(sizestring.c_str()); s.reserve(size); @@ -411,7 +413,7 @@ #else latesterror = errno; #endif - printf("status == -1 errno == %d in Socket::recv\n", latesterror); + ::printf("status == -1 errno == %d in Socket::recv\n", latesterror); return 0; } else if ( status == 0 ) @@ -691,13 +693,13 @@ { if ( ! Socket::create() ) { - printf("Could not create client socket.\n" ); + ::printf("Could not create client socket.\n" ); throw SocketException ( "Could not create client socket." ); } if ( ! Socket::connect ( host, port ) ) { - printf( "Could not bind to port.\n" ); + ::printf( "Could not bind to port.\n" ); throw SocketException ( "Could not bind to port." ); } diff -p -up src5.1.3/netgen-4.5_SRC/libsrc/makefile.mach.LINUX.orig src5.1.3/netgen-4.5_SRC/libsrc/makefile.mach.LINUX --- src5.1.3/netgen-4.5_SRC/libsrc/makefile.mach.LINUX.orig 2010-04-19 22:42:18.000000000 +0000 +++ src5.1.3/netgen-4.5_SRC/libsrc/makefile.mach.LINUX 2010-04-19 22:58:02.000000000 +0000 @@ -16,11 +16,12 @@ RANLIB=ranlib # CFLAGS2 = -CPLUSPLUSFLAGS2 = -O2 -I/usr/include/GL3.5 -DLINUX \ - -ftemplate-depth-99 -finline-limit=10000 \ - -Wdisabled-optimization -funroll-loops -DnoNGSOLVE - -LINKFLAGS2 = -L/usr/openwin/lib -L/usr/X11R6/lib -L/usr/lib/GL3.5 -lstdc++ +CPLUSPLUSFLAGS2 = $(CXXFLAGS) -O2 -DLINUX -DOPENGL \ + -DTRAFO -DNGSOLVE -DnoADDON -DnoLAPACK \ + -I/usr/include/g++/backward -DnoDEBUG \ + -DHAVE_IOSTREAM \ + -DnoUSE_PARDISO -DSOCKETS -DLAPACK -DFAST +#LINKFLAGS2 = -L/usr/openwin/lib -L/usr/X11R6/lib -L/usr/lib/GL3.5 -lstdc++ # goalngs=goalngs # goaltrafo=goaltrafo diff -p -up src5.1.3/netgen-4.5_SRC/libsrc/makefile.mach.LINUX64.orig src5.1.3/netgen-4.5_SRC/libsrc/makefile.mach.LINUX64 --- src5.1.3/netgen-4.5_SRC/libsrc/makefile.mach.LINUX64.orig 2010-04-19 22:40:54.000000000 +0000 +++ src5.1.3/netgen-4.5_SRC/libsrc/makefile.mach.LINUX64 2010-04-19 22:58:10.000000000 +0000 @@ -11,22 +11,20 @@ RANLIB=ranlib # # CFLAGS2 = -CPLUSPLUSFLAGS2 = -pg -march=nocona -O2 -DLINUX -DOPENGL \ - -ftemplate-depth-99 -finline-limit=100000 \ - -fforce-addr -funroll-loops \ - -DTRAFO -DNGSOLVE -DnoADDON -DnoLAPACK -DnoFAST \ - -DnoOCCGEOMETRY -I/usr/include/g++/backward -DnoDEBUG \ - -I/opt/intel/mkl70/include -DnoOCC52 -DHAVE_IOSTREAM \ +CPLUSPLUSFLAGS2 = $(CXXFLAGS) -O2 -DLINUX -DOPENGL \ + -DTRAFO -DNGSOLVE -DnoADDON -DnoLAPACK \ + -I/usr/include/g++/backward -DnoDEBUG \ + -DHAVE_IOSTREAM \ -DnoUSE_PARDISO -DSOCKETS -DLAPACK -DFAST # -DPML # # # -LINKFLAGS2 = -pg -L/usr/openwin/lib64 -L/usr/X11R6/lib64 -L/usr/lib/GL3.5 -L/usr/lib64 +#LINKFLAGS2 = -pg -L/usr/openwin/lib64 -L/usr/X11R6/lib64 -L/usr/lib/GL3.5 -L/usr/lib64 -SYSLIB2 = -lstdc++ +#SYSLIB2 = -lstdc++ # which BLAS/Lapack ? # -lmkl @@ -36,15 +34,15 @@ SYSLIB2 = -lstdc++ # -lblas -lgmp -lg2c # -llapack -lblas -lgmp -lg2c # lapack = -Llib -lgoto_prescott64p-r1.00 -llapack -lgmp -lg2c -lapack = -L/home/joachim/intel/mkl/8.0/lib/em64t -lmkl_em64t -lmkl_lapack64 -lmkl_blas95 -lmkl_def -lmkl_em64t +#lapack = -L/home/joachim/intel/mkl/8.0/lib/em64t -lmkl_em64t -lmkl_lapack64 -lmkl_blas95 -lmkl_def -lmkl_em64t -goaltrafo = goaltrafo -goalngs = goalngs +#goaltrafo = goaltrafo +#goalngs = goalngs # goaladdon = goaladdon -appngs = lib/$(MACHINE)/*.o -lngsolvebasic +#appngs = lib/$(MACHINE)/*.o -lngsolvebasic # -ltrafoapp # occlib = -L$(OCCLIB_DIR) -lTKIGES -lTKBRep -lTKSTEP -lTKSTL --- src5.1.3/NETGENPLUGIN_SRC_5.1.3/src/NETGEN/Makefile.am.orig 2010-04-19 23:22:13.000000000 +0000 +++ src5.1.3/NETGENPLUGIN_SRC_5.1.3/src/NETGEN/Makefile.am 2010-04-19 23:26:15.000000000 +0000 @@ -32,21 +32,30 @@ lib_LTLIBRARIES = libNETGEN.la LIB_OBJ_O = \ - linopt.o bfgs.o linsearch.o global.o bisect.o meshtool.o refine.o ruler3.o \ - improve3.o adfront3.o tetrarls.o prism2rls.o profiler.o pyramidrls.o pyramid2rls.o \ - netrule3.o ruler2.o meshclass.o improve2.o adfront2.o netrule2.o triarls.o geomsearch.o \ - secondorder.o meshtype.o parser3.o quadrls.o specials.o parser2.o meshing2.o meshing3.o \ - meshfunc.o localh.o improve2gen.o delaunay.o boundarylayer.o msghandler.o \ - meshfunc2d.o smoothing2.o smoothing3.o topology.o curvedelems_new.o clusters.o zrefine.o \ - ngexception.o geomtest3d.o geom2d.o geom2dmesh.o geom3d.o adtree.o transform3d.o geomfuncs.o \ - polynomial.o densemat.o vector.o basemat.o sparsmat.o algprim.o brick.o manifold.o bspline2d.o \ - meshsurf.o csgeom.o polyhedra.o curve2d.o singularref.o edgeflw.o solid.o explicitcurve2d.o \ - specpoin.o gencyl.o revolution.o genmesh.o genmesh2d.o spline3d.o surface.o identify.o \ - triapprox.o meshstlsurface.o stlline.o stltopology.o stltool.o stlgeom.o stlgeomchart.o \ - stlgeommesh.o table.o optmem.o spbita2d.o hashtabl.o sort.o flags.o seti.o bitarray.o \ - array.o symbolta.o mystring.o moveablemem.o spline.o splinegeometry.o ngnewdelete.o nglib.o \ - hprefinement.o Partition_Inter2d.o Partition_Loop.o Partition_Loop3d.o Partition_Inter3d.o \ - Partition_Loop2d.o Partition_Spliter.o occgeom.o occgenmesh.o occmeshsurf.o + Partition_Inter2d.o Partition_Inter3d.o Partition_Loop.o Partition_Loop2d.o \ + Partition_Loop3d.o Partition_Spliter.o adfront2.o adfront3.o adtree.o \ + algprim.o array.o basemat.o bfgs.o bisect.o bitarray.o boundarylayer.o \ + brick.o bspline2d.o clusters.o csgeom.o csgparser.o curve2d.o \ + curvedelems_new.o delaunay.o densemat.o dynamicmem.o edgeflw.o \ + explicitcurve2d.o extrusion.o flags.o gencyl.o genmesh.o genmesh2d.o geom2d.o \ + geom2dmesh.o geom3d.o geomfuncs.o geomsearch.o geomtest3d.o global.o \ + hashtabl.o hprefinement.o identify.o importsolution.o improve2.o \ + improve2gen.o improve3.o linopt.o linsearch.o localh.o manifold.o meshclass.o \ + meshdoc.o meshfunc.o meshfunc2d.o meshing2.o meshing3.o meshstlsurface.o \ + meshsurf.o meshtool.o meshtype.o moveablemem.o msghandler.o mvdraw.o \ + mystring.o netrule2.o netrule3.o ngexception.o nginterface.o nglib.o \ + ngnewdelete.o ngsock.o occconstruction.o occgenmesh.o occgeom.o occmeshsurf.o \ + optmem.o parser2.o parser3.o parthreads.o polyhedra.o polynomial.o \ + prism2rls.o profiler.o pyramid2rls.o pyramidrls.o quadrls.o readuser.o \ + refine.o revolution.o ruler2.o ruler3.o secondorder.o seti.o singularref.o \ + smoothing2.o smoothing3.o socketmanager.o sockets.o solid.o sort.o sparsmat.o \ + spbita2d.o specials.o specpoin.o spline.o spline3d.o splinegeometry.o \ + stlgeom.o stlgeomchart.o stlgeommesh.o stlline.o stlmeshing.o stltool.o \ + stltopology.o surface.o symbolta.o table.o tetrarls.o topology.o \ + transform3d.o triapprox.o triarls.o vector.o vscsg.o vsfieldlines.o vsmesh.o \ + vsocc.o vssolution.o writeabaqus.o writediffpack.o writeelmer.o writefeap.o \ + writefluent.o writegmsh.o writejcm.o writepermas.o writetecplot.o \ + writetochnog.o writeuser.o wuchemnitz.o zrefine.o NETGEN_LIBS_DIR=@NETGEN_LIBS_DIR@ @@ -61,15 +70,16 @@ ar x $(NETGEN_LIBS_DIR)/libla.a ar x $(NETGEN_LIBS_DIR)/libstlgeom.a ar x $(NETGEN_LIBS_DIR)/libgeom2d.a - rm -rf csgparser.o dynamicmem.o extrusion.o occconstruction.o parthreads.o readuser.o writeabaqus.o writediffpack.o writeelmer.o writefeap.o writefluent.o writegmsh.o writejcm.o writepermas.o writetecplot.o writetochnog.o writeuser.o wuchemnitz.o + ar x $(NETGEN_LIBS_DIR)/libvis.a + ar x $(NETGEN_LIBS_DIR)/libsockets.a #LIB_OBJ_LO = $(LIB_OBJ_O:%.o=%.lo) #%.lo: %.o; @ln -s $< $@ nodist_libNETGEN_la_SOURCES = -libNETGEN_la_LDFLAGS = $(LIB_OBJ_O) \ - $(CAS_LDPATH) -lTKernel -lTKBRep -lTKShHealing -lTKSTEP -lTKXSBase -lTKIGES -lTKMesh -lTKSTL $(FCLIBS) $(STDLIB) +libNETGEN_la_LDFLAGS = $(LIB_OBJ_O) $(NETGEN_LIBS_DIR)/*.o \ + $(CAS_LDPATH) -lTKernel -lTKBRep -lTKShHealing -lTKSTEP -lTKXSBase -lTKIGES -lTKMesh -lTKSTL -lTKTopAlgo -lTKOffset -lTogl1.7 -lGL -lGLU -ltcl -ltk $(FCLIBS) $(STDLIB) libNETGEN_la_DEPENDENCIES = $(LIB_OBJ_O)