Building on Ubuntu 12.04

These are the steps I needed to take before building VisIt on Ubuntu 12.04 with the default (gcc 4.6) compiler. The instructions are nearly the same as for 11.10 except that a few more packages were needed. Of course, that could be due to me building more 3rd party support libraries.

  • This procedure also worked for Ubuntu 14.04 using gcc 4.8.2 and may generalize to other Linuxes.

On my system VisIt runs with hardware accelerated OpenGL. Ubuntu prompted me to install the proprietary NVIDIA drivers after I installed 12.04 and that worked well.

To build visit and the support libraries, I installed these packages (and any dependencies they required):

  • subversion
  • g++
  • mesa-utils
  • libqt4-dev
  • qt4-dev-tools
  • qt4-doc
  • autoconf
  • libxt-dev
  • bison
  • flex
  • libxrender-dev
  • libxi-dev
  • zlib1g-dev (new from 11.10)
  • libjpeg8-dev (new from 11.10)
  • autoconf
  • python-all-dev
  • libqt4-opengl-dev (which includes libqt4-dev)
  • libxmu-dev
  • libx11-dev
  • freeglut3-dev
  • xutils-dev
  • uuid-dev

I also installed these, though none of them strictly to get visit to build, so I doubt you need any of them (though some sort of MPI is necessary if you want to build a parallel version of VisIt, of course):

  • openmpi-bin
  • libopenmpi-dev
  • tkcvs
  • gfortran
  • lib-avtools


You can run build_visit to compile 3rd party libraries and ultimately build VisIt. While the default mode is graphical, there is a --console mode that can build it all from the command line. A set of commands to build the code looks something like this:

mkdir visit
cd visit
chmod 700 build_visit2_10_0
mkdir thirdparty_shared
./build_visit2_10_0 --console --thirdparty-path `pwd`/thirdparty_shared

config-site file

I edited my existing config-site file instead of using the one created by build_visit. That means I'm not 100% certain whether build_visit gets it right but I had to make some edits regarding libz and libjpeg. I had to add libz to the HDF5 dependencies and I had to edit the path that was used to locate libjpeg in the HDF4 dependencies.

Note the use of the /usr/lib/x86_64-linux-gnu directory.

## HDF4
VISIT_OPTION_DEFAULT(VISIT_HDF4_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz /usr/lib/x86_64-linux-gnu jpeg)

## HDF5
VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz /usr/lib/x86_64-linux-gnu z)


My Ubuntu 12 computer uses OpenMPI. I do not run build_visit with the --parallel flag though. I instead prefer to edit the config-site file after the fact and tell VisIt's build how best to detect my parallel settings. Here is the bit that I add to the config-site:

## Parallel Build Setup.
## (configured w/ mpi compiler wrapper)

Running cmake/make

If you make any manual changes to your config-site file, DO NOT RUN build_visit AGAIN. You should instead run cmake and make directly to build VisIt. The build_visit script has taken care of the hard part of building the 3rd party libraries. By comparison, building VisIt now that you have a config-site file is easy.

# Copy the config-site file into the sources.
cp `hostname`.cmake visit2.10.0/src/config-site

# Run cmake and build VisIt
cd visit2.10.0/src
make -j 4

Notes on NVIDIA drivers

If, during install, you select the option that allows proprietary drivers (it mentions some MP3 tools as an example), this also enables the Ubuntu-packaged NVIDIA proprietary drivers. This is also available in the "Additional Drivers" section of the system settings control panel.

It appears that these drivers install some libraries to unusual locations. This may not cause a problem for VisIt, but I've seen it cause problems in other software.

In the unlikely event that you run into problems, try disabling the Ubuntu-packaged NVIDIA drivers (through Additional Drivers in system settings) and then installing the NVIDIA drivers from the NVIDIA website. Note that current NVIDIA drivers are able to properly disable the broken "Nouveau" driver via a blacklist configuration file. (If you don't allow the NVIDIA driver to do this, Nouveau will override the NVIDIA driver and you will have to blacklist Nouveau manually.)