-The Netgen 4.3 from the web location : http://www.hpfem.jku.at/netgen/ is used
-in the SMESH Module of Salome2 distribution.
+# ------------------------------------------------------------------
+# ------------------------------------------------------------------
+# Notes for Netgen >= 4.9
+# ------------------------------------------------------------------
+# ------------------------------------------------------------------
-How to build Netgen for Salome
-------------------------------
-
-Patch the official netgen 4.3 distribution:
-
-$ cd netgen43
-$ patch -p1 < patch_directory/netgen43ForSalome.patch
-
-Then run makeForSalome.sh:
-$ sh makeForSalome.sh
+Netgen can be find at http://www.hpfem.jku.at/netgen/
+1. How to build Netgen for Netgen Plugin
+------------------------------
-Additional information for maintainers
---------------------------------------
+1.1. Download Netgen archive (here netgen-4.9.12.tar.gz) and unpack it
-The SMESH Engine of SALOME2 (particularly the m4 file check_Netgen.m4) assume
-that Netgen is installed in the directory <netgen_installation_path> as follow:
+1.2. Configure the netgen compilation. The "good" options are
+ ../netgen-4.9.12/configure \
+ --prefix=THE_INSTALLATION_PATH \
+ --with-occ=${CASROOT} \
+ CXXFLAGS="-I${TOGL_HOME}/include" \
+ LDFLAGS="-L${TOGL_HOME}/lib/Togl1.7"
-prompt> ls <netgen_installation_path>
+1.3. Compile the netgen product
+ make then make install
-bin/ cshrc_for_netgen doc/ include/ lib/ tutorials/
+1.4. Patch the installation directory to copy include files
+ needed by NETGEN Plugin. Use the script
+ NETGENPLUGIN_SRC/src/NETGEN/netgen_copy_include_for_salome
+ to achieve that. The first argument is the directory containing
+ the Netgen sources. The second argument is THE_INSTALLATION_PATH
-prompt> ls <netgen_installation_path>/bin
+Erwan ADAM
+erwan.adam@cea.fr
-LINUX/
+# ------------------------------------------------------------------
+# ------------------------------------------------------------------
+# Notes for Netgen 4.5
+# ------------------------------------------------------------------
+# ------------------------------------------------------------------
-prompt> ls <netgen_installation_path>/bin/LINUX/
+The Netgen 4.5 from the web location : http://www.hpfem.jku.at/netgen/
+(CVS access) is used in the SMESH Module of Salome3 distribution.
-demoapp/ ng ng.tcl ngtcltk/ startup.tcl
+1. How to build Netgen for Salome
+------------------------------
-prompt> ls <netgen_installation_path>/bin/LINUX/demoapp/
+1.1. Download Netgen 4.5 from the NETGEN home site (see above).
-demoapp.tcl
+1.2. Unpack the downloaded Netgen 4.5 archive
+ (hereafter we assume that this is netgen45 directory)
-prompt> ls <netgen_installation_path>/bin/LINUX/ngtcltk/
+1.3. Patch the netgen 4.5 distribution for SALOME:
-dialog.tcl menustat.tcl ngicon.tcl parameters.tcl
-drawing.tcl nghelp.tcl ngvisual.tcl variables.tcl
+$ cd netgen45
+$ patch -p1 < patch_directory/netgen45ForSalome.patch
-prompt> ls <netgen_installation_path>/doc/
+1.4. For 64-bit platform you also need to apply another patch:
-ng4.pdf usenetgen.ps
+$ cd netgen45
+$ patch -p1 < patch_directory/netgen45lib64.patch
-prompt> ls <netgen_installation_path>/include/
+1.5. Set CASROOT environment variable to OCCT installation path,
+ since Netgen 4.5 requires Open CASCADE Technology:
-nglib.h
+$ setenv CASROOT <occt_installation_path>
-prompt> ls <netgen_installation_path>/lib/
+1.6. Compile and install netgen 4.5. To do this, simply run
+ makeForSalome.sh script (it is created from the patch):
-LINUX/
+$ sh makeForSalome.sh
-prompt> ls <netgen_installation_path>/lib/LINUX/
-libcsg.a libgeom2d.a libla.a libnginterface.a libstlgeom.a
-libgen.a libgprim.a libmesh.a libopti.a libvis.a
+2. Additional information for maintainers
+--------------------------------------
-prompt> ls <netgen_installation_path>/tutorials/
+The file check_NETGEN.m4 assumes that Netgen is installed in
+the directory <netgen_installation_path> as follow:
-boxcyl.geo cylinder.geo ficherea.geo part1.stl square.in2d
-cone.geo cylsphere.geo hinge.stl sculpture.geo trafo.geo
-cubeandspheres.geo demo2d.in2d lshape3d.geo shaft.geo twobricks.geo
-cube.geo ellipsoid.geo manyholes.geo sphere.geo twocubes.geo
-cubemcyl.geo ellipticcyl.geo matrix.geo sphereincube.geo twocyl.geo
-cubemsphere.geo
+prompt> ls <netgen_installation_path>
-All *.tcl files are needed to control and initiate the Netgen mesher throughout its
-MHI (Machine Human Interface).<netgen_installation_path>/bin/LINUX/ng is the Netgen
-executable with its embarked MHI. All the libraries *.a should be compiled without
-the option -DOPENGL which is only needed for the Netgen MHI. netgen43 is assumed to
-be the directory downloaded from the above web location archive of Netgen. The library
-<netgen_installation_path>/lib/LINUX/libnginterface.a should contain the objects
-nglib.o (from netgen43/libsrc/interface/nglib.cpp) and ngnewdelete.o
-(from netgen43/ngtcltk/ngnewdelete.cpp).
+include/ lib/
+
+prompt> ls <netgen_installation_path>/include
+
+adfront2.hpp explicitcurve2d.hpp hpref_quad.hpp myadt.hpp spbita2d.hpp
+adfront3.hpp extrusion.hpp hpref_segm.hpp mydefs.hpp specials.hpp
+adtree.hpp findip.hpp hpref_tet.hpp mystdlib.h specpoin.hpp
+algprim.hpp findip2.hpp hpref_trig.hpp mystring.hpp spline.hpp
+array.hpp flags.hpp hprefinement.hpp ngexception.hpp spline2d.hpp
+autoptr.hpp gencyl.hpp identify.hpp nglib.h spline3d.hpp
+basemat.hpp geom2d.hpp improve2.hpp occgeom.hpp splinegeometry.hpp
+bisect.hpp geom2dmesh.hpp improve3.hpp occmeshsurf.hpp splinegeometry2.hpp
+bitarray.hpp geom3d.hpp linalg.hpp opti.hpp stack.hpp
+boundarylayer.hpp geometry2d.hpp localh.hpp optmem.hpp stlgeom.hpp
+brick.hpp geomfuncs.hpp manifold.hpp parthreads.hpp stlline.hpp
+classifyhpel.hpp geoml.hpp meshclass.hpp polyhedra.hpp stltool.hpp
+clusters.hpp geomobjects.hpp meshfunc.hpp polynomial.hpp stltopology.hpp
+csg.hpp geomops.hpp meshing.hpp profiler.hpp surface.hpp
+csgeom.hpp geomsearch.hpp meshing2.hpp revolution.hpp symbolta.hpp
+csgparser.hpp geomtest3d.hpp meshing3.hpp ruler2.hpp table.hpp
+curve2d.hpp global.hpp meshstlsurface.hpp ruler3.hpp template.hpp
+curvedelems.hpp gprim.hpp meshsurf.hpp seti.hpp topology.hpp
+curvedelems_new.hpp hashtabl.hpp meshtool.hpp singularref.hpp transform3d.hpp
+densemat.hpp hpref_hex.hpp meshtype.hpp solid.hpp triapprox.hpp
+dynamicmem.hpp hpref_prism.hpp moveablemem.hpp sort.hpp vector.hpp
+edgeflw.hpp hpref_pyramid.hpp msghandler.hpp sparsmat.hpp
+
+prompt> ls <netgen_installation_path>/lib
+
+libcsg.a libgeom2d.a libla.a libnginterface.a libopti.a
+libgen.a libgprim.a libmesh.a libocc.a libstlgeom.a
+
+The library files can be also installed in the LINUX or LINUX64
+subfolder of the lib directory.
+
+All the libraries *.a should be compiled without the option -DOPENGL.
+netgen45 is assumed to be the directory downloaded from the above web
+location archive of Netgen. The library
+<netgen_installation_path>/lib/libnginterface.a should contain the objects
+nglib.o (from netgen45/libsrc/interface/nglib.cpp) and ngnewdelete.o
+(from netgen45/ngtcltk/ngnewdelete.cpp).
To have that kind of distribution from the version in the above web location you
-should first compile Netgen as suggested in the netgen43/README.INSTALL file. It will
-then produce the executable ng linked statically with the libraries *.a. Then modify
-the Makefiles to remove -DOPENGL from compiler flags list, add the objects nglib.o
-and ngnewdelete.o to the library libnginterface.a and recompile the libraries only.
-
-From the above web location perhaps, you will have to alter some Netgen sources to
-compile them; if you find any difficulties to do that, just ask me.
-
-Nadir
-
-********************************
-* Dr Nadir Bouhamou *
-* Ingénieur-chercheur *
-* Engineer-Researcher *
-* *
-* CEA Saclay *
-* DEN/DM2S/SFME/LGLS *
-* Bat 454 Pièce 5A *
-* 91191 Gif-Sur-Yvette cédex *
-* *
-* Tél: +33 (0)1 69 08 73 07 *
-* Fax: +33 (0)1 69 08 96 96 *
-* email: nadir.bouhamou@cea.fr *
-********************************
+need not to compile Netgen as suggested in the netgen45/README.INSTALL file.
+Simply modify the Makefiles to remove -DOPENGL from compiler flags
+list and to add OCC include dir and flags to compiler flags, add the objects
+nglib.o and ngnewdelete.o to the library libnginterface.a and
+recompile the libraries only.
+All this job is done by applying the patch and running the script makeForSalome.sh.
+
+The suggested patch alters some Netgen sources to compile them.
+
+Michael SAZONOV
+m-sazonov@opencascade.com
+
+# ------------------------------------------------------------------
+# ------------------------------------------------------------------
+# ------------------------------------------------------------------
+# ------------------------------------------------------------------