Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.


Build netgen-4.9.6 [kubuntu8.04 - occ6.3.0]

  • globos

    Hi all,

      I have successfully built netgen-4.9.6 (source code package) on my desktop kubuntu8.04 with OpenCascade6.3.0 enabled.
      I needed to hack some stuff so it can build. I just want to share this with the netgen community.

    Note that I have already tcl/tk, togl 1.7 and OpenCascade6.3.0 installed.

    Here is the the configure command I used :

    ./configure --prefix=/opt/bin/netgen-4.9.6 --enable-occ --enable-nglib --with-tcl=/usr/lib/tcl8.4 --with-tclinclude=/usr/include/tcl8.4 --with-tk=/usr/lib/tk8.4 --with-togl=/opt/lib/Togl-1.7 --with-occ=/opt/lib/occ6.3.0/ros

    I needed to hack netgen like this :

       - netgen-4.9.6 lacks libsrc/occ/utilities.h (I retrieved this file from the svn repository and copied it in libsrc/occ)

       - needed to add -DHAVE_IOMANIP to OCCFLAGS in libsrc/Makefile (compilation errors in Standard_Stream.hxx : unknown "std::setw" and "std::setprecision" that are declared in <iomanip>)

       - because "togl_ws.h" is required by "togl_1_7.h", it is needed to add the Togl-1.7 include folder in ng/Makefile :
        DEFAULT_INCLUDES=-I. -I$(top_builddir) -I/opt/lib/Togl-1.7

    I hope that it can help the netgen package maintainers.

    Another thing is I can't build netgen with --enable-parallel. I tried to install the libopenmpi1 and libopenmpi-dev ubuntu packages but it seems that the MPICH library is internally used by netgen with hard-coded paths in the makefiles, like :
    MPI_INCLUDES = -I/opt/mpich/include -DPARALLEL  -I/usr/share/metis/Lib -DMETIS
    MPI_LIBS = -lmetis -L/opt/mpich/ch-p4/lib -lmpich

    I think the configure script needs to be improved with something like --with-mpich options.

    Kind regards,

      Hugues Delorme